Scribe logoScribeNotes & practice
Sign inStart free
  1. Notes
  2. ›AP Statistics
  3. ›4 Inference for Quantitative Data: Means
  4. ›4.10 Carrying out a two-mean test

AP Statistics · Unit 4 · Inference for Quantitative Data: Means

4.10 Carrying out a two-mean test

Calculate a two-sample t statistic and p-value, decide whether to reject the null hypothesis, and interpret the result in context.

  • 4 min read
  • 5 parts
  • 10 questions
  • Draft
Start a Quick 5 on this topic→Jump to the 10 questions
1/5The t statistic measures the difference in standard errors
  1. 1The t statistic measures the difference in standard errors
  2. 2Technology turns the t statistic into a p-value
  3. 3Comparing the p-value with the significance level gives a decision
  4. 4A conclusion must link the decision to the context
  5. 5A p-value is not the probability that the null hypothesis is true
  6. Check your recall
  7. Practice: 10 questions
1

Part 1 of 5: The t statistic measures the difference in standard errors

A test that is already set up needs one number that summarizes the data. That number is the t statistic. It divides the observed difference in sample means by its standard error.

Use t=(xˉ1−xˉ2)−0s12n1+s22n2t=\frac{(\bar{x}_1-\bar{x}_2)-0}{\sqrt{\frac{s_1^2}{n_1}+\frac{s_2^2}{n_2}}}t=n1​s12​​+n2​s22​​​(xˉ1​−xˉ2​)−0​. The denominator combines the variability from both samples. A large value of ∣t∣|t|∣t∣ means the sample difference is far from 0 compared with chance variation.

Keep extra digits in the denominator and round only the final answer. When the null hypothesis is true, the statistic follows a ttt distribution. That lets us judge whether a given value is unusual. Check the conditions from the setup step first.

Worked example

Calculating t

Students used a new study app or a printed guide, assigned at random. The app group has n1=40n_1=40n1​=40, xˉ1=78.4\bar{x}_1=78.4xˉ1​=78.4, and s1=9.6s_1=9.6s1​=9.6. The guide group has n2=38n_2=38n2​=38, xˉ2=74.1\bar{x}_2=74.1xˉ2​=74.1, and s2=10.2s_2=10.2s2​=10.2. Calculate ttt for H0:μ1−μ2=0H_0:\mu_1-\mu_2=0H0​:μ1​−μ2​=0.
  1. 1
    Word equation: ttt equals the observed difference minus the null value, over the standard error.
  2. 2
    Symbol equation: t=(xˉ1−xˉ2)−0s12n1+s22n2t=\frac{(\bar{x}_1-\bar{x}_2)-0}{\sqrt{\frac{s_1^2}{n_1}+\frac{s_2^2}{n_2}}}t=n1​s12​​+n2​s22​​​(xˉ1​−xˉ2​)−0​.
  3. 3
    Substitute: t=(78.4−74.1)−09.6240+10.2238t=\frac{(78.4-74.1)-0}{\sqrt{\frac{9.6^2}{40}+\frac{10.2^2}{38}}}t=409.62​+3810.22​​(78.4−74.1)−0​.
  4. 4
    Evaluate the variance terms: 9.6240=2.304\frac{9.6^2}{40}=2.304409.62​=2.304 and 10.2238≈2.738\frac{10.2^2}{38}\approx 2.7383810.22​≈2.738.
  5. 5
    Find the standard error: 2.304+2.738≈2.245\sqrt{2.304+2.738}\approx 2.2452.304+2.738​≈2.245.
  6. 6
    Divide: t=4.32.245≈1.92t=\frac{4.3}{2.245}\approx 1.92t=2.2454.3​≈1.92.

Answer: t≈1.92t\approx 1.92t≈1.92. Technology gives about 75.1 degrees of freedom.

Key term

t statistic

The t statistic is the test statistic for a mean or mean difference, using sample standard deviations to estimate the standard error.

Part 1 done

2

Part 2 of 5: Technology turns the t statistic into a p-value

