Skip to main content

Unit 4 · Topic 4.2

4.2 Constructing a Confidence Interval for a Population Mean or Population Mean Difference

When σ is unknown, which is almost always, you estimate a population mean with a one-sample t-interval, x̄ ± t*·s/√n. The same method handles matched pairs: take the difference within each pair and build the interval on those differences.

Key terms

  • t-distribution
  • degrees of freedom (df = n − 1)
  • critical value t*
  • standard error s/√n
  • one-sample t-interval
  • mean difference (paired data)

Why t instead of z

In real problems you don't know σ, so you replace it with the sample standard deviation s. That adds extra uncertainty, and the standardized statistic follows a t-distribution instead of the standard normal.

t-distributions are symmetric, bell-shaped and centered at 0, but with heavier tails than the standard normal: more area far from the center. Each one is identified by its degrees of freedom (df). For one sample, df = n − 1. With small df the tails are much heavier; as df grows, the t-distribution gets closer and closer to the standard normal.

Critical values

t* is the value with the middle C% of the t-distribution (df = n − 1) between −t* and t*. Use invT or the t-table. Because the tails are heavier, t* is always bigger than the matching z*, which makes t-intervals a little wider.

For 95% confidence: df = 5 gives t* ≈ 2.571, df = 19 gives 2.093, df = 29 gives 2.045, and as df gets very large, t* approaches 1.960. If your df isn't in the table, use the next smaller df listed; it gives a slightly wider, safer interval.

The interval and conditions

One-sample t-interval for μ: x̄ ± t* · s/√n. The standard error is SE = s/√n and the margin of error is t* × SE.

  • Random: a random sample or a randomized experiment.
  • 10%: when sampling without replacement, n ≤ 10% of N.
  • Normal/sample data: n ≥ 30; or you're told the population is roughly normal; or, for a smaller sample, a graph of the data shows no strong skew and no outliers.

Matched pairs

When the data come in pairs, like before-and-after scores on the same students or twins split between two treatments, the two sets of values are dependent. Don't treat them as two separate samples. Instead, compute the difference for each pair, then do a one-sample t-interval on those differences: x̄d ± t* · sd/√nd, where x̄d is the mean difference, sd is the standard deviation of the differences and nd is the number of pairs.

The parameter is μd, the true mean difference. State the order of subtraction, like after − before. Check the normal condition on the differences, not on the original values.

Student12345678
Before6874815970778562
After8079786780838571
Difference (after − before)125−3810609

Worked examples

Try each one yourself first, then open the solution.

  1. Example 1Calculator allowed

    One-sample t-interval

    A random sample of 20 students at a large high school reports a mean of 6.8 hours of sleep on school nights, with s = 1.2 hours. A dotplot of the data shows no strong skew or outliers. Construct a 95% confidence interval for the mean sleep of all students at the school.

    Show the solution
    1. Step 1: Procedure: one-sample t-interval for μ = the true mean hours of sleep on school nights for all students at the school.
    2. Step 2: Random: random sample. 10%: 20 is less than 10% of a large school. Normal: n < 30, but the dotplot shows no strong skew or outliers.
    3. Step 3: df = 19, t* ≈ 2.093. SE = 1.2/√20 ≈ 0.268.
    4. Step 4: Margin of error: 2.093 × 0.268 ≈ 0.56.
    5. Step 5: Interval: 6.8 ± 0.56 = (6.24, 7.36).

    Answer: (6.24, 7.36) hours. We are 95% confident that the interval from 6.24 to 7.36 hours captures the true mean sleep on school nights for all students at the school.

  2. Example 2Calculator allowed

    Paired t-interval

    Eight randomly selected students from a large school took a practice test before and after a review session (table above). Construct a 95% confidence interval for the true mean improvement (after − before).

    Show the solution
    1. Step 1: These are paired data (same students), so work with the differences: 12, 5, −3, 8, 10, 6, 0, 9.
    2. Step 2: Parameter: μd = the true mean difference (after − before) in practice test score for all students at the school.
    3. Step 3: Conditions: random sample of students; 8 is less than 10% of a large school; the 8 differences show no strong skew or outliers (by the 1.5 × IQR rule, the fences are −8 and 20).
    4. Step 4: x̄d = 5.875, sd ≈ 5.11, nd = 8, df = 7, t* ≈ 2.365.
    5. Step 5: SE = 5.11/√8 ≈ 1.807. Margin of error ≈ 2.365 × 1.807 ≈ 4.27.
    6. Step 6: Interval: 5.875 ± 4.27 = (1.60, 10.15).

    Answer: (1.60, 10.15) points. We are 95% confident that the interval from 1.60 to 10.15 points captures the true mean improvement (after − before) for all students at the school.

  3. Example 3Calculator allowed

    Trap: using z* with s

    A student builds the sleep interval with z* = 1.96 instead of t*. What goes wrong?

    Show the solution
    1. Step 1: With s in place of σ, the statistic follows a t-distribution with 19 df, not a normal distribution.
    2. Step 2: 1.96 is smaller than 2.093, so the margin of error is too small (0.53 instead of 0.56).
    3. Step 3: The interval would capture μ less than 95% of the time.

    Answer: The interval is too narrow. Use t* with df = n − 1 whenever σ is estimated by s.

Common mistakes

  • Using z* when σ is unknown.
  • Treating paired data as two independent samples.
  • Checking normality on the original values instead of the differences for paired data.
  • Writing "n ≥ 30" as the only check when n is smaller. Then you need to look at a graph of the data.

On the exam

  • When n < 30, say what you looked at: "A dotplot of the sample shows no strong skew or outliers." Sketching the graph helps.
  • For matched pairs, name the procedure as a one-sample t-interval for μd and state the order of subtraction.

Connected topics

Videos

  • AP Stats 4.A.2 - Interval for a Mean

    Skew The ScriptWatch on YouTube (opens in a new tab)

  • AP Statistics | One Sample t-Interval for a Mean (Step-by-Step + TI-84, NumWorks & Desmos)

    Michael Porinchak - AP Statistics & AP PrecalculusWatch on YouTube (opens in a new tab)

  • Introduction to the t Distribution (non-technical)

    jbstatisticsWatch on YouTube (opens in a new tab)

  • AP Stats 4.A.3 - Interval for a Mean Difference

    Skew The ScriptWatch on YouTube (opens in a new tab)

  • Confidence interval for a mean with paired data | AP Statistics | Khan Academy

    Khan AcademyWatch on YouTube (opens in a new tab)

  • Example constructing a t interval for a mean | Confidence intervals | AP Statistics | Khan Academy

    Khan AcademyWatch on YouTube (opens in a new tab)

Check yourself

4 questions on 4.2 Constructing a Confidence Interval for a Population Mean or Population Mean Difference. Pick an answer to see if you got it, and why.

Question 1 of 4Calculator allowed

How does a t-distribution with 5 degrees of freedom compare with the standard normal distribution?

Question 2 of 4Calculator allowed

A researcher builds a 90% confidence interval for a population mean from a random sample of 15 observations. What is the critical value t*?

Question 3 of 4Calculator allowed

A random sample of 16 commuters has a mean commute of 27 minutes and a standard deviation of 8 minutes. What is the standard error of the sample mean?

Question 4 of 4Calculator allowed

Twenty randomly selected drivers each test a car's fuel economy with two kinds of fuel, in random order. The differences (premium − regular) have mean x̄d = 3.1 miles per gallon and standard deviation sd = 4.2 miles per gallon. Which is a 95% confidence interval for μd?

0 of 4 answered