Tutorials › Introduction to Statistics › Checking Conditions for Two-Proportion Inference

Two-Proportion Inference · Tutorial 711 of 996

Checking Conditions for Two-Proportion Inference

Check whether a study’s design and counts support valid two-proportion inference, and identify what to do when a condition fails.

Intermediate 10 min read

What You'll Learn

  • Distinguish conditions for generalizing from a sample from conditions for drawing a causal conclusion.
  • Check independence within each group and between groups.
  • Apply the 10% condition when sampling without replacement.
  • Check observed success and failure counts for a confidence interval.
  • Check pooled expected counts under the null hypothesis for a two-proportion test.
  • Recognize when a large sample does not fix a problem in the study design.

Why Check Conditions Before Calculating?

A two-proportion confidence interval or test uses a normal approximation to describe uncertainty in a difference between two population proportions. The arithmetic may be straightforward, but the approximation is only useful when the study design and the data support it. A large total sample does not automatically make an analysis valid: observations may be dependent, the groups may not be comparable in the intended way, or one group may have too few successes or failures.

For two groups, let \(n_1\) and \(n_2\) be their sample sizes, and let \(x_1\) and \(x_2\) be their numbers of successes. The sample proportions are \(\hat{p}_1=x_1/n_1\) and \(\hat{p}_2=x_2/n_2\). The inferential target is often the difference \(p_1-p_2\), where \(p_1\) and \(p_2\) are the corresponding population proportions. Before calculating an interval or test statistic for that difference, examine the study design, independence, and success-failure counts.

Definition: The main conditions for a normal-approximation two-proportion procedure are (1) an appropriate random sampling or assignment design, (2) independent observations within and between groups, and (3) sufficiently large success and failure counts. The precise count check differs for a confidence interval and a test of \(H_0:p_1=p_2\).

Sampling and Assignment: What Can the Study Support?

A random sample can support inference from the sample to the population from which it was drawn, provided the sampling process is appropriate and the independence conditions are reasonable. In a randomized experiment, random assignment supports a comparison of outcomes between the assigned groups and can support a causal conclusion about the treatment in that experiment. Random assignment by itself does not make the participants representative of a broader population, so it does not automatically justify generalizing the result to everyone.

The intended conclusion matters. For example, two independently selected random samples from two populations may support a comparison of population proportions. Two groups formed by random assignment may support a causal comparison of treatments. A convenience sample with no random selection or assignment may still describe the people observed, but it does not gain population representativeness simply because a two-proportion formula can be calculated.

Independence Within and Between Groups

The standard two-proportion model treats the outcomes as independent Bernoulli observations: each individual has a binary outcome, such as success or failure, and one person’s outcome does not determine another’s. It also treats the two groups as independent. These assumptions can be questionable if the same people contribute outcomes to both groups, if observations are matched, or if participants are clustered in households, schools, clinics, or other shared settings.

When a random sample is taken without replacement from a finite population, the observations are not exactly independent: selecting one person slightly changes who remains available. A common practical safeguard is the 10% condition: each sample size should be no more than 10% of its source population. If this condition is met, the dependence from sampling without replacement is usually small enough for the usual calculations.

For independent two-group inference, check both groups’ sampling or assignment structure. Two samples drawn separately from nonoverlapping populations can be independent. In an experiment, individual random assignment to one of two treatments can support the independent-groups model when each participant contributes one outcome and there is no meaningful interference between participants. If the same person is measured twice, or treatment is assigned to whole clinics while outcomes are measured on patients within them, the standard independent two-proportion procedure may not be appropriate.

Worked Example: Checking Two Independent Random Samples

Suppose a hypothetical survey uses separate random samples of adults from two towns. In Town A, 42 of 120 sampled adults report using a particular service; in Town B, 27 of 110 do. Each town has more than 1,200 adults. Check the design and count conditions for comparing the two population proportions.

Sampling design. The samples are described as random and drawn separately from the two towns, so the design is suitable for estimating each town’s proportion and comparing them, subject to the stated sampling assumptions. The samples are nonoverlapping, so the groups are independent by design.

