# 14.3: Measures of Dispersion

$$\newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} }$$

$$\newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}}$$

$$\newcommand{\id}{\mathrm{id}}$$ $$\newcommand{\Span}{\mathrm{span}}$$

( \newcommand{\kernel}{\mathrm{null}\,}\) $$\newcommand{\range}{\mathrm{range}\,}$$

$$\newcommand{\RealPart}{\mathrm{Re}}$$ $$\newcommand{\ImaginaryPart}{\mathrm{Im}}$$

$$\newcommand{\Argument}{\mathrm{Arg}}$$ $$\newcommand{\norm}[1]{\| #1 \|}$$

$$\newcommand{\inner}[2]{\langle #1, #2 \rangle}$$

$$\newcommand{\Span}{\mathrm{span}}$$

$$\newcommand{\id}{\mathrm{id}}$$

$$\newcommand{\Span}{\mathrm{span}}$$

$$\newcommand{\kernel}{\mathrm{null}\,}$$

$$\newcommand{\range}{\mathrm{range}\,}$$

$$\newcommand{\RealPart}{\mathrm{Re}}$$

$$\newcommand{\ImaginaryPart}{\mathrm{Im}}$$

$$\newcommand{\Argument}{\mathrm{Arg}}$$

$$\newcommand{\norm}[1]{\| #1 \|}$$

$$\newcommand{\inner}[2]{\langle #1, #2 \rangle}$$

$$\newcommand{\Span}{\mathrm{span}}$$ $$\newcommand{\AA}{\unicode[.8,0]{x212B}}$$

$$\newcommand{\vectorA}[1]{\vec{#1}} % arrow$$

$$\newcommand{\vectorAt}[1]{\vec{\text{#1}}} % arrow$$

$$\newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} }$$

$$\newcommand{\vectorC}[1]{\textbf{#1}}$$

$$\newcommand{\vectorD}[1]{\overrightarrow{#1}}$$

$$\newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}}$$

$$\newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}}$$

$$\newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} }$$

$$\newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}}$$

$$\newcommand{\avec}{\mathbf a}$$ $$\newcommand{\bvec}{\mathbf b}$$ $$\newcommand{\cvec}{\mathbf c}$$ $$\newcommand{\dvec}{\mathbf d}$$ $$\newcommand{\dtil}{\widetilde{\mathbf d}}$$ $$\newcommand{\evec}{\mathbf e}$$ $$\newcommand{\fvec}{\mathbf f}$$ $$\newcommand{\nvec}{\mathbf n}$$ $$\newcommand{\pvec}{\mathbf p}$$ $$\newcommand{\qvec}{\mathbf q}$$ $$\newcommand{\svec}{\mathbf s}$$ $$\newcommand{\tvec}{\mathbf t}$$ $$\newcommand{\uvec}{\mathbf u}$$ $$\newcommand{\vvec}{\mathbf v}$$ $$\newcommand{\wvec}{\mathbf w}$$ $$\newcommand{\xvec}{\mathbf x}$$ $$\newcommand{\yvec}{\mathbf y}$$ $$\newcommand{\zvec}{\mathbf z}$$ $$\newcommand{\rvec}{\mathbf r}$$ $$\newcommand{\mvec}{\mathbf m}$$ $$\newcommand{\zerovec}{\mathbf 0}$$ $$\newcommand{\onevec}{\mathbf 1}$$ $$\newcommand{\real}{\mathbb R}$$ $$\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}$$ $$\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}$$ $$\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}$$ $$\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}$$ $$\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}$$ $$\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}$$ $$\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}$$ $$\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}$$ $$\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}$$ $$\newcommand{\laspan}[1]{\text{Span}\{#1\}}$$ $$\newcommand{\bcal}{\cal B}$$ $$\newcommand{\ccal}{\cal C}$$ $$\newcommand{\scal}{\cal S}$$ $$\newcommand{\wcal}{\cal W}$$ $$\newcommand{\ecal}{\cal E}$$ $$\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}$$ $$\newcommand{\gray}[1]{\color{gray}{#1}}$$ $$\newcommand{\lgray}[1]{\color{lightgray}{#1}}$$ $$\newcommand{\rank}{\operatorname{rank}}$$ $$\newcommand{\row}{\text{Row}}$$ $$\newcommand{\col}{\text{Col}}$$ $$\renewcommand{\row}{\text{Row}}$$ $$\newcommand{\nul}{\text{Nul}}$$ $$\newcommand{\var}{\text{Var}}$$ $$\newcommand{\corr}{\text{corr}}$$ $$\newcommand{\len}[1]{\left|#1\right|}$$ $$\newcommand{\bbar}{\overline{\bvec}}$$ $$\newcommand{\bhat}{\widehat{\bvec}}$$ $$\newcommand{\bperp}{\bvec^\perp}$$ $$\newcommand{\xhat}{\widehat{\xvec}}$$ $$\newcommand{\vhat}{\widehat{\vvec}}$$ $$\newcommand{\uhat}{\widehat{\uvec}}$$ $$\newcommand{\what}{\widehat{\wvec}}$$ $$\newcommand{\Sighat}{\widehat{\Sigma}}$$ $$\newcommand{\lt}{<}$$ $$\newcommand{\gt}{>}$$ $$\newcommand{\amp}{&}$$ $$\definecolor{fillinmathshade}{gray}{0.9}$$

Consider these three sets of quiz scores:

• Section A: 5 5 5 5 5 5 5 5 5 5
• Section B: 0 0 0 0 0 10 10 10 10 10
• Section C: 4 4 4 5 5 5 5 6 6 6

All three of these sets of data have a mean of 5 and median of 5, yet the sets of scores are clearly quite different. In section A, everyone had the same score; in section B half the class got no points and the other half got a perfect score, assuming this was a 10-point quiz. Section C was not as consistent as section A, but not as widely varied as section B.

In addition to the mean and median, which are measures of the "typical" or "middle" value, we also need a measure of how "spread out" or varied each data set is.

There are several ways to measure this "spread" of the data. The first is the simplest and is called the range.

## Range

The range is the difference between the maximum value and the minimum value of the data set.

## Example 1

Using the quiz scores from above,

For section A, the range is 0 since both maximum and minimum are 5 and $$5 – 5 = 0$$

For section B, the range is 10 since $$10 – 0 = 10$$

For section C, the range is 2 since $$6 – 4 = 2$$

In the last example, the range seems to be revealing how spread out the data is. However, suppose we add a fourth section, Section D, with scores 0 5 5 5 5 5 5 5 5 10.

This section also has a mean and median of 5. The range is 10, yet this data set is quite different than Section B. To better illuminate the differences, we’ll have to turn to more sophisticated measures of variation.

## Standard Deviation

The standard deviation is a measure of variation based on measuring how far each data value deviates, or is different, from the mean. A few important characteristics:

• Standard deviation is always positive. Standard deviation will be zero if all the data values are equal, and will get larger as the data spreads out.
• Standard deviation has the same units as the original data.
• Standard deviation, like the mean, can be highly influenced by outliers.
##### Example 2

Using the data from section D, we could compute for each data value the difference between the data value and the mean:

$$\begin{array}{|l|l|} \hline \text { data value } & \text { deviation: data value - mean } \\ \hline 0 & 0-5=-5 \\ \hline 5 & 5-5=0 \\ \hline 5 & 5-5=0 \\ \hline 5 & 5-5=0 \\ \hline 5 & 5-5=0 \\ \hline 5 & 5-5=0 \\ \hline 5 & 5-5=0 \\ \hline 5 & 5-5=0 \\ \hline 5 & 5-5=0 \\ \hline 10 & 10-5=5 \\ \hline \end{array}$$

Solution

We would like to get an idea of the "average" deviation from the mean, but if we find the average of the values in the second column the negative and positive values cancel each other out (this will always happen), so to prevent this we square every value in the second column:

We then add the squared deviations up to get $$25 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 25 = 50$$. Ordinarily we would then divide by the number of scores, $$n$$, (in this case, 10) to find the mean of the deviations. But we only do this if the data set represents a population; if the data set represents a sample (as it almost always does), we instead divide by $$n - 1$$ (in this case, $$10 - 1 = 9$$).[1]

So in our example, we would have $$\frac{50}{10} = 5$$ if section D represents a population and $$\frac{50}{9} =$$ about 5.56 if section D represents a sample. These values (5 and 5.56) are called, respectively, the population variance and the sample variance for section D.

Variance can be a useful statistical concept, but note that the units of variance in this instance would be points-squared since we squared all of the deviations. What are points-squared? Good question. We would rather deal with the units we started with (points in this case), so to convert back we take the square root and get:

$$\text{population standard deviation} =\sqrt{\frac{50}{10}}=\sqrt{5} \approx 2.2$$

or

$$\text{sample standard deviation} =\sqrt{\frac{50}{9}} \approx 2.4$$

If we are unsure whether the data set is a sample or a population, we will usually assume it is a sample, and we will round answers to one more decimal place than the original data, as we have done above.

## To Compute Standard Deviation

1. Find the deviation of each data from the mean. In other words, subtract the mean from the data value.
2. Square each deviation.
4. Divide by $$n$$, the number of data values, if the data represents a whole population; divide by $$n – 1$$ if the data is from a sample.
5. Compute the square root of the result.

## Example 3

Computing the standard deviation for Section B above, we first calculate that the mean is 5. Using a table can help keep track of your computations for the standard deviation:

$$\begin{array}{|l|l|l|} \hline \text { data value } & \text { deviation: data value - mean } & \text { deviation squared } \\ \hline 0 & 0-5=-5 & (-5)^{2}=25 \\ \hline 0 & 0-5=-5 & (-5)^{2}=25 \\ \hline 0 & 0-5=-5 & (-5)^{2}=25 \\ \hline 0 & 0-5=-5 & (-5)^{2}=25 \\ \hline 0 & 0-5=-5 & (-5)^{2}=25 \\ \hline 10 & 10-5=5 & (5)^{2}=25 \\ \hline 10 & 10-5=5 & (5)^{2}=25 \\ \hline 10 & 10-5=5 & (5)^{2}=25 \\ \hline 10 & 10-5=5 & (5)^{2}=25 \\ \hline 10 & 10-5=5 & (5)^{2}=25 \\ \hline \end{array}$$

Assuming this data represents a population, we will add the squared deviations, divide by 10, the number of data values, and compute the square root:

$\sqrt{\frac{25+25+25+25+25+25+25+25+25+25}{10}}=\sqrt{\frac{250}{10}}=5 \nonumber$

Notice that the standard deviation of this data set is much larger than that of section D since the data in this set is more spread out.

For comparison, the standard deviations of all four sections are:

$$\begin{array}{|l|l|} \hline \text { Section A: 5 5 5 5 5 5 5 5 5 5 } & \text { Standard deviation: 0 } \\ \hline \text { Section B: 0 0 0 0 0 10 10 10 10 10 } & \text { Standard deviation: 5 } \\ \hline \text { Section C: 4 4 4 5 5 5 5 6 6 6 } & \text { Standard deviation: 0.8 } \\ \hline \text { Section D: 0 5 5 5 5 5 5 5 5 10 } & \text { Standard deviation: 2.2 } \\ \hline \end{array}$$

## Try it Now 1

The price of a jar of peanut butter at 5 stores were: $3.29,$3.59, $3.79,$3.75, and $3.99. Find the standard deviation of the prices. Answer Earlier we found the mean of the data was$3.682.

$$\begin{array}{|l|l|l|} \hline \text { data value } & \text { deviation: data value - mean } & \text { deviation squared } \\ \hline 3.29 & 3.29-3.682=-0.391 & 0.153664 \\ \hline 3.59 & 3.59-3.682=-0.092 & 0.008464 \\ \hline 3.79 & 3.79-3.682=0.108 & 0.011664 \\ \hline 3.75 & 3.75-3.682=0.068 & 0.004624 \\ \hline 3.99 & 3.99-3.682=0.308 & 0.094864 \\ \hline \end{array}$$

This data is from a sample, so we will add the squared deviations, divide by 4, the number of data values minus 1, and compute the square root:

$$\sqrt{\frac{0.153664+0.008464+0.011664+0.004624+0.094864}{4}} \approx \ 0.261$$

[1] The reason we do this is highly technical, but we can see how it might be useful by considering the case of a small sample from a population that contains an outlier, which would increase the average deviation: the outlier very likely won't be included in the sample, so the mean deviation of the sample would underestimate the mean deviation of the population; thus we divide by a slightly smaller number to get a slightly bigger average deviation.

This page titled 14.3: Measures of Dispersion is shared under a CC BY-SA 3.0 license and was authored, remixed, and/or curated by David Lippman & Jeff Eldridge (The OpenTextBookStore) .