Tutorials › AP Statistics › Using 2-PropZInt on the Calculator

Two-proportion confidence intervals · Tutorial 508 of 1000

Using 2-PropZInt on the Calculator

Use the TI-84’s 2-PropZInt command, then check that its interval agrees with the point estimate, standard error, and margin of error calculated by hand.

Intermediate 9 min read

What You'll Learn

  • Find the 2-PropZInt command and enter its five required inputs correctly
  • Identify the interval and sample proportions in the calculator output
  • Match calculator endpoints to a hand-calculated two-proportion z-interval
  • Check the design and Large Counts conditions before relying on the output
  • Recognize how changing the confidence level or group order changes the interval

From the Hand Calculation to the Calculator

In Constructing a Two-Proportion z-Interval by Hand, you calculated the point estimate, standard error, critical value, and endpoints of an interval for \(p_1-p_2\). The TI-84’s 2-PropZInt command performs those arithmetic steps quickly. Your job is still to define the groups, check the conditions, enter the data in the right order, and decide whether the displayed output matches the problem.

The calculator needs the number of successes and sample size for each group, followed by the confidence level. It calculates the sample proportions and the interval for their difference. It does not know what a “success” means in your situation, verify the study design, or decide which group should be first.

Definition: The TI-84’s 2-PropZInt is a calculator procedure for a two-proportion z-interval. It takes \(x_1,n_1,x_2,n_2\), and a confidence level as inputs and returns an interval estimating \(p_1-p_2\), along with the two sample proportions.

Entering the Information

On a TI-84, press STAT, move to TESTS, and select 2-PropZInt. Enter the number of successes and the sample size for Group 1, then the number of successes and the sample size for Group 2. Enter the confidence level as a decimal, such as \(0.95\) for 95% confidence. Select Calculate.

1
Define the groups and success.
Name Group 1 and Group 2, define the shared outcome counted as a success, and establish that the interval estimates \(p_1-p_2\).
2
Check the conditions.
Review the study design, independence, the 10% condition when applicable, and the Large Counts condition for each group. The calculator does not check these for you.
3
Enter the inputs in group order.
Enter \(x_1,n_1,x_2,n_2\), then the confidence level as a decimal. Do not enter a sample proportion where the calculator asks for a count.
4
Read and verify the output.
Record the interval and sample proportions. Compare them with your hand calculations, keeping the subtraction order consistent.

The output typically labels the interval endpoints and also displays \(\hat{p}_1\) and \(\hat{p}_2\). The proportions provide a quick check: they should equal \(x_1/n_1\) and \(x_2/n_2\). The interval should estimate the difference in that same order, Group 1 minus Group 2.

As in the earlier tutorial on constructing the interval by hand, the calculator’s calculation is equivalent to:

$$ (\hat{p}_1-\hat{p}_2) \mathbin{\pm} z^* \sqrt{ \frac{\hat{p}_1(1-\hat{p}_1)}{n_1} + \frac{\hat{p}_2(1-\hat{p}_2)}{n_2} } $$

Here, \(z^*\) is the critical value for the selected confidence level. The interval calculation uses each group’s sample proportion separately. Do not use a pooled proportion, which belongs to a different calculation used for a two-proportion test.

Worked Examples

Worked Example: A 95% Interval for Recycling Participation

Setting: Imagine independent random samples of households from two neighborhoods. A household is counted as a success if it reports participating in a local recycling program. In Neighborhood 1, 72 of 120 households are successes; in Neighborhood 2, 54 of 120 are successes. Assume each neighborhood has at least 1,200 households. Use 2-PropZInt to construct a 95% interval for \(p_1-p_2\), with Neighborhood 1 first.

State: Let \(p_1\) and \(p_2\) be the true proportions of households participating in the program in Neighborhoods 1 and 2, respectively. We want an interval estimating \(p_1-p_2\).

Plan: The samples are stated to be independent random samples, supporting the Random condition and independence between groups. Each sample of 120 is no more than 10% of its population because each neighborhood has at least 1,200 households. The Large Counts condition is met: Neighborhood 1 has 72 successes and \(120-72=48\) failures; Neighborhood 2 has 54 successes and \(120-54=66\) failures. All four counts are at least 10, so a two-proportion z-interval is appropriate.