The next question is how unusual that value would be if the means were equal. Assume the null hypothesis is true. The p-value is the probability of getting a statistic this extreme or more, in the direction of HaH_aHa​.

Use technology to find it. On a calculator, choose the two-sample t-test, enter the summary statistics, and select the alternative. Software also reports the degrees of freedom. A small p-value means the observed difference would be unusual if the means were equal.

Figure 1. The shaded tail beyond the observed t value shows the p-value for a one-sided test.

A one-sided test uses one tail area. A two-sided test doubles the tail area, because extreme results in either direction count against H0H_0H0​.

Key term

p-value

The p-value is the probability, assuming H0H_0H0​ is true, of a test statistic at least as extreme as observed, in the direction of HaH_aHa​.

Part 2 done

Quick check

One question on the part you just read

Easy

Identify what the p-value in a two-mean test measures.
Show answer and explanation

Answer: C · Worked explanation

The p-value is calculated assuming H0H_0H0​ is true and gives the probability of a statistic at least as extreme as the one observed. It is not the probability that H0H_0H0​ or HaH_aHa​ is true, because hypotheses are claims about parameters, not random events. It also does not give the size of the difference.
3

Part 3 of 5: Comparing the p-value with the significance level gives a decision

A p-value needs a standard for “small enough.” The significance level, α\alphaα, sets that standard before the data are examined. Common choices are 0.05 and 0.01. Choose it before looking at the data. Choosing afterward would let the result set its own standard.

If the p-value is less than or equal to α\alphaα, reject H0H_0H0​. The result then has statistical significance. If the p-value is greater than α\alphaα, fail to reject H0H_0H0​.

Decision rule for a test with significance level \lpha

ComparisonDecision about H0H_0H0​Evidence for HaH_aHa​
p-value ≤α\le\alpha≤αRejectConvincing
p-value >α>\alpha>αFail to rejectNot convincing
Comparison
p-value ≤α\le\alpha≤α
Decision about H0H_0H0​
Reject
Evidence for HaH_aHa​
Convincing
Comparison
p-value >α>\alpha>α
Decision about H0H_0H0​
Fail to reject
Evidence for HaH_aHa​
Not convincing

Common mistake

Never write “accept H0H_0H0​” or “prove HaH_aHa​.” A large p-value means the data are consistent with H0H_0H0​, not that H0H_0H0​ is true.

Key terms · tap one for its definition

significance level

The significance level is the cutoff α\alphaα, chosen before seeing the data; a p-value at or below it leads to rejecting H0H_0H0​.

statistical significance

Statistical significance is the status of a result whose p-value is less than or equal to the significance level.

Part 3 done

4

Part 4 of 5: A conclusion must link the decision to the context

A decision alone is incomplete. A full conclusion compares the p-value with α\alphaα, states the decision about H0H_0H0​, and answers in context. It refers to the population means, not only to the samples.

A reliable pattern has two sentences. First: “Because the p-value of ___ is less (or greater) than α=\alpha=α= ___, we reject (or fail to reject) H0H_0H0​.” Second: “There is (or is not) convincing statistical evidence that [claim in context].”

Worked example

Writing a conclusion

The app study has Ha:μ1−μ2>0H_a:\mu_1-\mu_2>0Ha​:μ1​−μ2​>0, t≈1.92t\approx 1.92t≈1.92, and a p-value of about 0.030. Use α=0.05\alpha=0.05α=0.05. Write the conclusion.
  1. 1
    Compare: 0.030<0.050.030<0.050.030<0.05.
  2. 2
    The p-value is below the significance level, so reject H0H_0H0​.
  3. 3
    Answer in context, about the mean quiz scores.

Answer: Because the p-value of 0.030 is less than 0.05, we reject H0H_0H0​. There is convincing statistical evidence that the true mean score is higher with the app than with the printed guide.

Exam tip

A conclusion without the p-value comparison or without context is incomplete.

Part 4 done

Quick check

One question on the part you just read

Easy

A two-mean test gives a p-value of 0.012, and the significance level is α=0.05\alpha=0.05α=0.05. Determine the decision about H0H_0H0​.
Show answer and explanation

Answer: A · Worked explanation

