When we measure the variability of a set of data, there are two closely linked statistics related to this. The variance and standard deviation both indicate how spread out the data values are. Both of these statistics involve similar steps in their calculation, but there is one major difference. The standard deviation is the square root of the variance.

### Construction of Variance

To fully understand the difference between these statistics we need to understand the calculation of the variance.

The steps to calculating the sample variance are as follows:

- Calculate the sample mean of the data.
- Find the difference between the mean and each of the data values.
- Square these differences.
- Add the squared differences together.
- Divide this sum by one less than the total number of data values.

The reasons for each of these steps are as follows:

- The mean provides the center point or average of the data.
- The differences from the mean help to determine the deviations from that mean. Data values that are far from the mean will produce a greater deviation than those that are close to the mean.
- The differences are squared because if the differences are added without being squared, this sum will be zero.
- The addition of these squared deviations provides a measurement of total deviation.
- The division by one less than the sample size provides a sort of mean deviation. This negates the effect of having many data points each contribute to the measurement of spread.

### Variance and Standard Deviation

When we consider the variance, we realize that there is one major drawback to using it. When we follow the steps of the calculation of the variance, this shows that the variance is measured in terms of square units. (This is because we added together squared differences in our calculation).

For example if our sample data is measured in terms of meters, then the units for variance would be given in square meters.

In order to standardize our measure of spread, we need to take the square root of the variance. This will eliminate the problem of squared units, and gives us a measure of the spread that will have the same units as our original sample.

There are many formulas in mathematical statistics that have nicer looking forms when we state them in terms of variance instead of standard deviation.