AP Statistics · Unit 4 · Topic 4.7

    4.7 Constructing a Confidence Interval for the Difference Between Two Population Means

    Reviewed by P V Satish, Senior Faculty of Science and Academic Consultant · PG Life Sciences, PGD Biotechnology · 20+ years teaching NEET and AP · Special interest in biotechnology, biochemistry and the basics of physics
    Updated

    In short

    A two-sample t-interval for μ₁ − μ₂ is (xˉ1−xˉ2)±t∗s12n1+s22n2(\bar{x}_1 - \bar{x}_2) \pm t^* \sqrt{\frac{s_1^2}{n_1} + \frac{s_2^2}{n_2}}. Use the calculator's df (2-SampTInt) or, by hand, the conservative df = smaller of n₁ − 1 and n₂ − 1. Check random (two independent samples or random assignment), 10% and normal/large sample for each group.

    What you need to know

    • Identify when a two-sample t-interval is appropriate (independent groups, not paired).
    • Verify the conditions for both groups.
    • Calculate the standard error, t* and the interval.
    • Interpret the interval in context, stating the order of subtraction.

    Worked example: an experiment

    Forty-seven volunteer students were randomly assigned to learn a topic with Method A (worked examples) or Method B (video lessons), then took the same test. Method A: n = 25, x̄ = 78.4, s = 8.2. Method B: n = 22, x̄ = 72.9, s = 9.6. Dotplots of both groups were roughly symmetric with no outliers. Construct a 95% confidence interval for the difference in mean scores.

    State. Estimate μ_A − μ_B, the difference in true mean test scores for students like these taught by Method A and Method B, with 95% confidence.

    Plan. Two-sample t-interval for μ_A − μ_B. Random: students were randomly assigned to methods. Normal/large sample: both groups have n < 30, but their dotplots show no strong skewness or outliers. (The 10% condition is not needed for random assignment.)

    SE=8.2225+9.6222≈2.62SE = \sqrt{\frac{8.2^2}{25} + \frac{9.6^2}{22}} \approx 2.62
    (78.4−72.9)±2.019(2.62)=5.5±5.29⇒(0.21, 10.79)(78.4 - 72.9) \pm 2.019(2.62) = 5.5 \pm 5.29 \quad \Rightarrow \quad (0.21,\ 10.79)

    Do. The calculator (2-SampTInt) gives df ≈ 41.6 and t ≈ 2.019, so the interval is about 0.21 to 10.79 points. With the conservative df = 21, t = 2.080 and the interval is about (0.05, 10.95), slightly wider.

    Conclude. We are 95% confident that the interval from 0.21 to 10.79 points captures the true difference in mean test scores (Method A − Method B) for students like these.

    Points that cost marks

    • Paired or two-sample? Two separate groups of students, so two-sample. If each student had used both methods, it would be paired (topic 4.2).
    • Order: 'A − B' must appear in the parameter and the conclusion.
    • Normality for both groups: a small, skewed group can invalidate the interval even if the other group is fine.
    • Scope: random assignment supports cause and effect, but these were volunteers, so the result applies to students like them.

    Two random samples (rather than an experiment) work the same way, with the 10% condition added for each sample. For example, independent random samples of 40 commuters in City A and 35 in City B, with means 34.2 and 29.5 minutes and standard deviations 9.1 and 7.4, give a 95% interval for μ_A − μ_B of about (0.90, 8.50) minutes.

    Key terms

    Two-sample t-interval
    (x̄₁ − x̄₂) ± t*·√(s₁²/n₁ + s₂²/n₂), estimating μ₁ − μ₂.
    2-SampTInt
    The calculator routine for a two-sample t-interval (use the unpooled option).
    Independent groups
    Groups made of different individuals with no pairing between them.
    Conservative degrees of freedom
    The smaller of n₁ − 1 and n₂ − 1.

    Common mistakes

    • Using a two-sample interval for before/after data.

      Before/after on the same people is paired.

    • Choosing 'pooled' on the calculator.

      Use the unpooled option; AP doesn't assume equal variances.

    • Checking normality only for the combined data.

      Check each group separately.

    How this topic is tested

    • Show the standard error with both variance terms.
    • Report df and t* together.
    • Interpret with 'difference in true mean … (group 1 − group 2)'.

    Practice questions

    Original AP-style multiple-choice questions. Pick an answer to see the explanation.

    1. Question 1 · SP 3 · Analyze Data

      s₁ = 5, n₁ = 20, s₂ = 4, n₂ = 20. The standard error of x̄₁ − x̄₂ is about:

    2. Question 2 · SP 3 · Analyze Data

      With x̄₁ − x̄₂ = 3 and conservative df = 19 (t* = 2.093), the 95% interval is about:

    3. Question 3 · SP 1 · Formulate Questions

      Which situation calls for a two-sample t-interval?

    4. Question 4 · SP 2 · Collect Data

      For a two-sample t-interval with n₁ = 15 and n₂ = 40, which normal check is needed?

    5. Question 5 · SP 3 · Analyze Data

      Using the conservative df instead of the calculator's df makes the interval:

    Free-response practice

    Write your answer first, then mark it against the scoring guide.

    Inference (interval) · 5 points

    Independent random samples of commuters: City A (n = 40) mean 34.2 min, s = 9.1; City B (n = 35) mean 29.5 min, s = 7.4.

    1. (a) Identify the procedure and verify conditions.
    2. (b) Construct a 95% interval.
    3. (c) Interpret the interval.

    Connected topics

    Frequently asked questions

    Why is df not a whole number?

    The calculator uses Welch's approximation, which gives fractional df. That's fine to report.

    Can I use z for large samples?

    Use t; with large df t is close to z anyway.

    What if the groups have very different sizes?

    The formula handles that; just check each group's conditions.

    How this shows up on the exam42 multiple-choice questions and 4 free-response questions of 10 points. See what each one asks you to do.Full-length AP Statistics practice examsUnit 4 is one of 5 units on the exam. Two timed exams in the 2027 format (42 MCQ + 4 FRQ), with explanations, scoring guides and an estimated 1–5 score. $14.99 · try 5 questions free.

    Free Unit 4 cheat sheet

    Every topic in Unit 4: Inference for Quantitative Data: Means on a few printable pages: the core idea, key terms, the two traps students fall into and what the exam asks.

    We'll use your email to tell you when new AP Statistics practice material is ready. No spam, and we'll delete it if you ask.

    Free Unit 4 practice test: 50 questions with explanations

    All topics in Unit 4: Inference for Quantitative Data: Means

    1. 4.1 Sampling Distributions for Sample Means
    2. 4.2 Constructing a Confidence Interval for a Population Mean or Population Mean Difference
    3. 4.3 Justifying a Claim Based on a Confidence Interval for a Population Mean or Population Mean Difference
    4. 4.4 Setting Up a Test for a Population Mean or Population Mean Difference
    5. 4.5 Carrying Out a Test for a Population Mean or Population Mean Difference
    6. 4.6 Sampling Distributions for the Difference Between Two Sample Means
    7. 4.7 Constructing a Confidence Interval for the Difference Between Two Population Means
    8. 4.8 Justifying a Claim Based on a Confidence Interval for the Difference Between Two Population Means
    9. 4.9 Setting Up a Test for the Difference Between Two Population Means
    10. 4.10 Carrying Out a Test for the Difference Between Two Population Means

    Other units in AP Statistics

    AP® is a trademark registered by College Board, which is not affiliated with, and does not endorse, this website.