Confidence Interval for Proportion
Let $X$ be the observed number of individuals possessing certain attributes (number of successes) in a random sample of size $n$ from a large population with population proportion $p$.
Formula
$100(1-\alpha)$% confidence interval for population proportion is
$\hat{p} - E \leq p \leq \hat{p} + E$
where,
$\hat{p}=\dfrac{X}{n}$
is the observed proportion of successes,$E = Z_{\alpha/2} \sqrt{\dfrac{\hat{p}(1-\hat{p})}{n}}$
is the margin of error,$1-\alpha$
is the confidence coefficient,$Z_{\alpha/2}$
is the critical value of $Z$.