Achievable logoAchievable logo
AP Statistics
Sign in
Sign up
Purchase
Textbook
Practice exams
Support
How it works
Resources
Exam catalog
Mountain with a flag at the peak
Textbook
Introduction
1. One variable data
2. Two variable data
3. Data collection
4. Probability and random variables
5. Sampling distributions
6. Categorical data
6.1 Introduction to confidence intervals
6.2 Introduction to significance testing
6.3 Confidence intervals for difference of two proportions
6.4 Significance tests for difference of two proportions
7. Quantitative data
8. Chi-square
9. Linear regression
Wrapping up
Achievable logoAchievable logo
6.4 Significance tests for difference of two proportions
Achievable AP Statistics
6. Categorical data
Our AP Statistics course is currently in development and is a work-in-progress.

Significance tests for difference of two proportions

7 min read
Font
Discuss
Share
Feedback

Significance test for two proportions

The goal of a significance test for two proportions is to decide whether an observed difference between two sample proportions reflects a real difference between the two population proportions, or whether the sample difference could reasonably be explained by natural sampling variation.

For this test, the null hypothesis says there is no difference between the population proportions:

H0​​:p1​=p2​​

Conditions for using the two-proportion z test

Large counts (normality) condition

Definitions
Combined (pooled) proportion (p^​c​)
The proportion calculated by combining the successes and sample sizes from both samples.

p^​c​​=n1​+n2​x1​+x2​​​

To use the normal approximation, all four of the following quantities must be at least 10:

n1​p^​c​n1​(1−p^​c​)n2​p^​c​n2​(1−p^​c​)​≥10≥10≥10≥10​

Randomness and independence

  • Each sample should be a random sample (ideally a simple random sample).
  • The two samples must be independent of each other.
  • If sampling is done without replacement, each population size N1​ and N2​ should be at least 10 times the corresponding sample size (the “10% condition”).

Choosing the alternative hypothesis

The alternative hypothesis depends on what the question is asking.

Definitions
Two-sided test
Checks for a difference in either direction. Used when the context only asks whether the two proportions differ.

Ha​​:p1​=p2​​

One-sided test
Used only when the context clearly calls for a specific direction.

Ha​orHa​​:p1​>p2​:p1​<p2​​

Key facts and equations:

  1. The null hypothesis for a significance test for the difference of two proportions is that the population proportions are equal: H0​:p1​=p2​.

  2. The alternate hypothesis is one of:

Ha​Ha​Ha​​:p1​=p2​:p1​<p2​:p1​>p2​​

  1. n1​p^​c​, n1​(1−p^​c​), n2​p^​c​, and n2​(1−p^​c​) must each be at least 10 in order to apply the normality condition.

  2. The combined/pooled proportion equation is:

p^​c​​=n1​+n2​x1​+x2​​​

  1. The standard error of the distribution of differences in sample proportions is:

SE​=p^​c​(1−p^​c​)(n1​1​+n2​1​)​​

Practice problem

Example:

After a major wildfire, an organization surveyed two different local districts to see how many homeowners were able to get the emergency help that they needed. In a random sample of 720 homeowners from district A, 432 said that they were able to get the help that they needed. In another random sample of 610 homeowners from district B, 336 said they were able to get the help they needed. The 95% confidence interval for pA​−pB​ is (−0.004,0.102).

Part a.

Does the data that is given provide convincing evidence that a greater proportion of district A homeowners were able to get help than district B homeowners?

Define the parameters:

  • Let pA​ represent the true proportion of homeowners in district A who were able to get the help they needed.
  • Let pB​ represent the true proportion of homeowners in district B who were able to get the help they needed.

State the hypotheses:

H0​Ha​​:pA​=pB​:pA​>pB​​

The alternative hypothesis is one-sided because the question is specifically asking whether the proportion in district A is greater than the proportion in district B. The key question is whether the observed sample difference is large enough to be unlikely under H0​, given the natural variation we expect from random sampling.

Check the large counts (normality) condition:

First compute the pooled proportion:

p^​c​​=720+610432+336​=1330768​≈0.577​

Now check each value:

nA​p^​c​​=720(0.577)=415.44​

nA​(1−p^​c​)​=720(0.423)=304.56​

nB​p^​c​​=610(0.577)=351.97​

nB​(1−p^​c​)​=610(0.423)=258.03​

Since all four values are at least 10, the large counts condition is met.

Check the independence requirement:

The independence requirement is that each sample size should be less than 10% of its population size. Although the exact number of homeowners in each district is not given, it is reasonable to assume each district has far more than 7,200 and 6,100 homeowners, so the 10% condition is likely satisfied.

Complete the test with a TI-84 calculator:

  • Step 1: Press STAT, scroll over to TESTS, scroll down to 6: 2-PropZTest, and press ENTER.
  • Step 2: Input the following data:
    • x1​ = number of successes in sample 1 (using district A data: 432)
    • n1​ = size of sample 1 (720)
    • x2​ = number of successes in sample 2 (using district B data: 336)
    • n2​ = size of sample 2 (610)
    • Choose alternative hypothesis: >