A p-value at or below α\alphaα leads to rejecting H0H_0H0​, and 0.012 is below 0.05. Saying fail to reject confuses a small p-value with a large one. Accepting H0H_0H0​ is never the wording used, and the null hypothesis, not the alternative, is the one rejected.
5

Part 5 of 5: A p-value is not the probability that the null hypothesis is true

Take the app study, where the p-value is 0.030. Suppose the true means were equal. A sample difference of 4.3 points or more would then occur by chance about 3% of the time.

The p-value is not the probability that H0H_0H0​ is true. It also says nothing about how large or important the difference is. A tiny difference can give a small p-value when samples are large.

The scope of the conclusion depends on the design. Random sampling lets you generalize to the population sampled. Random assignment supports a cause-and-effect conclusion.

Note read

Check your recall[13 marks]

5 written questions. Answer each one in your head or on paper, then open the mark scheme.

  1. 1.Calculate[3 marks]

    Calculate the test statistic for H0:μ1−μ2=0H_0:\mu_1-\mu_2=0H0​:μ1​−μ2​=0 using xˉ1=52.0\bar{x}_1=52.0xˉ1​=52.0, s1=6.0s_1=6.0s1​=6.0, n1=36n_1=36n1​=36, xˉ2=48.0\bar{x}_2=48.0xˉ2​=48.0, s2=8.0s_2=8.0s2​=8.0, and n2=64n_2=64n2​=64.

    Show mark schemeHide mark scheme

    Model answer

    t=(52.0−48.0)−06.0236+8.0264=4.02.0≈2.83t=\frac{(52.0-48.0)-0}{\sqrt{\frac{6.0^2}{36}+\frac{8.0^2}{64}}}=\frac{4.0}{\sqrt{2.0}}\approx 2.83t=366.02​+648.02​​(52.0−48.0)−0​=2.0​4.0​≈2.83.

    • 1 mark for substituting the values into the two-sample ttt formula
    • 1 mark for obtaining a standard error of 1.0+1.0=2.0≈1.414\sqrt{1.0+1.0}=\sqrt{2.0}\approx 1.4141.0+1.0​=2.0​≈1.414
    • 1 mark for obtaining t≈2.83t\approx 2.83t≈2.83
  2. 2.Determine[3 marks]

    A two-sided test of whether mean sleep differs for students who use a bedtime app and students who do not gives a p-value of 0.082. Determine the decision at α=0.05\alpha=0.05α=0.05 and give the conclusion in context.

    Show mark schemeHide mark scheme

    Model answer

    The p-value of 0.082 is greater than 0.05, so we fail to reject H0H_0H0​. There is not convincing statistical evidence that mean sleep differs between app users and non-users.

    • 1 mark for comparing 0.082 with 0.05 and noting the p-value is larger
    • 1 mark for deciding to fail to reject H0H_0H0​
    • 1 mark for concluding in context that there is not convincing evidence of a difference in mean sleep
  3. 3.Interpret[3 marks]

    A test of whether a new fertilizer raises mean yield (Ha:μ1−μ2>0H_a:\mu_1-\mu_2>0Ha​:μ1​−μ2​>0) gives a p-value of 0.04. Interpret this p-value in context.

    Show mark schemeHide mark scheme

    Model answer

    If the true mean yields were equal, there would be about a 4% probability of getting a sample difference in mean yield at least as large as the one observed, just by chance.

    • 1 mark for assuming the true mean yields are equal
    • 1 mark for giving the probability as about 4% (0.04)
    • 1 mark for referring to a sample difference in mean yield at least as large as observed, by chance
  4. 4.Explain[2 marks]

    Explain why a p-value of 0.04 does not mean there is a 4% chance that H0H_0H0​ is true.

    Show mark schemeHide mark scheme

    Model answer

    The p-value is calculated assuming H0H_0H0​ is true. It gives the probability of data at least this extreme, not the probability that the hypothesis itself is true.

    • 1 mark for stating that the p-value is computed assuming H0H_0H0​ is true
    • 1 mark for stating that it is a probability about the data, not about the hypothesis
  5. 5.Describe[2 marks]

    Describe how the p-value for a two-sided test is found from the t curve.

    Show mark schemeHide mark scheme

    Model answer

    Find the area in the tail beyond the observed t value. Double that area, because results as extreme in either direction count.

    • 1 mark for finding the tail area beyond the observed t value
    • 1 mark for doubling it to include both directions

