The Wilcoxon Rank-Sum Test for Two Independent Samples | OCR A Level Further Maths notes
Free preview: The Wilcoxon Rank-Sum Test for Two Independent Samples
Comparing Two Groups by Ranks
Year 1 or Year 2: the rank-sum test is in OCR A's Statistics option (5.07); check your own specification for which year.
Let's start with the problem. A gardener tries a new fertiliser on 5 plots and the old one on 7. Two independent groups, small samples, and no reason to think yields are Normal. A two-sample t-test is out. Here's a clever trick: forget the actual numbers, put all the values in one line in order, and see whether one group bunches at the top.
- That is the Wilcoxon rank-sum test: it compares the groups using only the order of the values.
- : the two populations have the same distribution (in particular, the same median).
- : one population tends to have larger values (one-tailed), or their medians differ (two-tailed).
- Assumptions: the samples are independent and random, and the two distributions have the same shape (so a difference means a shift).
The method
- Label the sizes. Call the smaller sample size m and the larger n.
- Rank everything together, all m + n values, from 1 (smallest). Tied values share the average rank. Why together? We want to see where each group sits in the combined order.
- Add up the ranks of the smaller sample: .
- Find the mirror sum , the rank sum the smaller sample would have if the order were reversed.
- Choose T: whichever of these predicts to be small (two-tailed: the smaller of the two).
- Decide: reject if T is less than or equal to the table's critical value.
💡 In plain words
- If the groups are alike, the ranks are well mixed, and the smaller sample's rank sum is about .
- If one group is mostly at the bottom of the ordering, its rank sum is very small: evidence of a difference.
Critical values for W (reject if T ≤ value)
| m, n | one-tail 5% | one-tail 2.5% | one-tail 1% |
|---|---|---|---|
| 4, 6 | 13 | 12 | 11 |
| 5, 7 | 21 | 20 | 18 |
| 5, 8 | 23 | 21 | 19 |
| 6, 8 | 31 | 29 | 27 |
| 6, 9 | 33 | 31 | 28 |
| 8, 10 | 56 | 53 | 49 |
- A two-tailed 5% test uses the 2.5% column, as usual.
👀 Watch me do it: 3 phones of brand S last 14, 9 and 17 hours; 5 phones of brand L last 11, 20, 16, 22 and 18 hours. Find W, its mirror and the value expected under
| What I write | Why I do it |
|---|---|
| m = 3 (S), n = 5 (L) | Step 1: the smaller sample is S. |
| Combined order: 9, 11, 14, 16, 17, 18, 20, 22 with ranks 1 to 8 | Step 2: rank all 8 together. |
| S has 9 (rank 1), 14 (rank 3), 17 (rank 5) | Pick out the smaller sample's ranks. |
| Step 3. | |
| Mirror | Step 4: S's rank sum if the order were reversed. |
| Expected , halfway between 9 and 18 | W = 9 is below it: S's phones sit low in the order. Whether that is low enough is what the table decides. |
✏️ YOUR TURN 1
Try this first:
Samples of 4 and 6 are ranked together. The smaller sample has ranks 2, 3, 5, 7. Find W, the mirror sum, and the value expected under .
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.
All notes in Non-Parametric Tests
- Non-Parametric Tests and the Sign Test for a Median
- The Wilcoxon Signed-Rank Test: Single Samples and Paired Data
- The Wilcoxon Rank-Sum Test for Two Independent Samples
What's inside for this topic
3 teacher notes, 68 practice questions, 45 flashcards, 2 quizzes.
Get the full notes, every practice question, flashcards, quizzes and mock papers.
Previous note: The Wilcoxon Signed-Rank Test: Single Samples and Paired Data
All OCR A Level Further Maths topics · A Level Further Maths