The calculator gives:

zpp^​1​p^​2​​≈1.809=0.0352=0.6=0.551​

Compare the p-value to α=0.05:

0.0352​<0.05​

Solution:

(spoiler)

Since the p-value is less than α, we reject the null hypothesis. There is evidence that a greater proportion of district A homeowners were able to get the help they needed compared to district B homeowners.

Part b.

Is the result consistent with the 95% confidence interval that is given above?

Solution:

(spoiler)

The problem states that a 95% confidence interval for pA​−pB​ is (−0.004,0.102).

This interval contains 0 (since −0.004<0<0.102), which means that a two-sided test at the α=0.05 level would not reject H0​:pA​=pB​.

That does not contradict Part a, because Part a used a one-sided alternative (pA​>pB​). The interval is mostly positive and only barely dips below 0, which matches the idea that the data lean toward pA​>pB​ even though a two-sided interval still includes 0.

Part c.

If the null hypothesis had been that the two proportions were equal, what type of error (Type I or Type II) could have potentially been made based on the conclusion?

Solution:

(spoiler)

A type I error happens when we reject the null hypothesis even though it is true (a false positive). A type II error happens when we fail to reject the null hypothesis even though it is false (a false negative).

Here, we rejected H0​, so the only possible error consistent with that decision is a type I error.

Purpose of two-proportion significance test

  • Tests if observed sample proportion difference reflects true population difference
  • Null hypothesis: H0​:p1​=p2​
  • Decides between real difference or sampling variation

Conditions for two-proportion z test

  • Large counts (normality): all n1​p^​c​, n1​(1−p^​c​), n2​p^​c​, n2​(1−p^​c​)≥10
    • p^​c​=n1​+n2​x1​+x2​​ (pooled proportion)
  • Randomness: each sample is random
  • Independence: samples independent; 10% condition if sampling without replacement

Alternative hypothesis choices

  • Two-sided: Ha​:p1​=p2​
  • One-sided: Ha​:p1​>p2​ or Ha​:p1​<p2​
  • Direction depends on context of the question

Key formulas

  • Pooled proportion: p^​c​=n1​+n2​x1​+x2​​
  • Standard error: SE=p^​c​(1−p^​c​)(n1​1​+n2​1​)​

Interpreting results and errors

  • Reject H0​ if p-value < significance level (e.g., 0.05)
  • Confidence interval containing 0 means no significant difference at two-sided α
  • Type I error: rejecting H0​ when it is true (false positive)
  • Type II error: failing to reject H0​ when it is false (false negative)

Sign up for free to take 8 quiz questions on this topic

Previous
Next  | 7.1 Significance test for the difference of two means
All rights reserved ©2016 - 2026 Achievable, Inc.

Significance tests for difference of two proportions

Significance test for two proportions

The goal of a significance test for two proportions is to decide whether an observed difference between two sample proportions reflects a real difference between the two population proportions, or whether the sample difference could reasonably be explained by natural sampling variation.

For this test, the null hypothesis says there is no difference between the population proportions:

H0​​:p1​=p2​​

Conditions for using the two-proportion z test

Large counts (normality) condition

Definitions
Combined (pooled) proportion (p^​c​)
The proportion calculated by combining the successes and sample sizes from both samples.

p^​c​​=n1​+n2​x1​+x2​​​

To use the normal approximation, all four of the following quantities must be at least 10:

n1​p^​c​n1​(1−p^​c​)n2​p^​c​n2​(1−p^​c​)​≥10≥10≥10≥10​

Randomness and independence

  • Each sample should be a random sample (ideally a simple random sample).
  • The two samples must be independent of each other.
  • If sampling is done without replacement, each population size N1​ and N2​ should be at least 10 times the corresponding sample size (the “10% condition”).

Choosing the alternative hypothesis

The alternative hypothesis depends on what the question is asking.

Definitions
Two-sided test
Checks for a difference in either direction. Used when the context only asks whether the two proportions differ.

Ha​​:p1​=p2​​

One-sided test
Used only when the context clearly calls for a specific direction.

Ha​orHa​​:p1​>p2​:p1​<p2​​

Key facts and equations:

  1. The null hypothesis for a significance test for the difference of two proportions is that the population proportions are equal: H0​:p1​=p2​.

  2. The alternate hypothesis is one of:

Ha​Ha​Ha​​:p1​=p2​:p1​<p2​:p1​>p2​​

  1. n1​p^​c​, n1​(1−p^​c​), n2​p^​c​, and n2​(1−p^​c​) must each be at least 10 in order to apply the normality condition.

  2. The combined/pooled proportion equation is:

p^​c​​=n1​+n2​x1​+x2​​​

  1. The standard error of the distribution of differences in sample proportions is:

SE​=p^​c​(1−p^​c​)(n1​1​+n2​1​)​​

Practice problem

Example:

After a major wildfire, an organization surveyed two different local districts to see how many homeowners were able to get the emergency help that they needed. In a random sample of 720 homeowners from district A, 432 said that they were able to get the help that they needed. In another random sample of 610 homeowners from district B, 336 said they were able to get the help they needed. The 95% confidence interval for pA​−pB​ is (−0.004,0.102).

Part a.

Does the data that is given provide convincing evidence that a greater proportion of district A homeowners were able to get help than district B homeowners?

Define the parameters:

  • Let pA​ represent the true proportion of homeowners in district A who were able to get the help they needed.
  • Let pB​ represent the true proportion of homeowners in district B who were able to get the help they needed.

State the hypotheses:

H0​Ha​​:pA​=pB​:pA​>pB​​

The alternative hypothesis is one-sided because the question is specifically asking whether the proportion in district A is greater than the proportion in district B. The key question is whether the observed sample difference is large enough to be unlikely under H0​, given the natural variation we expect from random sampling.

Check the large counts (normality) condition:

First compute the pooled proportion:

p^​c​​=720+610432+336​=1330768​≈0.577​

Now check each value:

nA​p^​c​​=720(0.577)=415.44​

nA​(1−p^​c​)​=720(0.423)=304.56​

nB​p^​c​​=610(0.577)=351.97​

nB​(1−p^​c​)​=610(0.423)=258.03​

Since all four values are at least 10, the large counts condition is met.

Check the independence requirement:

The independence requirement is that each sample size should be less than 10% of its population size. Although the exact number of homeowners in each district is not given, it is reasonable to assume each district has far more than 7,200 and 6,100 homeowners, so the 10% condition is likely satisfied.

Complete the test with a TI-84 calculator:

  • Step 1: Press STAT, scroll over to TESTS, scroll down to 6: 2-PropZTest, and press ENTER.
  • Step 2: Input the following data:
    • x1​ = number of successes in sample 1 (using district A data: 432)
    • n1​ = size of sample 1 (720)
    • x2​ = number of successes in sample 2 (using district B data: 336)
    • n2​ = size of sample 2 (610)
    • Choose alternative hypothesis: >

The calculator gives:

zpp^​1​p^​2​​≈1.809=0.0352=0.6=0.551​

Compare the p-value to α=0.05:

0.0352​<0.05​

Solution:

(spoiler)

Since the p-value is less than α, we reject the null hypothesis. There is evidence that a greater proportion of district A homeowners were able to get the help they needed compared to district B homeowners.

Part b.

Is the result consistent with the 95% confidence interval that is given above?

Solution:

(spoiler)

The problem states that a 95% confidence interval for pA​−pB​ is (−0.004,0.102).

This interval contains 0 (since −0.004<0<0.102), which means that a two-sided test at the α=0.05 level would not reject H0​:pA​=pB​.

That does not contradict Part a, because Part a used a one-sided alternative (pA​>pB​). The interval is mostly positive and only barely dips below 0, which matches the idea that the data lean toward pA​>pB​ even though a two-sided interval still includes 0.

Part c.

If the null hypothesis had been that the two proportions were equal, what type of error (Type I or Type II) could have potentially been made based on the conclusion?

Solution:

(spoiler)

A type I error happens when we reject the null hypothesis even though it is true (a false positive). A type II error happens when we fail to reject the null hypothesis even though it is false (a false negative).

Here, we rejected H0​, so the only possible error consistent with that decision is a type I error.

Key points

Purpose of two-proportion significance test

  • Tests if observed sample proportion difference reflects true population difference
  • Null hypothesis: H0​:p1​=p2​
  • Decides between real difference or sampling variation

Conditions for two-proportion z test

  • Large counts (normality): all n1​p^​c​, n1​(1−p^​c​), n2​p^​c​, n2​(1−p^​c​)≥10
    • p^​c​=n1​+n2​x1​+x2​​ (pooled proportion)
  • Randomness: each sample is random
  • Independence: samples independent; 10% condition if sampling without replacement

Alternative hypothesis choices

  • Two-sided: Ha​:p1​=p2​
  • One-sided: Ha​:p1​>p2​ or Ha​:p1​<p2​
  • Direction depends on context of the question

Key formulas

  • Pooled proportion: p^​c​=n1​+n2​x1​+x2​​
  • Standard error: SE=p^​c​(1−p^​c​)(n1​1​+n2​1​)​

Interpreting results and errors

  • Reject H0​ if p-value < significance level (e.g., 0.05)
  • Confidence interval containing 0 means no significant difference at two-sided α
  • Type I error: rejecting H0​ when it is true (false positive)
  • Type II error: failing to reject H0​ when it is false (false negative)

More from Categorical data

  • Introduction to confidence intervals
  • Introduction to significance testing
  • Confidence intervals for difference of two proportions