Previous Up Next

9.1.2  Variance: variance

The variance of a list of numbers measures how close the numbers are to their mean by finding the average of the squares of the differences between the numbers and the mean; specifically, given a list of numbers [x1,…,xn] with mean µ = (x1 + ⋯ + xn)/n, the variance is

(x1 − µ)2 + … + (xn − µ)2
n

The squares help ensure that the numbers above the mean and those below the mean don’t cancel out. The variance command computes the variance.


Examples.


Previous Up Next