Mean and standard deviation: comparing distributions
Measure centre and spread with the mean and standard deviation in Year 12 VCE General Mathematics. Two Bendigo bus routes can take the same time on average, yet one is reliable and the other is a lottery. The mean tells you the typical value; the standard deviation tells you how far values usually stray from it.
You will calculate the mean from lists and frequency tables, find the standard deviation with technology and by hand, and interpret it in context. You will compare two groups by centre and spread, see how one extreme value drags the mean and standard deviation, and choose between mean and median, ready for the bell-shaped normal model next.
Theory
The mean and standard deviation give the centre and spread of a distribution in two numbers. This Year 12 General Mathematics guide for students in Victoria shows how to calculate them, what they mean, how to compare two distributions, and when the median and IQR are the better choice.
The mean \(\bar{x}\) is the sum of the values divided by how many there are. It measures the centre of a distribution and uses every value.
The standard deviation \(s\) measures how spread out the values are around the mean. Each value's deviation is \(x - \bar{x}\); the deviations always add to \(0\), so they are squared, added, divided by \(n - 1\), and square-rooted. A small \(s\) means the values sit close to the mean (consistent); a large \(s\) means they are widely spread. In practice \(s\) is found with the statistics mode of a calculator, but the steps can be done by hand for a small data set.
To compare two distributions, compare their centres (which mean is higher?) and their spreads (which \(s\) is larger?), and say what each means in context. The mean and standard deviation suit symmetric data with no outliers; for skewed data or data with outliers use the median and IQR instead.
The mean of \(n\) values, and the mean from a frequency table:
The sample standard deviation:
Standard deviation by hand
- Find the mean \(\bar{x}\).
- Find each deviation \(x - \bar{x}\) (check they add to \(0\)).
- Square each deviation and add the squares.
- Divide by \(n - 1\), then take the square root.
Comparing two distributions
- Check the shape: symmetric with no outliers means use \(\bar{x}\) and \(s\); otherwise median and IQR.
- Centre: compare the means and state the difference in context.
- Spread: compare the standard deviations; the smaller \(s\) is the more consistent group.
Use a deviation table, then divide by \(n - 1 = 4\).
| \(\bar{x}\) | \(=\) | \(\dfrac{5 + 8 + 9 + 11 + 17}{5}\) |
| \(\) | \(=\) | \(\dfrac{50}{5}\) |
| \(\) | \(=\) | \(10\) |
| \(x\) | 5 | 8 | 9 | 11 | 17 |
|---|---|---|---|---|---|
| \(x - \bar{x}\) | \(-5\) | \(-2\) | \(-1\) | \(1\) | \(7\) |
| \((x - \bar{x})^2\) | \(25\) | \(4\) | \(1\) | \(1\) | \(49\) |
| \(\text{sum of squares}\) | \(=\) | \(25 + 4 + 1 + 1 + 49\) |
| \(\) | \(=\) | \(80\) |
| \(s\) | \(=\) | \(\sqrt{\dfrac{80}{5 - 1}}\) |
| \(\) | \(=\) | \(\sqrt{20}\) |
| \(\) | \(\approx\) | \(4.47\) |
The mean is \(10\) emails and the standard deviation is about \(4.47\) emails. Check: the deviations \(-5 - 2 - 1 + 1 + 7 = 0\).
| Number of pets, \(x\) | 0 | 1 | 2 | 3 | 4 |
|---|---|---|---|---|---|
| Frequency, \(f\) | 3 | 7 | 9 | 5 | 1 |
Multiply each value by its frequency, add, and divide by the total frequency.
| \(\sum f\) | \(=\) | \(3 + 7 + 9 + 5 + 1\) |
| \(\) | \(=\) | \(25\) |
| \(\sum f x\) | \(=\) | \(0 \times 3 + 1 \times 7 + 2 \times 9 + 3 \times 5 + 4 \times 1\) |
| \(\) | \(=\) | \(44\) |
| \(\bar{x}\) | \(=\) | \(\dfrac{44}{25}\) |
| \(\) | \(=\) | \(1.76\) |
| \(s\) | \(\approx\) | \(1.05\) |
The mean is \(1.76\) pets per household. Entering the values with their frequencies in the statistics mode gives \(s \approx 1.05\) pets.
Both data sets are small with no outliers, so the mean and \(s\) are suitable.
| \(\bar{x}_A\) | \(=\) | \(\dfrac{144}{6}\) |
| \(\) | \(=\) | \(24\) |
| \(s_A\) | \(=\) | \(\sqrt{\dfrac{10}{5}}\) |
| \(\) | \(\approx\) | \(1.41\) |
| \(\bar{x}_B\) | \(=\) | \(\dfrac{144}{6}\) |
| \(\) | \(=\) | \(24\) |
| \(s_B\) | \(=\) | \(\sqrt{\dfrac{278}{5}}\) |
| \(\) | \(\approx\) | \(7.46\) |
Centre: both routes have the same mean travel time, \(24\) minutes. Spread: route B's standard deviation (\(7.46\) min) is much larger than route A's (\(1.41\) min), so route A is far more consistent. A commuter who must arrive on time should choose route A.
Recalculate each statistic without \(1500\) and compare.
| \(\bar{x}\) | \(=\) | \(\dfrac{3720}{7}\) |
| \(\) | \(\approx\) | \(531.43\) |
| \(\text{median}\) | \(=\) | \(380\) |
| \(s\) | \(\approx\) | \(428.19\) |
| \(\bar{x}\text{ without 1500}\) | \(=\) | \(\dfrac{2220}{6}\) |
| \(\) | \(=\) | \(370\) |
| \(\text{median without 1500}\) | \(=\) | \(370\) |
| \(s\text{ without 1500}\) | \(\approx\) | \(33.47\) |
The single value \$1500 raises the mean from \$370 to about \$531 and the standard deviation from about \$33.47 to about \$428.19, but moves the median only from \$370 to \$380. Because the data contain an outlier, the median and IQR describe them better than the mean and standard deviation.
Common pitfalls
Frequently asked questions
What does the standard deviation tell you?
How spread out the values are around the mean. A small standard deviation means the values are close to the mean and consistent; a large one means they are widely spread.
How do you calculate standard deviation by hand?
Find the mean, subtract it from each value to get the deviations, square them, add the squares, divide by n - 1, then take the square root.
Why do we divide by n - 1?
The data are treated as a sample, and dividing by n - 1 gives the sample standard deviation s used in this course. On a calculator choose the sample standard deviation, often labelled sx.
When should you use the median and IQR instead of the mean and standard deviation?
When the distribution is skewed or has outliers. Extreme values pull the mean and standard deviation a long way, but hardly move the median and IQR.
How do you compare two distributions using the mean and standard deviation?
Compare the means to say which group is typically higher, and compare the standard deviations to say which group is more consistent. Always state both in the context of the data.