e-Statistics

Comparison of Two Proportions

We are interested in whether there is discrepancy in occurrence of a particular type between two groups, say group 1 and 2. In terms of hypothesis testing it becomes

$ H_A:\hspace{0.05in}p_1$ $ p_2$

where $ p_1$ and $ p_2$ are the respective population proportions from group 1 and 2.

The categorical data are summarized in the count of the specific type (Observed) and the total sample size (Size) in the first row (Group 1) and the second row (Group 2) as follows.

The test statistic is calculated as

$ Z = \displaystyle\frac{\hat{p}_1 - \hat{p}_2}
{\sqrt{\hat{p}(1-\hat{p})\left(\frac{1}{n} + \frac{1}{m}\right)}} =$

where $ \hat{p}_1 = X/n$ and $ \hat{p}_2 = Y/m$ are the point estimates of $ p_1$ and $ p_2$ as they appear in the column Probability in the above table.

$ \hat{p} = \frac{X+Y}{n+m} =$

is called a pooled estimate of the common population proportion. Having constructed the hypothesis testing problems `` $ H_A:\: p_1 = p_2$'', `` $ H_A:\: p_1 > p_2$'', or `` $ H_A:\: p_1 < p_2$'', we can make our decision via p-value = . Also, we may want to see the confidence interval for the difference $ p_1 - p_2$. The confidence interval for $ p_1 - p_2$ can be calculated by

$ \left(
\hat{p}_1 - \hat{p}_2
- z_{\alpha/2}\sqrt{\frac{\hat{p}_1(1-\hat{p}_1)}...
...rt{\frac{\hat{p}_1(1-\hat{p}_1)}{n}
+ \frac{\hat{p}_2(1-\hat{p}_2)}{m}}
\right)$
= ( , )