$Z$-Test for Proportion

Let $X$ be the observed number of individuals possessing certain attributes (say, number of successes) in a random sample of size $n$ from a large population, then $\hat{p}=\frac{X}{n}$ be the observed proportion of successes. Let $p$ be the population proportion of successes and $q = 1- p$ be the population proportion of failures.

The hypothesis testing problem can be setup as:

Situation Hypothesis Testing Problem
Situation A : $H_0: p=p_0$ against $H_a : p < p_0$ (Left-tailed)
Situation B : $H_0: p=p_0$ against $H_a : p > p_0$ (Right-tailed)
Situation C : $H_0: p=p_0$ against $H_a : p \neq p_0$ (Two-tailed)

Formula

The test statistic for $H_0:p=p_0$ is

$Z=\frac{\hat{p}-p}{SE(\hat{p})}$

where

  • $SE(\hat{p})= \sqrt{\frac{p(1-p)}{n}}$ is standard error of $p$,

The test statistic $Z$ follows standard normal distribution $N(0,1)$

Related Resources