Practice this topic

10 quick-fire multiple-choice questions, easy to hard. Tap an answer to see if you're right and the worked explanation. (The written questions with mark schemes are under “Check your recall” above.)

0 right0 of 10 answered

Includes the 2 quick checks in the note above.

3.

Easy·Identify[1 mark]

A test of H0:μ1−μ2=0H_0:\mu_1-\mu_2=0H0​:μ1​−μ2​=0 against Ha:μ1−μ2≠0H_a:\mu_1-\mu_2\neq 0Ha​:μ1​−μ2​=0 for mean battery life of two brands gives a p-value of 0.20, with α=0.05\alpha=0.05α=0.05. Identify the correct conclusion.
Show answer and explanation

Answer: D · Worked explanation

The p-value of 0.20 is greater than 0.05, so we fail to reject the null hypothesis. That means the data do not give convincing evidence of a difference. It does not show the means are equal; the data are only consistent with that possibility.
4.

Medium·Calculate[1 mark]

Group 1 has xˉ1=18.6\bar{x}_1=18.6xˉ1​=18.6, s1=3.0s_1=3.0s1​=3.0, and n1=25n_1=25n1​=25. Group 2 has xˉ2=16.2\bar{x}_2=16.2xˉ2​=16.2, s2=4.0s_2=4.0s2​=4.0, and n2=16n_2=16n2​=16. Calculate ttt for H0:μ1−μ2=0H_0:\mu_1-\mu_2=0H0​:μ1​−μ2​=0.
Show answer and explanation

Answer: B · Worked explanation

The variance terms are 3.0225=0.36\frac{3.0^2}{25}=0.36253.02​=0.36 and 4.0216=1.00\frac{4.0^2}{16}=1.00164.02​=1.00. Then 1.36≈1.166\sqrt{1.36}\approx 1.1661.36​≈1.166 and t=2.41.166≈2.06t=\frac{2.4}{1.166}\approx 2.06t=1.1662.4​≈2.06. The value 1.76 comes from dividing by 1.36, forgetting the square root. The value 1.50 adds the standard errors 0.6 and 1.0 instead of the variance terms.
5.

Medium·Calculate[1 mark]

A one-sided test gives a p-value of 0.034 for a test statistic in the direction of HaH_aHa​. Calculate the p-value if the same data are used for a two-sided test.
Show answer and explanation

Answer: B · Worked explanation

A two-sided test counts extreme results in both directions, so the tail area is doubled: 2×0.034=0.0682\times 0.034=0.0682×0.034=0.068. Halving to 0.017 moves the wrong way. Keeping 0.034 ignores the second tail, and 0.966 is the area on the other side of the observed value.
6.

Medium·Interpret[1 mark]

A test of whether students who use a bedtime app sleep longer, on average, gives a p-value of 0.03. Interpret this p-value.
Show answer and explanation

Answer: D · Worked explanation

The p-value is a probability about the sample result under the assumption that the true means are equal. It is not the probability that the null hypothesis is true, and it is not a percentage of students. Subtracting from 1 to get 97% also misreads it as a probability that the alternative is true.
7.

Medium·Determine[1 mark]

A test gives a p-value of 0.047. Determine which decisions are correct.
Show answer and explanation

Answer: A · Worked explanation

Reject H0H_0H0​ when the p-value is at or below α\alphaα. Since 0.047≤0.050.047\le 0.050.047≤0.05, reject at the 0.05 level. Since 0.047>0.010.047>0.010.047>0.01, fail to reject at the 0.01 level. Claiming rejection at 0.01 but not at 0.05 reverses the rule, treating a smaller α\alphaα as easier to meet, and the two 'both' choices ignore that the decision depends on the level.
8.

Hard·Determine[2 marks]

