Skip to main content
United StatesStatisticsSyllabus dot point

How do you compute the t test statistic and P-value and conclude a test comparing two means?

Topic 7.9 Carrying Out a Test for the Difference of Two Population Means: compute the two-sample (or paired) t test statistic, find the P-value, compare to the significance level, and state a conclusion in context.

A focused answer to AP Statistics Topic 7.9, on computing the two-sample t statistic with the unpooled standard error (or the paired one-sample t statistic on differences), finding the P-value, and concluding in context, with a full worked test.

Generated by Claude Opus 4.811 min answer

Reviewed by: AI editorial process; not yet individually human-reviewed

Have a quick question? Jump to the Q&A page

Jump to a section
  1. What this topic is asking
  2. The two-sample t statistic
  3. The paired t statistic
  4. P-value, decision, and conclusion
  5. Try this

What this topic is asking

The College Board (Topic 7.9) wants you to carry out and conclude a test comparing two means: compute the two-sample t statistic with the unpooled standard error (or the paired one-sample t statistic on the differences), find the P-value, compare to α\alpha, and state a conclusion in context.

The two-sample t statistic

The numerator is the observed difference of means; the denominator is the same unpooled standard error as the two-sample interval (variances added). Unlike the proportion case, the two-sample mean test and interval use the same standard error, because there is no pooled-proportion analogue required on the AP exam by default. The degrees of freedom are messy, so report the calculator value or use the conservative smaller-dfdf choice; AP grading accepts either.

The paired t statistic

Pairing turns a two-sample problem into a one-sample problem on a single list of differences. This is why the procedure, statistic, and degrees of freedom all match Topic 7.5 applied to the differences. The payoff is that pairing removes between-subject variability, often giving a smaller standard error and more power than an independent design with the same number of measurements.

P-value, decision, and conclusion

Find the P-value from the appropriate tt-distribution in the direction of HaH_a: upper tail for >>, lower for <<, both (doubled) for \ne. Then compare to α\alpha: P-value α\le \alpha rejects H0H_0 (convincing evidence of a difference in the stated direction); P-value >α> \alpha fails to reject (not convincing evidence). The conclusion sentence states the decision, ties it to the PP-versus-α\alpha comparison, and interprets in context ("there is convincing evidence the supplement lowers the mean reaction time"). As ever, never write "accept H0H_0," and for a two-sided two-sample test, the two-sided interval at C=1αC = 1 - \alpha gives the same verdict via the zero-check.

Try this

Q1. Write the two-sample t statistic and name the standard error type. [2 points]

  • Cue. t=xˉ1xˉ2s12/n1+s22/n2t = \dfrac{\bar{x}_1 - \bar{x}_2}{\sqrt{s_1^2/n_1 + s_2^2/n_2}}; it uses the unpooled standard error.

Q2. Paired data give xˉd=3\bar{x}_d = 3, sd=6s_d = 6, n=16n = 16. Find the paired t statistic. [1 point]

  • Cue. t=36/16=31.5=2.00t = \dfrac{3}{6/\sqrt{16}} = \dfrac{3}{1.5} = 2.00, df=15df = 15.

Exam-style practice questions

Practice questions written in the style of College Board exam questions on this dot point, with worked answer explainers. The year tag is the paper they imitate, not the source.

AP 2018 (style)1 marksSection I (multiple choice). For a two-sample t-test, the test statistic is (A) xˉ1xˉ2s12/n1+s22/n2\dfrac{\bar{x}_1 - \bar{x}_2}{\sqrt{s_1^2/n_1 + s_2^2/n_2}} (B) xˉ1xˉ2sp1/n1+1/n2\dfrac{\bar{x}_1 - \bar{x}_2}{s_p\sqrt{1/n_1 + 1/n_2}} only (C) xˉ1xˉ2n1+n2\dfrac{\bar{x}_1 - \bar{x}_2}{\sqrt{n_1 + n_2}} (D) xˉdsd/n\dfrac{\bar{x}_d}{s_d/\sqrt{n}}
Show worked answer →

The correct answer is (A).

The standard two-sample t-test (unpooled) uses t=xˉ1xˉ2s12/n1+s22/n2t = \dfrac{\bar{x}_1 - \bar{x}_2}{\sqrt{s_1^2/n_1 + s_2^2/n_2}}, the difference over the unpooled standard error.

(B) is a pooled-variance version not required on the AP exam as the default. (C) is not a valid standard error. (D) is the paired statistic, used only for matched data.

AP 2022 (style)4 marksSection II (free response). Independent random samples compare a supplement to a placebo on reaction time (ms). Treatment: n1=36n_1 = 36, xˉ1=245\bar{x}_1 = 245, s1=30s_1 = 30. Placebo: n2=36n_2 = 36, xˉ2=260\bar{x}_2 = 260, s2=28s_2 = 28. Test at α=0.05\alpha = 0.05 whether the supplement lowers mean reaction time. Compute the test statistic and P-value, and conclude in context (justify in context). Use a conservative df=35df = 35.
Show worked answer →

A 4-point two-sample t-test.

(1) (1 point) Let μ1,μ2\mu_1, \mu_2 be the true mean reaction times for supplement and placebo. H0:μ1=μ2H_0: \mu_1 = \mu_2 versus Ha:μ1<μ2H_a: \mu_1 < \mu_2. Random/independent; both n30n \ge 30, so normal/large holds.
(2) (1 point) SE=30236+28236=25+21.78=46.786.84SE = \sqrt{\dfrac{30^2}{36} + \dfrac{28^2}{36}} = \sqrt{25 + 21.78} = \sqrt{46.78} \approx 6.84.
(3) (1 point) t=2452606.84=156.842.19t = \dfrac{245 - 260}{6.84} = \dfrac{-15}{6.84} \approx -2.19, conservative df=35df = 35. P-value =P(t35<2.19)0.017= P(t_{35} < -2.19) \approx 0.017.
(4) (1 point) Since 0.017<0.050.017 < 0.05, reject H0H_0. There is convincing evidence that the supplement lowers the true mean reaction time relative to placebo.

Markers reward the unpooled standard error, the t statistic, the lower-tail P-value, and a contextual conclusion.

Related dot points

Sources & how we know this