Tutorials › Exam PA - Predictive Analytics › Reading Boxplots Beyond the Median

Exam PA · Visualization and Anomaly Detection · Tutorial 138 of 966

Reading Boxplots Beyond the Median

Interpret each part of a boxplot in context, calculate the summaries it displays, and identify what cannot be concluded from the plot alone.

Beginner 10 min read

What You'll Learn

  • Read the median and quartiles from a boxplot and explain their meaning in context
  • Calculate the interquartile range and compare the two halves of the box
  • Distinguish whisker endpoints from the sample minimum and maximum
  • Interpret individually plotted observations without assuming they are errors
  • Recognize that different data sets can share the same boxplot
  • Check quartile and whisker conventions before comparing plots

What a Boxplot Shows

A boxplot compresses a quantitative data set into a small number of landmarks. It is useful when a quick view of location and spread is needed, but it does not show every observation or the full shape of the distribution. To read one accurately, distinguish the parts of the box from the whiskers and any individually plotted points.

Definition: A standard boxplot displays the first quartile \(Q_1\), the median \(Q_2\), and the third quartile \(Q_3\) as a box: the lower and upper edges mark \(Q_1\) and \(Q_3\), and a line inside marks the median. The interquartile range is \(IQR=Q_3-Q_1\), the width of the middle half of the data. Whiskers extend from the box according to the plotting convention in use. Some boxplots show observations beyond the whiskers as individual points.

For a vertical boxplot, read the values from the vertical scale; for a horizontal boxplot, read them from the horizontal scale. The orientation changes the direction in which you read the scale, not the meaning of the components. The box contains the central half of the observations, from the first through the third quartile. The median divides the data into two halves in the sense that about half the observations are at or below it and about half are at or above it. With an even number of observations, the median commonly lies between two observed values.

Quartiles are sample summaries, and software can use different conventions to calculate them, particularly for small samples. The five-number summary (minimum, \(Q_1\), median, \(Q_3\), maximum) may therefore differ slightly across methods even when it describes the same data. When a problem supplies the quartiles or specifies a calculation convention, use that information rather than assuming a particular software default.

Interpreting the Box and the IQR

The height or length of the box is the IQR. A larger IQR means the middle half of the observed values spans a wider range on the measurement scale; it does not, by itself, describe the spread of every observation. The median’s position within the box is also informative. If the median is much nearer one box edge than the other, the two quartile intervals have different lengths. This is a clue about the distribution, not a complete description of its shape.

Key interpretation: The interval from \(Q_1\) to the median describes the spread of the lower half of the data, and the interval from the median to \(Q_3\) describes the spread of the upper half. Comparing these lengths can suggest uneven spread, but a boxplot cannot reveal the detailed arrangement of observations within either interval.

The quartile interval has this interpretation because quartiles divide an ordered data set into four sections, each containing roughly one-quarter of the observations. From \(Q_1\) to \(Q_3\) are the two middle sections, so together they cover roughly half the data. Subtracting the endpoints gives the span of that central half:

$$ IQR=Q_3-Q_1. $$

This is a measure of spread, not a count: an IQR of 20 units means that the central half spans 20 units on the measurement scale. It does not mean that half of the observations have a value of 20.

Worked Example: Reading a Boxplot of Claim Processing Times

A hypothetical insurer displays a boxplot of processing times, measured in days, for a group of claims. The lower box edge is at 240 days, the median line is at 310 days, and the upper box edge is at 430 days. The whiskers end at 120 and 620 days, and two points beyond the upper whisker are plotted at 900 and 1,050 days. Interpret the display.

Step 1: Identify the box summaries. The first quartile is \(Q_1=240\), the median is \(Q_2=310\), and the third quartile is \(Q_3=430\) days.

Step 2: Calculate the IQR. Subtract the quartiles: \(IQR=430-240=190\) days. Thus, the interval from 240 to 430 days spans the central half of the observed processing times.

Step 3: Compare the two parts of the box. The lower part has length \(310-240=70\) days. The upper part has length \(430-310=120\) days. The median is nearer \(Q_1\), and the upper half of the box spans more days than the lower half. This indicates different spreads in these two quartile intervals; it does not establish the exact distribution shape.

