Variance Calculator
The mean squared deviation. Standard deviation before the square root is taken.
The formulas
Variance is the mean squared deviation from the mean. Take the square root and you have the standard deviation; the two carry identical information in different units.
The units problem
Squaring the deviations squares the units too. Variance on a set of heights in centimetres comes out in square centimetres — a quantity with no physical meaning. That is the main reason reports quote standard deviations instead.
Variance earns its keep in the mathematics rather than the reporting. It adds: the variance of a sum of independent variables is the sum of their variances, which is not true of standard deviations. That property is what makes variance the natural currency of analysis of variance, portfolio theory and error propagation.
Why the sample divisor is n − 1
A sample's values cluster more tightly around their own mean than around the unknown population mean, because the sample mean is computed from those very values. Dividing by n would therefore underestimate the population variance consistently — not occasionally, but on average, every time. Using n − 1 removes that bias exactly.
The intuition: once you know the mean and n − 1 of the deviations, the last one is determined, since the deviations must sum to zero. Only n − 1 of them are free to vary.
Worked example
Both divisors on the same data
Mean = 18. Sum of squared deviations = 192.
- Population variance σ² = 192 ÷ 8 = 24
- Sample variance s² = 192 ÷ 7 ≈ 27.4286
The sample figure is always the larger of the two, because the divisor is always smaller.
Questions
Can variance be negative?
No. It averages squared quantities, so it is always zero or positive. Zero variance means every value is identical.