Dispersion measures: variance and standard deviation

00Comment iconComment iconComment iconComment icon

Today we will talk about one of the most important measures: dispersion measures. They helped us understand how close each data is to the average!

Writer image

Translated byEditorial

Writer image

Revised byEditorial

Edit Article

Why Study Standard Deviation

When listening to the audio of different hearts, we can see that, by knowing the position of the number of heartbeats per minute, we can determine the age of the heart’s owner. Having a position within your data set is important, but sometimes it is not the only data to analyze. When checking whether a patient has heart problems, in addition to the number of beats per minute, their rhythm on the electrocardiogram is examined. In this case, the rhythm of the heart is studied, whether it changes pace a lot or not; in other words, how dispersed the heartbeats are compared with the average. Notice the difference between the following audios:

Can you tell which heart has arrhythmia?

Let’s move on to another example; let’s study the following series:

X: 70, 70, 70, 70, 70

Y: 68,69, 70, 71, 72

Z: 0, 10, 70, 110, 160

The arithmetic mean for each series is 70, only series X has a mode, and the median of all 3 is 70. Despite this, the three are clearly very different.

Dispersion or variability is the greater or lesser diversification of the values of a variable around a central tendency value taken as a point of comparison. In the case of the example, X has zero dispersion, while Y has less dispersion than Z.
Image content of the Website

How to Calculate Variance and Standard Deviation

As indices of stable variability, variance and standard deviation are used.

Variance is based on deviations around the arithmetic mean, but by determining the arithmetic mean of the squares of the deviations. Thus, it is represented by s²:

\[ s^{2} = \frac{\sum{(x_i - \bar{x})^{2}}}{\sum{f_i}} \]

Since variance is calculated from the squares of the deviations, it is a number in squared units in relation to the variable in question, which, from a practical point of view, is inconvenient; a new measure was devised that has practical usefulness and interpretation, called standard deviation, defined as the square root of the variance:

\[ s = \sqrt{s^{2}} \]

Properties

1st: The standard deviation is always positive or zero. The standard deviation of a constant is zero.

2nd: By adding (or subtracting) a constant c to all values of a variable, the standard deviation will remain the same, a property called translation invariance.

3rd: By multiplying (or dividing) all values of a variable by a constant c, the standard deviation is multiplied (or divided) by that constant.

Deviation for Ungrouped Data

Take as an example the following series of the variable x:

X: 40, 45, 48, 52, 54, 62, 70

The most practical way to calculate the standard deviation would be to create a table of the data and their squares:

xMeandeviationsquared deviation
4053-13169
4553-864
4853-525
5253-11
5453+11
6253+981
7053+17289

\[ \text{Sum of squared deviations: } = 630 \]

\[ \text{Number of elements in the sample: } = 7 \]

\[ \text{variance } = \frac{630}{7} = 90 \]

\[ \text{standard deviation } = \sqrt{90} = 9.49 \]

Deviation for Grouped Data: Without Class Intervals

Since in this case we have the presence of frequencies, we must take them into account by multiplying the square of the deviation by the frequency, resulting in the formula:

\[ s^{2} = \frac{\sum{f_i*(x_i - \bar{x})^{2}}}{\sum{f_i}} \]

As an example:

xFrequencyMeandeviationsquared deviationSquared deviation* frequency
022.1-2.14.418.82
162.1-1.11.217.26
2122.1-0.10.010.12
372.1+0.90.815.67
432.1+1.93.6110.83

\[ \text{Sum of squared deviations: } = 32.7 \]

\[ \text{Number of elements in the sample: } = 30 \]

\[ \text{variance } = \frac{32.7}{30} = 1.09 \]

\[ \text{standard deviation } = \sqrt{1.09} = 1.044 \]

Deviation for Grouped Data: With Class Intervals

For class intervals, the midpoint is considered as the value of that class.

As an example:

ClassMidpointFrequencyMeandeviationsquared deviationSquared deviation* frequency
0 - 2125-41632
2 - 4325-248
4 - 6525000
6 - 8725+248
8 - 10925+41632

\[ \text{Sum of squared deviations: } = 80 \]

\[ \text{Number of elements in the sample: } = 10 \]

\[ \text{variance } = \frac{80}{10} = 8 \]

\[ \text{standard deviation } = \sqrt{8} = 2.82 \]

Coefficient of Variation

The standard deviation by itself does not tell us much. Thus, a standard deviation of two units may be considered small for a series of values whose mean value is 200; however, if the mean is equal to 20, the same cannot be said.

In addition, the fact that the standard deviation is expressed in the same unit as the data limits its use when one wants to compare two or more series of values in relation to their dispersion or variability.

To overcome these difficulties and limitations, the coefficient of variation (CV) is used:

\[ \text{CV } = \frac{s}{\bar{x}} \]

Thus, for the last example where:

\[ \text{standard deviation } = 2.82 \]

\[ \text{mean } = 5 \]

\[ \text{CV } = \frac{2.82}{5} = 0.564 = 56.4 \% \]

Exercises

1) Calculate the standard deviations of the following sets:

(a) 1,3,4,9;

(b) 20, 14, 15, 19, 21, 22, 20;

2) Calculate the standard deviations of the following sets:

(a) 17.9, 22.5, 13.3, 16.8, 15.4, 14.2;

(b) -10, -6, 2, 3, 7, 9, 10;

3) Calculate the standard deviations of the following distribution:
XFrequency
21
33
45
58
65
74
82
4) Calculate the standard deviations of the following distribution:
XFrequency
1.5-1.64
1.6-1.78
1.7-1.812
1.8-1.915
1.9-2.012
2.0-2.18
2.1-2.24
5) Knowing that a data set has an arithmetic mean and standard deviation of 18.3 and 1.47, respectively, calculate the coefficient of variation.

6) In a final Mathematics exam, the average grade of a group of 150 students was 7.8 and the standard deviation was 0.80. In Statistics, however, the final average grade was 7.3 and the standard deviation was 0.76. In which subject was the dispersion greater?

7) Measuring the heights of 1,017 individuals, we obtained mean = 162.2 cm and s = 8.01 cm. The average weight of these same individuals is 52 kg, with a standard deviation of 2.3 kg. Do these individuals show greater variability in height or in weight?

8) A group of one hundred students has an average height of 163.8 cm, with a coefficient of variation of 3.3%. What is the standard deviation of this group?

9) A distribution presents the following statistics: s = 1.5 and CV = 2.9%. Determine the mean of the distribution.

Answer Key

1) a. 2.94; b. 2.81;

2) a. 3.01; b. 7.03;

3) 1.51;

4) 0.159;

5) 8.03%

6) Statistics

7) Height

8) 5.41

9) 51.7