10% condition. In Town A, \(120/1200=0.10\); because the population is more than 1,200, the sample is less than 10% of that population. In Town B, \(110/1200\approx0.0917\), also less than 10% of even a population of 1,200. Thus, the 10% condition is met for both samples.

Observed counts. Town A has 42 successes and \(120-42=78\) failures. Town B has 27 successes and \(110-27=83\) failures. All four counts are at least 10, so the usual success-failure check for a two-proportion confidence interval is met.

These checks support using the usual normal-approximation interval for the difference in the towns’ service-use proportions. They do not prove that the survey has no bias; for example, nonresponse could still affect how well the sampled adults represent their towns.

Success-Failure Counts for a Confidence Interval

For a confidence interval for \(p_1-p_2\), the standard large-sample check uses the observed counts in each group. Each group should have at least 10 successes and at least 10 failures. In symbols, check \(x_1\), \(n_1-x_1\), \(x_2\), and \(n_2-x_2\). This check supports the normal approximation for the sampling distribution of the difference in sample proportions.

A short justification comes from the variance of a sample proportion. For independent Bernoulli outcomes with success probability \(p_i\), the sample proportion in group \(i\) has variance \(p_i(1-p_i)/n_i\). When both successes and failures are sufficiently numerous, the distribution of that proportion is reasonably approximated by a normal distribution. If the two groups are independent, the variances of their sample proportions add when forming a difference:

$$ \operatorname{Var}(\hat{p}_1-\hat{p}_2) = \frac{p_1(1-p_1)}{n_1} + \frac{p_2(1-p_2)}{n_2}. $$

The observed proportions estimate the unknown population proportions in this variance expression. The success-failure check is a practical safeguard for using the resulting normal-approximation interval. The cutoff of 10 is a common rule of thumb, not a mathematical boundary at which an approximation suddenly becomes exact.

Success-Failure Counts for a Hypothesis Test

For a two-proportion test of \(H_0:p_1=p_2\), the null hypothesis supplies a common success probability for both groups. The usual test estimates this common probability with the pooled proportion \(\hat{p}_{\text{pool}}=(x_1+x_2)/(n_1+n_2)\). Under the null model, the expected numbers of successes and failures in group \(i\) are \(n_i\hat{p}_{\text{pool}}\) and \(n_i(1-\hat{p}_{\text{pool}})\). A common large-sample check requires all four expected counts to be at least 10.

This test check is not identical to the confidence-interval check. For the interval, use the observed successes and failures in each group. For a test of equal proportions, use the pooled expected counts under the null. Some introductory settings apply the observed-count rule as a simpler conservative screen for tests too. Whichever convention is specified, state which counts were checked rather than saying only that the sample is “large enough.”

Worked Example: The Test Check Passes but the Interval Check Fails

In a hypothetical randomized study, 34 of 40 participants assigned to a program have the binary outcome of interest, compared with 20 of 40 participants assigned to control. Check the count conditions for a confidence interval and for a test of \(H_0:p_1=p_2\).

Confidence interval. In the program group there are 34 successes and \(40-34=6\) failures. In the control group there are 20 successes and \(40-20=20\) failures. The program group has fewer than 10 observed failures, so the usual 10-per-category condition for a two-proportion confidence interval is not met.

Test under the equality null. The pooled estimate is \(\hat{p}_{\text{pool}}=(34+20)/(40+40)=54/80=0.675\). Under the null, each group has expected successes \(40(0.675)=27\) and expected failures \(40(1-0.675)=40(0.325)=13\). All four expected counts are at least 10, so the common pooled expected-count check for the test is met.

The two checks give different answers because they use different counts. The confidence-interval condition fails because one observed category contains only 6 participants; the test’s pooled expected-count condition passes because its null-model expected counts are 27 and 13 in each group. Passing the test count check does not make the interval check pass, nor does either count check repair a problem with the study design.

