Variability can also be defined in terms of how close the
scores in the distribution are to the middle of the
distribution. Using the mean as the measure of the middle of
the distribution, the variance is defined as the average
squared difference of the scores from the mean. The data from
Quiz 1 are shown in Table 1. The
mean score is 7.07.0. Therefore,
the column "Deviation from Mean" contains the score
-7-7.
The column "Squared Deviation" is simply the previous column
squares.
Table 1: Calculation of Variance for Quiz 1 scores.
| |
Scores |
Deviation from Mean |
Squared Deviation |
| |
9 |
2 |
4 |
| |
9 |
2 |
4 |
| |
9 |
2 |
4 |
| |
8 |
1 |
1 |
| |
8 |
1 |
1 |
| |
8 |
1 |
1 |
| |
8 |
1 |
1 |
| |
7 |
0 |
0 |
| |
7 |
0 |
0 |
| |
7 |
0 |
0 |
| |
7 |
0 |
0 |
| |
7 |
0 |
0 |
| |
6 |
-1 |
1 |
| |
6 |
-1 |
1 |
| |
6 |
-1 |
1 |
| |
6 |
-1 |
1 |
| |
6 |
-1 |
1 |
| |
6 |
-1 |
1 |
| |
5 |
-2 |
4 |
| |
5 |
-2 |
4 |
| Mean |
7 |
0 |
1.5 |
One thing that is important to notice is that the mean
deviation from the mean is 00.
This will always be the case. The mean of the squared
deviations is 1.51.5. Therefore,
the variance is 1.51.5. Analogous
calculations with Quiz 2 show that it's variance is
6.76.7. The formula for the
variance is:
σ2=∑X−μ2N
σ
2
X
μ
2
N
where
σ2
σ
2
is the variance, μμ is the
mean, and NN is the number of
numbers. For Quiz 1,
μ=7
μ
7
and
N=20
N
20
.
If the variance in a sample is used to estimate the variance
in a population, then the previous formula underestimates the
variance and the following formula should be used:
s2=∑X−M2N−1
s
2
X
M
2
N
1
where
s2
s
2
is the estimate of the variance and
MM is the sample mean. Note that
MM is the mean of a sample taken
from a population with a mean of
μμ. Since, in practice, the
variance is usually computed in a sample, this formula is most
often used. The simulation "estimating variance" illustrates the bias
in the formula with NN in the
denominator.
Let's take a concrete example. Assume the scores
11,
22,
44, and
55 were sampled from a larger
population. To estimate the variance in the population you
would compute
s2
s
2
as follows:
M=1+2+4+54=124=3
M
1
2
4
5
4
12
4
3
s2=1−32+2−32+4−32+5−324−1=4+1+1+43=103=3.333
s
2
1
3
2
2
3
2
4
3
2
5
3
2
4
1
4
1
1
4
3
10
3
3.333
There are an alternate formulas that can be easier to use if
you are doing your calculations with a hand calculator:
σ2=∑X2−∑X2NN
σ
2
X
2
X
2
N
N
and
s2=∑X2−∑X2NN−1
s
2
Σ
X
2
X
2
N
N
1
For this example,
∑X2=12+22+42+52=46
X
2
1
2
2
2
4
2
5
2
46
∑X2N=1+2+4+52N=1444=36
X
2
N
1
2
4
5
2
N
144
4
36
σ2=46−364=2.5
σ
2
46
36
4
2.5
and
s2=46−363=3.333
s
2
46
36
3
3.333
as with the other formula.