Group 1 has n1=50n_1=50n1​=50, xˉ1=82.0\bar{x}_1=82.0xˉ1​=82.0, s1=10.0s_1=10.0s1​=10.0. Group 2 has n2=50n_2=50n2​=50, xˉ2=78.0\bar{x}_2=78.0xˉ2​=78.0, s2=10.0s_2=10.0s2​=10.0. For Ha:μ1−μ2>0H_a:\mu_1-\mu_2>0Ha​:μ1​−μ2​>0, technology gives a p-value of 0.024 for the correct statistic. Determine ttt and the decision at α=0.05\alpha=0.05α=0.05.
Show answer and explanation

Answer: C · Worked explanation

The standard error is 10050+10050=2\sqrt{\frac{100}{50}+\frac{100}{50}}=250100​+50100​​=2, so t=4.02=2.00t=\frac{4.0}{2}=2.00t=24.0​=2.00. The p-value 0.024 is below 0.05, so reject H0H_0H0​. Judging by the raw size of the difference ignores the standard error. The value t=1.00t=1.00t=1.00 forgets the square root, and t=0.40t=0.40t=0.40 divides by sss alone.
9.

Hard[2 marks]

Sixty volunteers are randomly assigned to a new drug or a placebo. A test of Ha:μ1−μ2>0H_a:\mu_1-\mu_2>0Ha​:μ1​−μ2​>0 for mean symptom relief gives a p-value of 0.004, with α=0.05\alpha=0.05α=0.05. Which conclusion is justified?
Show answer and explanation

Answer: D · Worked explanation

The p-value is below 0.05, so there is convincing evidence for the alternative. Random assignment supports a cause-and-effect conclusion, but volunteers limit generalization to people like them. A significant result is never proof for every patient, and a p-value need not be exactly 0 to support rejecting the null hypothesis.
10.

Hard[2 marks]

Study A has 2,000 students per group, a difference in sample means of 0.5 points, and a p-value of 0.001. Study B has 15 students per group, a difference of 8 points, and a p-value of 0.08. Which statement is correct at α=0.05\alpha=0.05α=0.05?
Show answer and explanation

Answer: A · Worked explanation

A smaller p-value means stronger evidence against H0H_0H0​, and Study A’s large samples let a small difference stand out from chance variation. The p-value does not measure the size of the difference. Study B failing to reject does not show that no difference exists; its small samples simply give less evidence.

Keep going

Next topic5.1 ScatterplotsPrevious topic4.9 Setting up a two-mean test

More in Unit 4 · Inference for Quantitative Data: Means

  1. 4.2Interval for a mean or mean differenceNotes · 10 questions
  2. 4.3Claims from a mean intervalNotes · 10 questions
  3. 4.4Setting up a test for a mean or mean differenceNotes · 10 questions
  4. 4.5Carrying out a test for a mean or mean differenceNotes · 10 questions
  5. 4.6Differences in sample meansNotes · 10 questions
  6. 4.7Interval for a difference of two meansNotes · 10 questions
  7. 4.8Claims about a difference of meansNotes · 10 questions
  8. 4.9Setting up a two-mean testNotes · 10 questions
  9. 4.10Carrying out a two-mean testNotes · 10 questions

All AP Statistics topics →

Draft: written by Scribe and checked automatically, not yet by a subject reviewer.

Practice questions are original, written by Scribe and checked automatically for correctness.

Topic codes follow the official numbering. Not endorsed by College Board or any exam board.

On this page

0/5 read

  1. 1The t statistic measures the difference in standard errors
  2. 2Technology turns the t statistic into a p-value
  3. 3Comparing the p-value with the significance level gives a decision
  4. 4A conclusion must link the decision to the context
  5. 5A p-value is not the probability that the null hypothesis is true
  6. Check your recall
  7. Practice: 10 questions
All coursesScribeHow it worksPricingPrivacyTerms

Notes and questions are written by Scribe in our own words. Topic codes follow the official course numbering so you can find your place. Not produced or endorsed by the IB, College Board, AQA, OCR, Pearson Edexcel or any exam board.

© 2026 Scribe