Worked Example: Large Counts Do Not Fix Dependence

Suppose a hypothetical health program is assigned to 12 clinics, with 6 clinics assigned to the program and 6 to usual care. Across the program clinics, 180 of 240 patients have a successful outcome; across the usual-care clinics, 150 of 240 do. Determine whether the usual independent two-proportion procedure is justified by these counts and this design.

Count check. The program group has 180 successes and \(240-180=60\) failures. The usual-care group has 150 successes and \(240-150=90\) failures. All four observed counts exceed 10, so the count check for an interval is comfortably met.

Design check. Treatment was assigned to clinics, not independently to individual patients. Patients at the same clinic may share staff, procedures, or other influences, so their outcomes may be correlated. Counting 240 patients in each group does not make those outcomes independent. The effective independent information is tied in part to the 12 clinics, not simply to 480 separate patients.

Therefore, large patient-level success and failure counts are not enough to justify the ordinary independent two-proportion calculation. The analysis must account for the cluster-randomized design; the basic two-proportion procedure should not be applied as if every patient had been independently assigned and observed.

A Practical Condition-Checking Sequence

A reliable check proceeds from the study design to the counts. This order helps prevent a common mistake: looking at a favorable count table and overlooking that the observations are paired or clustered.

1
Name the groups and outcome.
State what counts as a success in each group, and identify the sample sizes and success counts.
2
Inspect sampling or assignment.
Decide whether random sampling supports population inference or random assignment supports a treatment comparison. Do not claim more than the design allows.
3
Assess independence.
Check whether each individual contributes one outcome, whether observations may be paired or clustered, and whether the two groups are independent.
4
Apply the relevant count rule.
For an interval, check observed successes and failures in both groups. For a test of equal proportions, check the pooled expected counts under the null.
5
State the conclusion of the check.
Say which conditions are met, which are not, and what that means for the planned normal-approximation procedure.

Common Mistakes and Why the Conditions Matter

  • Checking only the total sample size. A sample can be large overall but have very few failures in one group. Check both categories separately in each group.
  • Using the wrong counts for the procedure. For a confidence interval, the usual check uses observed counts. For a test of equal proportions, the pooled null model gives the expected-count check.
  • Treating “random” as a complete description. Random sampling, random assignment, independence, and representativeness answer different questions. Identify what was randomized and what conclusion it can support.
  • Assuming many people guarantee independent data. People in the same clinic or household can have related outcomes. A large number of individuals does not remove clustering.
  • Calling the rule of 10 an exact law. It is a practical approximation guideline. A failed check means the usual normal approximation may be unreliable, not that every possible analysis is impossible.

These conditions matter because an interval’s stated coverage and a test’s p-value rely on an appropriate sampling distribution. If the observations are dependent or the normal approximation is poor, the calculated uncertainty can be misleading. A careful condition check is therefore part of the statistical argument, not a box to tick after the calculation.

Key takeaway: First verify that the design and independence assumptions support comparing two groups. Then check the appropriate success-failure counts: observed counts for the usual interval condition and pooled expected counts under equality for the usual test condition. Report any limitation rather than hiding it behind a large total sample size.

Check Your Understanding

For each situation, identify which condition or distinction needs attention.

  1. A random sample of 90 people is drawn without replacement from a population of 600. Does it meet the 10% condition? Show the relevant comparison.
  2. In a two-proportion confidence interval, one group has 18 successes and 7 failures. Does that group meet the common 10-per-category count rule?
  3. A test of \(H_0:p_1=p_2\) has pooled estimate \(\hat{p}_{\text{pool}}=0.40\), with \(n_1=50\) and \(n_2=60\). Find the expected successes and failures in each group, and check them against 10.
  4. The same patients are measured before and after treatment, with many successes and failures at both times. Why may the independent two-proportion procedure still be inappropriate?
  5. A randomized study recruits volunteers and randomly assigns them to two treatments. Which part of the design supports a causal comparison, and why does it not by itself establish generalizability to the full population?