Do by hand: Calculate the sample proportions and their difference:

$$ \hat{p}_1=\frac{72}{120}=0.60,\qquad \hat{p}_2=\frac{54}{120}=0.45,\qquad \hat{p}_1-\hat{p}_2=0.15 $$

The interval standard error uses the separate sample proportions:

$$ \begin{aligned} SE_{\hat{p}_1-\hat{p}_2} &=\sqrt{\frac{0.60(0.40)}{120}+\frac{0.45(0.55)}{120}}\\ &=\sqrt{0.002000+0.0020625}\\ &=\sqrt{0.0040625}\approx0.06374 \end{aligned} $$

For 95% confidence, use \(z^*\approx1.96\). Thus the margin of error is \(1.96(0.0637377)\approx0.1249\), and the interval is:

$$ 0.15\mathbin{\pm}0.1249 \quad\Longrightarrow\quad (0.0251,\ 0.2749) $$

Do on the calculator: Select 2-PropZInt and enter \(x_1=72\), \(n_1=120\), \(x_2=54\), \(n_2=120\), and C-Level \(=0.95\). The calculator reports sample proportions \(0.60\) and \(0.45\), and an interval approximately \((0.0251,\ 0.2749)\). These agree with the hand calculation after rounding.

Conclude: We are 95% confident that the true recycling participation proportion in Neighborhood 1 minus the true proportion in Neighborhood 2 is between about 0.025 and 0.275. The important calculator check is that the displayed interval estimates the stated difference in the stated group order.

Worked Example: Changing the Confidence Level

Setting: Imagine independent random samples of subscribers from two online services. In Service 1, 84 of 140 sampled subscribers have enabled a particular reminder; in Service 2, 63 of 140 have enabled it. Assume each service has at least 1,400 subscribers. Use 2-PropZInt to find a 90% interval for \(p_1-p_2\).

Conditions: The samples are independent random samples, so the Random condition and independence between groups are supported. Each sample is at most 10% of its population because each population has at least 1,400 subscribers. The success and failure counts are 84 and 56 for Service 1, and 63 and 77 for Service 2. All counts are at least 10, so the Large Counts condition is met.

Hand calculation: The sample proportions and point estimate are:

$$ \hat{p}_1=\frac{84}{140}=0.60,\qquad \hat{p}_2=\frac{63}{140}=0.45,\qquad \hat{p}_1-\hat{p}_2=0.15 $$

The standard error is:

$$ \begin{aligned} SE_{\hat{p}_1-\hat{p}_2} &=\sqrt{\frac{0.60(0.40)}{140}+\frac{0.45(0.55)}{140}}\\ &=\sqrt{0.0017143+0.0017679}\\ &=\sqrt{0.0034821}\approx0.05901 \end{aligned} $$

For 90% confidence, \(z^*\approx1.645\). The margin of error is \(1.645(0.0590097)\approx0.0971\), giving:

$$ 0.15\mathbin{\pm}0.0971 \quad\Longrightarrow\quad (0.0529,\ 0.2471) $$

Calculator entry and check: Enter \(84,140,63,140\), in that order, and set C-Level to \(0.90\). The output should show \(\hat{p}_1=0.60\), \(\hat{p}_2=0.45\), and endpoints approximately \(0.0529\) and \(0.2471\). A 90% interval is narrower here than the 95% interval in the first example because a lower confidence level uses a smaller critical value. The sample sizes and proportions also affect the standard error, so compare intervals only with those details in mind.

Worked Example: Checking an Interval That Includes Zero

Setting: Imagine independent random samples of community gardeners from two regions. In Region 1, 46 of 100 sampled gardeners use a particular watering method. In Region 2, 40 of 95 use it. Assume the regions have at least 1,000 and 950 gardeners, respectively. Use 2-PropZInt for a 95% interval, with Region 1 first.

Conditions: The samples are independent random samples, supporting randomness and independence between groups. The sample sizes are no more than 10% of their respective populations. Region 1 has 46 successes and 54 failures; Region 2 has 40 successes and 55 failures. All four counts are at least 10, so the Large Counts condition is met.