Step 4: Interpret the whiskers and points. The displayed whisker endpoints are 120 and 620 days. They are not automatically the sample minimum and maximum. The points at 900 and 1,050 days are individual observations plotted beyond the upper whisker under the chosen plotting convention. Their positions alone do not establish that they are data errors or explain why they are large.

Check. The box is 190 days long, with the median 70 days above its lower edge and 120 days below its upper edge. The values and interpretations are consistent with the stated plot.

Whiskers and Individually Plotted Points

Whiskers are often mistaken for a data set’s minimum and maximum. That interpretation is only justified when the plot’s convention says the whiskers reach those extremes. In many commonly used boxplots, whiskers stop at the most extreme observations that meet a specified rule; observations beyond them are shown separately as points. The exact rule depends on the plotting method, so read a legend, caption, or software description when it is available.

A point beyond a whisker tells you that the observation lies beyond the displayed whisker endpoint. It does not, by itself, tell you whether the observation is valid, unusual for the underlying population, or caused by a recording problem. Those questions require the data and the context. In particular, an extreme but plausible claim amount or processing time should not be discarded merely because a boxplot draws it separately.

Worked Example: Calculating Quartiles From Ordered Data

A hypothetical analyst records eight repair durations, in days, and sorts them as follows: 12, 15, 18, 20, 22, 24, 26, 30. Use the median-of-halves convention: for an even-sized data set, find the median of the lower half for \(Q_1\) and the median of the upper half for \(Q_3\). Find the quartiles and IQR, then describe the box.

Step 1: Find the overall median. There are eight values, so take the mean of the fourth and fifth values: \(Q_2=(20+22)/2=21\) days.

Step 2: Find \(Q_1\). The lower half is 12, 15, 18, 20. Its middle two values are 15 and 18, so \(Q_1=(15+18)/2=16.5\) days.

Step 3: Find \(Q_3\). The upper half is 22, 24, 26, 30. Its middle two values are 24 and 26, so \(Q_3=(24+26)/2=25\) days.

Step 4: Calculate the IQR. \(IQR=25-16.5=8.5\) days. The lower half of the box has length \(21-16.5=4.5\) days, and the upper half has length \(25-21=4\) days.

Step 5: Check the result. The quartiles are ordered \(16.5<21<25\), and their difference is \(8.5\). Under the specified convention, the box runs from 16.5 to 25 days with its median line at 21 days. The sample minimum and maximum, 12 and 30 days, are not enough on their own to determine how every boxplot convention draws the whiskers.

Method and mistake avoided. The calculation follows the stated median-of-halves convention. A common mistake is to use the overall median as one of the quartiles or to substitute the minimum and maximum for \(Q_1\) and \(Q_3\).

What the Boxplot Conceals

A boxplot is a summary, not a miniature display of all the data. It does not show the individual values inside the box or whiskers, the number of observations at each value, or whether values are concentrated in clusters. It also does not show the sample size unless that information is added separately. Two distributions can therefore have the same boxplot summaries and still differ substantially in their detailed patterns.

Worked Example: Two Data Sets, One Boxplot Summary

Two hypothetical portfolios have the following ordered claim counts per account. Portfolio A has 1, 2, 3, 4, 5, 6, 7, 8; Portfolio B has 1, 1, 4, 4, 5, 5, 8, 8. Use the median-of-halves convention to compare their five-number summaries and explain what a boxplot cannot distinguish.

Step 1: Calculate Portfolio A’s summaries. Its minimum is 1 and maximum is 8. The median is \((4+5)/2=4.5\). The lower half is 1, 2, 3, 4, giving \(Q_1=(2+3)/2=2.5\). The upper half is 5, 6, 7, 8, giving \(Q_3=(6+7)/2=6.5\).

Step 2: Calculate Portfolio B’s summaries. Its minimum is also 1 and maximum is also 8. The median is \((4+5)/2=4.5\). The lower half is 1, 1, 4, 4, so \(Q_1=(1+4)/2=2.5\). The upper half is 5, 5, 8, 8, so \(Q_3=(5+8)/2=6.5\).

Step 3: Compare the results. Both portfolios have the same five-number summary under this convention: minimum 1, \(Q_1=2.5\), median 4.5, \(Q_3=6.5\), and maximum 8. Their IQR is \(6.5-2.5=4\).

