Standard Deviation Explained: Population vs Sample, With a Step-by-Step Example
Standard deviation measures how spread out a set of numbers is around its average. A small value means the numbers cluster tightly; a large value means they are widely scattered. It is one of the most useful summary statistics.
Open the Standard Deviation Calculator
Step by step: the data set 4, 8, 15, 16, 23, 42
- Mean: (4 + 8 + 15 + 16 + 23 + 42) ÷ 6 = 108 ÷ 6 = 18.
- Deviations from the mean: −14, −10, −3, −2, 5, 24.
- Square each deviation: 196, 100, 9, 4, 25, 576. Their sum is 910.
- Population variance: 910 ÷ 6 = 151.67. Population standard deviation = √151.67 = 12.32.
- Sample variance: 910 ÷ (6 − 1) = 182.00. Sample standard deviation = √182.00 = 13.49.
These match the values the calculator reports for the default numbers.
Population or sample?
Use the population formula (divide by n) when your data includes every member of the group you care about, such as the exam scores of an entire class. Use the sample formula (divide by n − 1) when your data is a subset used to estimate a larger group, such as a survey of 500 voters. Dividing by n − 1, called Bessel's correction, compensates for the fact that a sample tends to understate the true spread. With large data sets the difference is tiny; with small ones, as above, it is noticeable: 12.32 versus 13.49.
Interpreting the result
For data shaped roughly like a bell curve, about 68% of values lie within one standard deviation of the mean, about 95% within two, and about 99.7% within three. This is the empirical rule. In our example the mean is 18 and the sample standard deviation is about 13.5, so most values are expected between roughly −9 and 45. Because the data contains one large value (42), the result is pulled upward: standard deviation is sensitive to outliers.
Where it is used
- Finance: volatility of investment returns is measured as a standard deviation.
- Quality control: checking that a manufacturing process stays within tolerance.
- Education and research: describing the spread of scores or measurements.
- Weather and health: understanding how unusual a reading is compared with normal variation.
Standard deviation versus other measures
The range (maximum minus minimum) uses only two values and is easily distorted. The interquartile range focuses on the middle half of the data and resists outliers. Variance is the square of the standard deviation and is in squared units, so the standard deviation is easier to interpret because it uses the same units as your data.
Common mistakes
- Using the sample formula for a full population, or the reverse.
- Entering numbers with units or text, which the calculator ignores.
- Comparing standard deviations of data sets with very different means without considering the coefficient of variation (SD ÷ mean).
- Interpreting the empirical rule for data that is strongly skewed.
Frequently asked questions
Can standard deviation be negative?
No. It is a square root of an average of squares, so it is zero or positive. It is zero only when all values are identical.
What counts as a high standard deviation?
It depends on the context and the mean. Compare it with the mean (the coefficient of variation) or with similar data sets.
How many numbers do I need?
At least two for a sample standard deviation. More values give a more reliable estimate of the underlying spread.