Math Core

Lesson 8.5 · Statistics

Range and interquartile range

Two data sets can have the same center and still look very different. Suppose two classes both have a median test score of 80. In one class almost everyone scored between 75 and 85. In the other, scores ranged from 50 to 100. To tell them apart, you need a measure of spread (or variability): a number that says how spread out the data is.

The range

The simplest measure of spread is the distance from the smallest value to the largest.

Definition

Range

The range of a data set is the maximum minus the minimum:

range=maximum−minimum\text{range} = \text{maximum} - \text{minimum}

For the data 14, 9, 22, 17, 1114, \ 9, \ 22, \ 17, \ 11, the maximum is 22 and the minimum is 9, so the range is 22−9=1322 - 9 = 13.

The range is quick, but it depends on only two values. A single outlier can make it huge, even when most of the data is packed close together.

Quartiles

A better measure of spread looks at the middle half of the data. To find it, you split the ordered data into four parts with about the same number of values in each. The values that split it are called quartiles.

Finding the quartiles

  1. Put the data in order and find the median. This splits the data into a lower half and an upper half.
  2. If there is an odd number of values, leave the median out of both halves.
  3. The first quartile, Q1Q_1, is the median of the lower half.
  4. The third quartile, Q3Q_3, is the median of the upper half.

About a quarter of the data is below Q1Q_1, and about a quarter is above Q3Q_3. The median is sometimes called Q2Q_2.

Definition

Interquartile range (IQR)

The interquartile range is the distance between the third and first quartiles:

IQR=Q3−Q1\text{IQR} = Q_3 - Q_1

It measures the spread of the middle half of the data.

Worked example: An even number of values

Find the range and IQR of 3, 5, 6, 8, 10, 11, 13, 163, \ 5, \ 6, \ 8, \ 10, \ 11, \ 13, \ 16.

Range: 16−3=1316 - 3 = 13.

Median: There are 8 values. The middle two are 8 and 10, so the median is 8+102=9\dfrac{8 + 10}{2} = 9.

Halves: The median splits the list into two halves of 4 values each.

3, 5, 6, 8⏟lower half∣10, 11, 13, 16⏟upper half\underbrace{3, \ 5, \ 6, \ 8}_{\text{lower half}} \quad \Big| \quad \underbrace{10, \ 11, \ 13, \ 16}_{\text{upper half}}

Quartiles: Q1=5+62=5.5Q_1 = \dfrac{5 + 6}{2} = 5.5 and Q3=11+132=12Q_3 = \dfrac{11 + 13}{2} = 12.

IQR: 12−5.5=6.512 - 5.5 = 6.5.

Worked example: An odd number of values, with an outlier

The ages of 11 people at a family picnic are

12, 15, 17, 18, 20, 21, 23, 24, 26, 30, 7112, \ 15, \ 17, \ 18, \ 20, \ 21, \ 23, \ 24, \ 26, \ 30, \ 71

Find the range and the IQR.

Range: 71−12=5971 - 12 = 59.

Median: With 11 values, the median is the 6th: 21.

Halves: Leave out the median. The lower half is 12,15,17,18,2012, 15, 17, 18, 20 and the upper half is 23,24,26,30,7123, 24, 26, 30, 71.

Quartiles: Q1=17Q_1 = 17 (middle of the lower half) and Q3=26Q_3 = 26 (middle of the upper half).

IQR: 26−17=926 - 17 = 9.

The range, 59, makes the ages look very spread out, but that's because of one grandparent who is 71. The IQR says the middle half of the ages are within 9 years of each other. The outlier barely affects the IQR.

Common mistake

When there is an odd number of values, don't put the median into either half. In the picnic example, including 21 in both halves would give halves of 6 values and different quartiles. And as always, order the data first.

Comparing spread

Worked example: Which is more consistent?

Two runners recorded their times, in seconds, for the 100-meter dash over several races.

  • Runner A: Q1=14.2Q_1 = 14.2, Q3=14.8Q_3 = 14.8
  • Runner B: Q1=13.6Q_1 = 13.6, Q3=15.4Q_3 = 15.4

Which runner's times are more consistent?

Solution. Runner A's IQR is 14.8−14.2=0.614.8 - 14.2 = 0.6 second. Runner B's IQR is 15.4−13.6=1.815.4 - 13.6 = 1.8 seconds. Runner A's middle half of times is packed much closer together, so Runner A is more consistent.

Tip

A smaller IQR means the middle of the data is bunched together, so the values are more alike. A larger IQR means more variability. When a data set has outliers, the IQR is a more trustworthy measure of spread than the range.

Practice

Practice 1

Find the range of 14, 9, 22, 17, 1114, \ 9, \ 22, \ 17, \ 11.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 2

Find the first quartile, Q1Q_1, of 2, 4, 5, 7, 9, 10, 12, 152, \ 4, \ 5, \ 7, \ 9, \ 10, \ 12, \ 15.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 3

Find the IQR of 6, 8, 9, 11, 13, 14, 16, 18, 216, \ 8, \ 9, \ 11, \ 13, \ 14, \ 16, \ 18, \ 21.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 4

The number of push-ups 10 students did in one minute were

31, 25, 40, 28, 35, 22, 38, 30, 27, 3331, \ 25, \ 40, \ 28, \ 35, \ 22, \ 38, \ 30, \ 27, \ 33

Find the IQR.

Enter a number. Fractions like 3/4 and sqrt(2) are OK.

Practice 5

In the push-up data above, suppose the student who did 40 push-ups actually did 90. Which measure changes?

Practice 6

Two bakeries weigh their loaves of bread, in grams. Bakery P has an IQR of 12 grams. Bakery Q has an IQR of 35 grams. Which statement is best supported?

Practice 7

The dot plot shows how many hours of sleep 13 campers got on the first night of camp. Find the IQR.

3456789✕✕✕✕✕✕✕✕✕✕✕✕✕
Hours of sleep

Enter a number. Fractions like 3/4 and sqrt(2) are OK.