01 · Learn the idea
Two groups, two comparisons
When you compare two groups, you make two comparisons. One is about center: which group is typically higher. You answer it with the mean or the median. The other is about variation: which group is more spread out. You answer it with the range or the interquartile range (IQR).
Often each group is a sample from a bigger population, such as all the plants that could be grown with one fertilizer. Then what you find in the two samples is your evidence about the two populations.
Eight plants grown with fertilizer A reached these heights, in centimeters: 10, 12, 12, 14, 14, 16, 16, 18. Eight plants grown with fertilizer B reached 14, 16, 17, 18, 18, 19, 20, 22. The mean for A is 112 ÷ 8 = 14 and the mean for B is 144 ÷ 8 = 18. Plants with B are typically 4 cm taller. The range is 8 cm for both groups, so the heights are about equally spread out.
Use the same measure for both groups. If either group has an outlier, compare medians and IQRs for both. To find quartiles, split the ordered list into a lower half and an upper half, leaving the median out of both halves when the count is odd. Q1 is the median of the lower half and Q3 is the median of the upper half.
02 · Build understanding
Worked example: two bus routes
Lena timed her ride to school on two bus routes for 8 days each, in minutes. Route A: 22, 24, 24, 25, 27, 28, 28, 30. Route B: 18, 19, 21, 21, 23, 24, 26, 48. Which route is faster, and which is more dependable?
Step 1: Look for outliers, because they decide which measures to use. Route B has one ride of 48 minutes, far above its other rides. So compare medians and IQRs for both routes.
Step 2: Compare the centers. For Route A the two middle values are 25 and 27, so the median is 26 minutes. For Route B they are 21 and 23, so the median is 22 minutes. Route B is typically 4 minutes faster.
Step 3: Compare the variation. Route A: the lower half is 22, 24, 24, 25, so Q1 = 24. The upper half is 27, 28, 28, 30, so Q3 = 28. The IQR is 4 minutes. Route B: the lower half is 18, 19, 21, 21, so Q1 = 20. The upper half is 23, 24, 26, 48, so Q3 = 25. The IQR is 5 minutes. On usual days the two routes are about equally steady.
Step 4: Look at the extremes. The range is 30 − 22 = 8 minutes for Route A and 48 − 18 = 30 minutes for Route B. Route B had one very bad day. Route A never did.
Step 5: Draw a conclusion and check it. Route B is usually faster, by about 4 minutes, but it can go badly wrong. Check with the means: Route A has 208 ÷ 8 = 26 and Route B has 200 ÷ 8 = 25. The means differ by only 1 minute because the 48 pulls Route B’s mean up, which is why the medians give the clearer picture.
03 · Build understanding
Worked example: two box plots
A made-up lab tested the battery life, in hours, of two phone models and drew a box plot for each. Model X: minimum 8, Q1 10, median 12, Q3 13, maximum 15. Model Y: minimum 5, Q1 9, median 14, Q3 17, maximum 20. Compare the two models.
Step 1: Compare the centers. A box plot marks the median, so use it. Model Y’s median, 14 hours, is 2 hours more than Model X’s median, 12 hours.
Step 2: Compare the variation with the IQR, the length of each box. Model X: 13 − 10 = 3 hours. Model Y: 17 − 9 = 8 hours. The middle half of Model Y’s phones are spread over much more time.
Step 3: Compare the ranges, the full length of each plot. Model X: 15 − 8 = 7 hours. Model Y: 20 − 5 = 15 hours.
Step 4: Interpret. A typical Model Y phone lasts longer, but Model Y is much less predictable. About a quarter of the Model Y phones lasted 9 hours or less, because Q1 is 9. About three quarters of the Model X phones lasted 10 hours or more, because Q1 is 10.
Step 5: Check that the conclusion matches the numbers. Y is ahead in center (14 against 12) and behind in consistency (IQR 8 against 3, range 15 against 7). A buyer who wants the longest typical life picks Y. A buyer who wants no surprises picks X.
04 · Build understanding
Say only what the numbers support
A higher center means "typically higher". It does not mean every value is higher. In the plant data, B’s median is above A’s, yet the tallest A plant, 18 cm, is taller than the shortest B plant, 14 cm. The groups overlap.
A smaller range or IQR means the group is more consistent. Whether that is good depends on the context. Consistent race times are good. Consistently low scores are not.
The other displays work the same way. From a line plot or a stem-and-leaf plot you can list every value and compute any measure. From a histogram you cannot list the values, but you can count along the bars to find which interval holds each median and compare those intervals.
Your conclusion is about the populations only if each sample represents its population. Eight rides on each route are a small sample, so say "the data suggest" and keep the claim modest.
05 · Build understanding
Three mistakes to watch for
Comparing the mean of one group with the median of the other. For the bus routes, Route A’s mean is 26 and Route B’s median is 22, and those are different kinds of center. Pick one measure and use it for both groups.
Reading a bigger spread as bigger values. Model Y’s IQR of 8 hours is larger than Model X’s 3 hours. That says Model Y’s battery lives differ more from phone to phone. It says nothing about which model lasts longer. The medians answer that.
Comparing totals when the groups are different sizes. A class of 30 that brings 3 cans per student collects 90 cans. A class of 20 that brings 4 per student collects 80. The bigger class has the bigger total even though each student brought fewer. Compare the mean or the median per student.
Apply and explain
Your turn
Two study groups took the same quiz. Group 1 scored 70, 72, 75, 76, 78, 80, 81 and 84. Group 2 scored 50, 58, 64, 70, 74, 82, 90 and 98. Kai says Group 2 did better because it has the highest score, 98. Use the median and the interquartile range of each group to respond to Kai.
Use paper or explain your thinking aloud before opening the solution.
Check your reasoning
One top score does not describe a group. Group 1 has a median of 77 and Group 2 has a median of 72, so a typical Group 1 score is 5 points higher. Group 1 has Q1 = 73.5 and Q3 = 80.5, an IQR of 7. Group 2 has Q1 = 61 and Q3 = 86, an IQR of 25. Group 1 is typically higher and much more consistent. Group 2 has the highest score but also the lowest, 50, so its scores are spread far more widely.
- Finds the medians, 77 and 72, and says Group 1 is typically higher.
- Finds the interquartile ranges, 7 and 25, and says Group 1 is more consistent.
- Explains that a single highest score does not describe a whole group.
Ready to practice?
Try the questions, get feedback, and review your reasoning.
Compare two populations: practice →