Hand calculation: The sample proportions and their difference are:

$$ \hat{p}_1=\frac{46}{100}=0.46,\qquad \hat{p}_2=\frac{40}{95}\approx0.42105,\qquad \hat{p}_1-\hat{p}_2\approx0.03895 $$

Calculate the standard error using each group’s own proportion and sample size:

$$ \begin{aligned} SE_{\hat{p}_1-\hat{p}_2} &=\sqrt{\frac{0.46(0.54)}{100} +\frac{(40/95)(55/95)}{95}}\\ &=\sqrt{0.002484+0.002566}\\ &=\sqrt{0.005050}\approx0.07106 \end{aligned} $$

For 95% confidence, the margin of error is approximately \(1.959964(0.0710632)=0.1393\). Therefore:

$$ 0.03895\mathbin{\pm}0.1393 \quad\Longrightarrow\quad (-0.1003,\ 0.1782) $$

Calculator entry and check: Enter \(x_1=46\), \(n_1=100\), \(x_2=40\), \(n_2=95\), and C-Level \(=0.95\). The calculator’s sample proportions should be about \(0.46\) and \(0.4211\), with interval endpoints about \(-0.1003\) and \(0.1782\). Small differences in the final displayed digits are due to rounding.

What the check tells us: The hand and calculator endpoints agree, and the interval contains zero. That observation is a check on the result, not a sign that the calculator has made an error. The interval is still an estimate of \(p_1-p_2\); the detailed interpretation of its endpoints is the subject of the next tutorial.

Common Mistakes and AP Exam Tips

  • Entering the groups in the wrong order: 2-PropZInt estimates Group 1 minus Group 2. If the question defines \(p_1-p_2\), enter Group 1’s count and sample size first. Reversing the groups reverses the sign of the estimated difference and interval.
  • Entering proportions instead of counts: The calculator asks for \(x_1,n_1,x_2,n_2\), not \(\hat{p}_1,\hat{p}_2\). For example, enter 72 and 120, not 0.60 and 120.
  • Confusing successes with failures: Enter the number that meets the problem’s stated success definition. The calculator obtains the number of failures from \(n_i-x_i\); do not enter the failure count as \(x_i\).
  • Using a percent instead of a decimal: Enter \(0.95\) for 95% confidence, not 95. Check the confidence-level field before calculating.
  • Trusting output without checking conditions: A calculator can produce an interval even when the study design or Large Counts condition is unsuitable. State the conditions and verify them from the data and setting.
  • Copying endpoints without showing the method: On an AP response, a calculator result alone may not demonstrate understanding. Identify the parameter, check conditions, and show enough work or explain how the entered values correspond to the groups.
AP Exam Tip: Use the calculator to reduce arithmetic, not to replace statistical reasoning. A strong response names \(p_1-p_2\), verifies the conditions, states the input order and confidence level, and checks that the calculator’s sample proportions and endpoints agree with the hand-calculation formula.

Key Takeaway

2-PropZInt automates the arithmetic for a two-proportion confidence interval. Enter the successes and sample sizes in the order of the defined groups, use the confidence level as a decimal, and verify the output against the separate sample proportions, point estimate, standard error, and margin of error. The calculator does not check whether the procedure is appropriate.

Key takeaway: The interval from 2-PropZInt estimates \(p_1-p_2\). Correct inputs and a matching hand calculation are useful checks, but you must still justify the procedure using the study design and Large Counts condition.

Check Your Understanding

Use the calculator steps and hand-calculation checks from this tutorial to answer each question.

  1. For samples with 38 successes out of 80 in Group 1 and 27 successes out of 75 in Group 2, what five values would you enter for a 95% interval?
  2. Why should you check the calculator’s displayed \(\hat{p}_1\) and \(\hat{p}_2\) after entering the data?
  3. What happens to the sign and endpoint order if you reverse the two groups in a 2-PropZInt calculation?
  4. For counts \(x_1=46,n_1=100,x_2=40,n_2=95\), list the four success and failure counts used to check the Large Counts condition.
  5. Does a calculator-generated interval by itself show that the Random, independence, 10%, and Large Counts conditions are satisfied? Explain briefly.