Standard Deviation Calculator
Calculate mean, variance and standard deviation (population and sample) of a data set instantly.
1,241 views
How Standard Deviation Is Calculated
Standard deviation measures how far, on average, values sit from the mean. The steps: find the mean of the data set; subtract it from each value and square the result (this removes negative signs and weights larger gaps more heavily); average those squared differences to get the variance; then take the square root to return to the original units, which gives the standard deviation.
Concretely, take the data set 2, 4, 4, 4, 5, 5, 7, 9 (n = 8). The mean is 5. The deviations from the mean are -3, -1, -1, -1, 0, 0, 2, 4; squaring each gives 9, 1, 1, 1, 0, 0, 4, 16, which sum to 32. Dividing by n = 8 gives a population variance of 4, and the square root gives a population standard deviation of 2. Dividing that same sum of 32 by n-1 = 7 instead gives a sample variance of about 4.57, and a sample standard deviation of about 2.14 — noticeably larger than the population figure from the exact same numbers.
That difference is not a rounding quirk; it is Bessel's correction. When you calculate the mean from a sample rather than knowing the true population mean, that sample mean is, by construction, the value that minimizes the sum of squared deviations for that specific sample — so measuring spread around it and dividing by n systematically underestimates the true population variance. Dividing by n-1 instead of n corrects that downward bias, which is why the sample formula is used whenever your data is a subset standing in for a larger group, not the entire group itself.
What to Know
Population (÷n) is for when your data already covers every member of the group you care about — all 30 students in one specific class, all products in one specific batch. Sample (÷n-1) is for when your data is a subset used to estimate something about a larger group you have not fully measured — a 500-person survey standing in for a national population, a handful of lab measurements standing in for a general phenomenon. Standard deviation is expressed in the same unit as the original data (kilograms, seconds, points), unlike variance, which is in squared units and harder to interpret directly — that is precisely why standard deviation, not variance, is the number usually reported. For roughly bell-shaped (normal) data, about 68% of values fall within one standard deviation of the mean and about 95% within two, which is a quick way to judge whether a given value is unusually far from typical.
Frequently Asked Questions
Population or sample — which should I use?
If your data covers the entire group you care about (every student in one class, every unit in one batch), use population (÷n). If it's a subset standing in for a larger group you have not fully measured (a survey, a handful of lab readings), use sample (÷n-1), which gives a slightly larger, unbiased estimate of that larger group's true variance.
What is Bessel's correction and why divide by n-1 for a sample?
A sample's own mean is, by definition, the value closest to all the points in that sample — so measuring spread around it and dividing by n underestimates the variance of the wider population it came from. Dividing by n-1 instead corrects that systematic downward bias, which is why the sample formula always produces a slightly larger number than the population formula on identical data.
What does a standard deviation of 5 mean?
Typical values lie within about ±5 of the mean. For roughly normal (bell-curve) data, about 68% of values fall within one standard deviation of the mean and about 95% within two — so a value more than two standard deviations away is genuinely unusual for that data set.
What is the difference between variance and standard deviation?
Variance is the average squared distance from the mean, so its unit is squared (e.g. kg² if the data is in kg) and hard to interpret directly. Standard deviation is variance's square root, expressed in the same unit as the original data — which is why it, not variance, is the number people actually quote.
Does a single outlier change the standard deviation a lot?
Yes, disproportionately. Because each deviation is squared before averaging, a value far from the mean contributes much more to the total than a typical value does — one extreme outlier can inflate the standard deviation noticeably even in an otherwise tightly clustered data set.
Similar Tools
Report a Problem
Standard Deviation Calculator
Comments
No comments yet — be the first to write one!