Average (mean or arithmetic mean) is the sum of all values divided by the count of the values.
Variance is the sum of the “squared difference between each observation and the average of the observations” divided by the count minus one. These are measured in square units so variance isn’t easily interpreted.
Standard Deviation is the square root of variance. The standard deviation is a measure of dispersion. It helps us understand how spread our our data is and it does so in the same units as the original observations.
A simple example of average, variance and standard deviation:
|Order $||(Order $ – Avg $)^2|
|Order Count = 6|
|Average Order $ = $95.67|
|Variance = 5,943 / (6 – 1) = 1,189|
|Std. Dev = Sqrt(Variance) = $34.48|
Average: We add up all of the order sales ($574) and then divide by the number of orders (6) to get our average order of $96.67.
Variance: Using that average, we subtract it from each of the order sales and then square the difference. For example:
Order #1: $112 – Average of orders = $112 – $95.67 = $16.33
Variance = $16.33^2 = $16.33 * $16.33 = 267
Notice how I dropped the units on the last number (267). Technically it’s 267 square dollars but that’s not a number we can really interpret.
To get the final “variance” we add up the individual variance score and divide by the count minus one. The reason we subtract one from the count is that division by n tends to underestimate the sample variance. Keep in mind we’re looking at the sample variance. We didn’t collect an order from the entire population of customers.
For variance just remember that you divide by (n-1).
Standard Deviation: After calculating our final variance score, we take the square root of that variance. This takes us from square dollars to regular dollars and we can can now interpret the dispersion of our collected orders.
Standard Deviation = SQRT(5,943) = $34.38
Based on the Empirical Rule we can estimate that 95% of the possible orders fall within two standard deviations of our average. That means you can expect 95% of orders to fall within $95.67 +/- 2 * $34.38 or between $26.91 and $164.43.