Variance quantifies how far a set of values spreads around its mean. The NIST/SEMATECH e-Handbook describes it as roughly the arithmetic average of the squared distance from the mean. Squaring makes every deviation positive and gives large deviations more weight, but it also squares the units: the variance of times in minutes is in minutesยฒ. For that reason, results are usually reported as the standard deviation, the square root of the variance, while variance itself is used inside calculations such as combining independent sources of variation.
Formula
sยฒ = ฮฃ (xแตข โ xฬ)ยฒ รท (n โ 1) (sample)
ฯยฒ = ฮฃ (xแตข โ ฮผ)ยฒ รท n (population)
- xแตข: each value.
- xฬ or ฮผ: the mean.
- n: the number of values.
- ฮฃ: the sum over all values.
The sample version divides by n โ 1 and is the form NIST gives; the population version divides by n and applies when the data covers the entire group.
Example
Four commute times in minutes: 3, 7, 8, 10.
- Mean = 28 รท 4 = 7.
- Deviations: โ4, 0, 1, 3. Squared: 16, 0, 1, 9. Sum = 26.
- Population variance = 26 รท 4 = 6.5 minยฒ.
- Sample variance = 26 รท 3 โ 8.667 minยฒ.
The matching standard deviations are โ6.5 โ 2.55 minutes and โ8.667 โ 2.94 minutes.
The standard deviation calculator shows variance alongside standard deviation, and the guide to finding standard deviation explains the n โ 1 choice. The mean in step 1 can come from the mean, median and mode calculator.
Variance vs standard deviation
Both measure the same spread. Variance is in squared units and is convenient for algebra; standard deviation is in the original units and is easier to interpret.