Step 4: State the limitation. Portfolio A has values spread one by one across the range, while Portfolio B repeats values at 1, 4, 5, and 8. The shared summary does not reveal that difference in arrangement. A boxplot built from these summaries cannot show whether observations are evenly spread or concentrated at repeated values.

Check. Both sets have the same quartiles, median, and extremes, so the summaries match. Their different repeated values confirm that identical boxplots do not imply identical data.

Common Mistakes and Practical Reading

When interpreting a boxplot, separate what is directly displayed from what is only suggested. Quartiles and the median are positions on the scale; the IQR is their difference; whiskers and points depend on the plotting convention. None of these components, taken alone, proves a cause or identifies a data-quality problem.

1
Read the scale and units.
Confirm whether values represent dollars, days, counts, or another measurement, and note whether the axis is transformed.
2
Locate the quartiles and median.
Read the two box edges as \(Q_1\) and \(Q_3\), and the internal line as the median.
3
Calculate and interpret the IQR.
Use \(Q_3-Q_1\) to describe the span of the middle half, and compare the two distances from the median to the box edges.
4
Check what the whiskers and points mean.
Do not call whisker endpoints the minimum and maximum unless the plotting convention supports that reading. Treat separate points as observations to investigate, not errors to delete automatically.
5
State what remains unknown.
Acknowledge that the plot conceals the exact observations, within-interval concentrations, and potentially important patterns such as repeated values.

Common trap: reading the whiskers as the range. Suppose a plot shows whiskers from 10 to 60 and a separate point at 90. Calling 10 and 60 the data minimum and maximum is incorrect: the point at 90 is an observed value beyond the upper whisker, so the displayed sample maximum is at least 90. The correction is to describe 10 and 60 as whisker endpoints and identify 90 as a separately plotted observation. Whether 10 is the sample minimum still depends on whether the plotting convention includes the minimum in the whisker.

Key takeaway: A boxplot gives a compact account of quartile locations and the spread of the middle half. Interpret whiskers and plotted points using the stated convention, and do not infer detailed shape, data validity, or the full range from the box alone.

Check Your Understanding

For each problem, state the relevant summaries in context and pay attention to the stated convention.

  1. A boxplot of hypothetical call-resolution times has \(Q_1=48\) minutes, median 60 minutes, and \(Q_3=78\) minutes. Calculate the IQR and the distances from the median to each box edge. What does the difference between those distances indicate? (Answer: \(IQR=30\) minutes; the distances are 12 and 18 minutes, so the upper half of the box spans 6 minutes more than the lower half.)
  2. Sorted hypothetical inspection durations are 5, 7, 9, 10, 14, 18, 19, 25 hours. Using the median-of-halves convention, calculate \(Q_1\), the median, \(Q_3\), and the IQR. (Answer: \(Q_1=8\) hours, median \(=12\) hours, \(Q_3=18.5\) hours, and \(IQR=10.5\) hours.)
  3. A boxplot of hypothetical monthly service costs has a lower whisker at $80, a box from $140 to $260, a median at $170, an upper whisker at $390, and a separate point at $520. Calculate the IQR and state what can be said about the $520 observation. (Answer: \(IQR=\$120\); $520 is plotted beyond the upper whisker under the displayed convention, but that alone does not show it is an error or establish the sample maximum if other observations are not shown.)
  4. Two hypothetical groups have identical displayed quartiles \(Q_1=3\), median \(=5\), and \(Q_3=9\), but one group has many repeated observations while the other has values spread throughout each interval. Name one conclusion the shared boxplot supports and one it does not support. (Answer: Both have \(IQR=6\) and the same displayed quartile locations; the boxplot does not reveal whether observations are repeated or spread throughout the intervals.)
  5. A boxplot has whiskers ending at 2 and 14, with separately plotted observations at 18 and 21. A reader reports that the sample range is \(14-2=12\). Correct the statement and explain the limitation. (Answer: The stated 12 is the distance between whisker endpoints, not necessarily the sample range; 21 is an observed value, so the sample maximum is at least 21, while the sample minimum cannot be confirmed without knowing whether the lower whisker reaches it.)
Clinical Biostats