Testing for a Difference Between Two Population Means | Cambridge A Level Maths notes

Free preview: Testing for a Difference Between Two Population Means

Comparing Two Means

9231 Paper 4: Further Probability & Statistics

Let's start with a typical question: do two machines, two schools or two diets give the same average? We take a sample from each and compare the sample means. But two sample means will always differ a bit, even if the populations are identical. So the real question is: is the gap bigger than chance alone would produce?

  • Population X has mean μx, variance σx2; population Y has mean μy, variance σy2.
  • The samples must be independent: different, unrelated individuals in each.
  • We look at the difference X¯−Y¯.

The distribution of the difference

We build it from what we know about one sample mean, one step at a time.

  1. Each mean on its own: X¯ has mean μx and variance σx2nx; Y¯ has mean μy and variance σy2ny.
  2. Mean of the difference: E(X¯−Y¯)=μx−μy. Expectations subtract.
  3. Variance of the difference: for independent variables, variances add, even for a difference: Var(X¯−Y¯)=σx2nx+σy2ny.
  4. Shape: exactly Normal if both populations are Normal; approximately Normal by the CLT if both samples are large.

z=(x¯−y¯)−(μx−μy)σx2nx+σy2ny

  • Under H0:μx=μy the part (μx−μy) is 0.
  • For large samples with unknown variances, use sx2 and sy2 in place of σx2 and σy2.

💡 In plain words

  • Same idea as a one-sample test: how many standard errors is the observed difference from the difference claimed in H0?
  • The standard error combines the uncertainty from both samples.

✏️ YOUR TURN 1

Try this first:

X is Normal with standard deviation 3 and Y is Normal with standard deviation 4. Samples of 10 from X and 8 from Y are taken independently. State the distribution of X¯−Y¯ if μx=μy, and find its standard error.

Answer:

  • Variance 910+168=0.9+2=2.9.
  • X¯−Y¯~N(0,2.9) exactly (both populations Normal).
  • Standard error 2.9=1.703.

A Two-Sample Test, Step by Step

Method: two-sample z-test

  1. Hypotheses about the two population means, e.g. H0:μA=μB, H1:μA≠μB. Define both in context.
  2. Justify the Normal model: both populations Normal, or both samples large (CLT).
  3. Standard error: work out sA2nA and sB2nB separately, add, square root.
  4. z: observed difference minus the difference in H0, divided by the standard error.
  5. Compare with the critical value from the tables.
  6. Conclude in context.

👀 Watch me do it: two machines make rods. Machine A: 50 rods, x¯A=32.4 mm, sA=4.1. Machine B: 60 rods, x¯B=30.9 mm, sB=3.8. Test at 5% whether the machines have different mean lengths

What I writeWhy I do it
H0:μA=μB, H1:μA≠μBStep 1: "different" means two-tailed. μA,μB are the mean lengths of all rods from each machine.
Both samples are large, so by the CLT X¯A−X¯B is approximately Normal, and we use sA,sBStep 2.
4.1250+3.8260=0.3362+0.2407=0.7595Step 3.
z=32.4−30.90.7595=1.975Step 4: H0 difference is 0.
Critical values ±1.96. 1.975>1.96, so reject H0 (only just)Step 5: two-tailed 5%.
There is sufficient evidence at the 5% level to suggest the two machines have different mean lengthsStep 6.

Unlock the full note: start 7 days free.

Log in or subscribe to read the rest of this note. Members also get the AI tutor, practice quizzes, mock exams and flashcards for this topic.

Log in · Subscribe · Start free trial

All notes in Inference using normal and t-distributions (4.2)

  1. Large-Sample Confidence Intervals, Sample Size and Differences of Means
  2. Testing for a Difference Between Two Population Means
  3. Student's t-Distribution and t-Intervals for a Mean
  4. The One-Sample t-Test for a Mean
  5. Paired and Two-Sample t-Tests with a Pooled Variance

What's inside for this topic

5 teacher notes, 110 practice questions, 38 flashcards, 2 quizzes.

Get the full notes, every practice question, flashcards, quizzes and mock papers.

Start your free 7-day trial

Questions? Chat with us on WhatsApp · Try one live lesson

Previous note: Large-Sample Confidence Intervals, Sample Size and Differences of Means Next note: Student's t-Distribution and t-Intervals for a Mean

Testing for a Difference Between Two Population Means on other exam boards

All Cambridge A Level Maths topics · A Level Maths