Standard Deviation Calculator
This page opens the average calculator with the standard deviation as its headline figure instead of the mean. Both divisors are worked out every time: the sample standard deviation divides the sum of squared deviations by n − 1, the population standard deviation divides by n, and the Sample and Population switch decides which of the two sits at the top. Sample is the default, because a set of numbers is usually a subset of something larger. For 2, 4, 4, 4, 5, 5, 7, 9 the mean is 5 and the squared deviations add up to 32, which gives a population standard deviation of exactly 2 and a sample standard deviation of about 2.1381, each printed beside the division and the square root that produced it.
Commas, spaces, tabs, semicolons and new lines all separate values, so a column pasted straight out of a spreadsheet works. Currency symbols, percent signs and accounting parentheses are understood; anything left over is listed rather than silently dropped.
(18 + 22 + 31 + … + 83) ÷ 12 = 600 ÷ 12 = 50 The arithmetic mean: the one most people mean by “average”.
Sorted: 18, 22, 31, …, 83, an even count (12), so the median is the average of the 6th and 7th values: (46 + 51) ÷ 2 = 48.5
All 12 values appear exactly once, so nothing is more common than anything else: there is no mode. No mode is a real answer, not a failure. Adding a repeat would create one.
Largest − smallest = 83 − 18 = 65
√(sample variance) = √428.72727272727275 = 20.705730432111608 Divides by n − 1. Use this when your numbers are a sample drawn from something larger.
Σ(x − mean)² ÷ (n − 1) = 4716 ÷ 11 = 428.72727272727275 Divides by n − 1. Use this when your numbers are a sample drawn from something larger.
√(population variance) = √393 = 19.82422760159901 Divides by n. Use this when your numbers ARE the whole group.
Σ(x − mean)² ÷ n = 4716 ÷ 12 = 393 Divides by n. Use this when your numbers ARE the whole group.
(18 × 22 × 31 × … × 83)^(1/12) = 45.487558964974305 The geometric mean: the right average for growth rates, ratios and anything that multiplies.
12 ÷ (1/18 + 1/22 + … + 1/83) = 12 ÷ 0.29584565082861597 = 40.56169143061571 The harmonic mean: the right average for speeds, rates and other per-unit quantities.
18 + 22 + 31 + … + 83 = 600
Common questions
- Should I use the sample or the population standard deviation?
- Sample, unless your numbers really are every member of the group you are describing. The sample figure divides the sum of squared deviations by n − 1 and is the default here; the population figure divides by n and is right only when nothing is left out. Both are computed on every paste and both are listed, each row labelled with the divisor it used, so nothing is chosen for you behind the scenes. The gap is not cosmetic: on eight numbers the two answers differ by about 7%.
- What does the standard deviation tell me next to the mean?
- The mean says where the values sit, the standard deviation says how far they typically sit from it, in the same units as the values themselves. A standard deviation of 0 means every value is identical, and a large one next to a small mean means the values are scattered. In a roughly bell-shaped set about two thirds of the values land within one standard deviation of the mean, though the tool assumes nothing about the shape of your data: it reports the figure and its arithmetic. The mean, median and range are listed below the headline, so the spread can be read against them.
- How do you calculate standard deviation by hand?
- Subtract the mean from each value, square each difference, add the squares up, divide by n − 1 for a sample or by n for a population, then take the square root. For 2, 4, 4, 4, 5, 5, 7, 9 the mean is 5 and the squares add up to 32. Divided by 8 that is a variance of 4 and a population standard deviation of exactly 2; divided by 7 it is a sample variance of 4.571428571428571 and a sample standard deviation of 2.138089935299395. The page prints both divisions and the square root beside each figure, so every step can be checked rather than taken on trust.
- Does it show the variance as well?
- Yes. Sample variance and population variance are rows of their own, each carrying its own division, and the standard deviation row shows the square root it took of that variance. If you would rather have the variance as the big figure at the top, the Featured result menu holds it alongside standard deviation, mean, median, mode, range, geometric mean, harmonic mean and sum.
- Why does one number give no standard deviation?
- Because the sample formula divides by n − 1, which is zero when there is a single value, so the row reads Not defined and gives that reason instead of printing 0. A lone measurement has no spread to measure, and 0 would read as a finding about the data when it is only an artefact of the formula. If that one value genuinely is your whole group, the population standard deviation of 0 is the answer you want, and it is shown.
- How do I get my own numbers in?
- The box comes filled: twelve sample numbers on a first visit, or the list you last used here, so there is a real result on screen before you touch anything. Select what is in it and paste your own over the top. Commas, spaces, tabs, semicolons, pipes and new lines all separate values, so a column copied straight out of a spreadsheet works, and currency symbols, percent signs and accounting parentheses for negatives are understood. Anything that is not a number is named above the results rather than quietly dropped, because a skipped entry changes the answer without changing anything you can see.
Exact for median, mode, minimum, maximum and range. The mean, variances and standard deviations use compensated summation and are accurate to roughly 15 significant digits, not claimed as exact, because double-precision arithmetic is not.