Variance
What is the variance?
The variance is a statistic used to describe the variability or spread in a continuous variable. It is the average squared distance of each data value from the mean.
When should you use variance?
Since variance is the average squared distance from the mean, it is not as easy to interpret as the standard deviation of the data. In general, you should use the mean to report the center of the data and the standard deviation to report the spread of the data.
The variance is affected by extreme values, especially with small sample sizes. Be sure to plot your data so you can see whether you have extreme values and understand how they might affect your summary statistics.
The variance has nicer statistical properties than the standard deviation, so statisticians develop methods for analysis based on the variance instead of the standard deviation. Some examples are analysis of variance, regression analysis, and variance components analysis.
In these analyses, total variance is decomposed into components. It is very important to decompose variance, not standard deviation. The components of variance add to the total variance, but the components of standard deviation do not add to the total standard deviation. When summing up components of variability, use the Pythagorean theorem and add up variances. You can take the square root of the variance to obtain the standard deviation in the same units as the original data.
The variance is the second moment around the mean.
How do you calculate variance?
Suppose you are measuring the heights of basketball players in inches, and your measurements are 63, 69, 72, 73, and 74 inches.
To calculate variance, first find the mean of the data. The mean is (63 + 69 + 72 + 73 + 74) / 5 = 70.2. Next, subtract the mean from each data value, then square that difference. Then, sum up all the squared differences. Finally, divide the sum of the squared differences by one less than the sample size.
Using n – 1 in the denominator of the average instead of n accounts for using the data to estimate the mean in the variance formula. The denominator n – 1 is called the degrees of freedom for estimating the variance. If you knew all the basketball players’ heights but one, and you knew the mean, you could find the final height. Therefore, if you know the mean, that last height is not free to vary. It is determined by the others and the mean. Degrees of freedom measure how much information is in a data set.
In the figure above, you can see the calculations of the variance for the five basketball players. The variance is ((73 – 70.2)2 + (74 – 70.2)2 + (69 – 70.2)2 + (63 – 70.2)2 +(72 – 70.2)2) / 4 = 19.7.
Examples of variance
Examine the variance of the data in the Univariate Statistics Data. You can see the value of variance in the Summary Statistics report.