What variance measures
Variance is the average squared distance of each value from the mean. It answers the same question as standard deviation (how spread out is the data) but in squared units, so a data set measured in dollars has a variance in dollars squared. That makes it awkward to read but very useful in statistics, because variances of independent variables simply add together.
Variance formulas
Population variance: σ² = Σ(x − μ)² ÷ N
The top of both formulas, Σ(x − x̄)², is called the sum of squares. The calculator shows it as its own line so you can check your own working.
Worked example
For 10, 12, 23, 23, 16, 23, 21, 16 the mean is 18 and the sum of squares is 192.
| Divide by | Variance | |
|---|---|---|
| Sample | n − 1 = 7 | 27.4286 |
| Population | N = 8 | 24 |
Variance or standard deviation?
Report the standard deviation when you describe data to people, because it uses the original units. Use the variance when you combine sources of variation, run an ANOVA, or work with formulas that need it. To convert, take the square root of the variance; to go back, square the standard deviation.
The computational shortcut
Some textbooks use s² = [Σx² − (Σx)² ÷ n] ÷ (n − 1). It gives the same answer with fewer subtractions, which helps when working by hand, but it can lose accuracy with large numbers on a calculator. This tool uses the definition formula above for full precision.
Formulas follow the NIST/SEMATECH e-Handbook of Statistical Methods: measures of scale.
Frequently asked questions
Why is variance in squared units?
Because each distance from the mean is squared before averaging. Squaring stops negative and positive distances from cancelling out. Taking the square root at the end gives the standard deviation in the original units.
Is a variance of 0 possible?
Yes, but only when every value in the data set is the same. Any difference between values gives a variance above zero.
Which Excel function gives the same result?
VAR.S gives the sample variance and VAR.P gives the population variance.