Five-Number Summary and Box Plots
A compact way to describe a batch of numbers — minimum, first quartile, median, third quartile, maximum — and the standard picture (a box plot) that turns those five numbers into a shape you can compare across many groups at a glance.
Prerequisites: Order Statistics, Standard Deviation
You have a year of daily P&L for a strategy and want to describe it in a sentence before diving into anything fancier. "The mean daily P&L was $1,200" tells you almost nothing on its own — a single $500,000 blow-up day and 250 quiet days averaging $800 can produce the exact same mean as 250 consistently solid $1,200 days, yet those are completely different risk profiles. The mean is easily dragged around by a few extreme values, and standard deviation shares the same weakness. What you often want first is a description built entirely from positions in the sorted list — which value is in the middle, which values mark off the middle chunk, which values are the extremes — because those don't budge much just because one day was wild.
An analogy: a classroom's height lineup
Line up thirty students from shortest to tallest. Five landmarks describe the whole line without you needing to write down all thirty heights: the shortest student, the tallest student, the student standing exactly in the middle, and two more students — one a quarter of the way along the line, one three-quarters of the way along. Those five positions tell you the full spread of the line, where the crowded middle sits, and how far the extremes stick out, all without being thrown off if one kid happens to be freakishly tall. That's the whole idea of the five-number summary: describe the shape of a batch of numbers using landmarks in the sorted order, not an average that any one extreme value can drag around.
The five numbers, one symbol at a time
Sort your observations from smallest to largest. The five landmarks are:
- Minimum, — the smallest value.
- First quartile, — the value one-quarter of the way through the sorted list (25% of observations lie below it).
- Median, — the value exactly in the middle (50% of observations lie below it).
- Third quartile, — the value three-quarters of the way through (75% of observations lie below it).
- Maximum, — the largest value.
The middle 50% of the data, from to , is called the interquartile range:
In plain English: the IQR is the width of the box that contains the "typical" middle half of your observations, ignoring the bottom and top quarters entirely — a spread measure that a single wild outlier can barely move, unlike the standard deviation.
A box plot draws this directly: a box from to with a line at the median, and whiskers extending out to the most extreme point still within
with any points beyond that range plotted individually as dots — flagged as candidate outliers. In plain English: the whiskers stretch to cover "normal-looking" spread beyond the box, using 1.5 box-widths as a conventional cutoff, and anything further out gets drawn separately so it doesn't silently stretch the whisker to hide how far away it really is.
Worked example 1: eleven days of P&L by hand
Sorted daily P&L ($000s): . With , the median is the 6th value: . is the median of the lower half (values ): the middle of those five is . is the median of the upper half (): . So:
The whisker fence is on the low side and on the high side. Every value except 40 falls inside , so the upper whisker stops at 12 (the largest point still inside the fence) and 40 is flagged as an outlier, plotted as an isolated dot. The five-number summary — — immediately tells you the typical day nets a few thousand dollars, half the days fall between −$1,000 and $9,000, and there's one exceptional $40,000 day sitting well outside the normal pattern, all without a mean or standard deviation calculation that $40,000 day would have dominated.
Worked example 2: comparing two strategies side by side
Two strategies, summarized:
| Min | Median | Max | IQR | |||
|---|---|---|---|---|---|---|
| Strategy A | ||||||
| Strategy B |
Strategy A has a higher median ( vs ) but a much wider IQR ( vs ) — its typical middle-half spread is 2.5× wider. Strategy B's box sits in a tight band from 1 to 5, meaning most days cluster close together, while A's box from to shows a much more dispersed "normal" outcome even before considering the $40,000 outlier day. If you only compared the two means, you might miss that A's slightly higher average return comes with meaningfully more day-to-day variability in the typical (non-outlier) range — exactly the comparison a five-number summary is built to surface at a glance.
What this means in practice
Box plots are the fastest way to eyeball dozens of strategies, factors, or backtests side by side — lining up their boxes reveals which ones are tightly consistent versus wildly dispersed, and which have outlier days worth investigating individually, before you compute a single formal statistic. Because the five-number summary is built from sorted positions rather than sums, it's naturally robust to the exact kind of fat-tailed, outlier-prone data that finance produces constantly, which is precisely where mean-and-standard-deviation summaries are least trustworthy. It's a description, not an inference — a box plot tells you what the data looks like, not whether a difference between two groups is statistically significant, for which you'd reach for a formal test.
The five-number summary (min, , median, , max) and the box plot that draws it describe a batch of data using positions in the sorted order rather than a mean, making them resistant to the exact kind of extreme values that finance data is full of. The interquartile range, , measures the spread of the typical middle half and is the basis for the standard 1.5×IQR rule for flagging outliers.
The classic mistake is treating the 1.5×IQR whisker rule as a definition of "real" outliers to be deleted, rather than a visualization convention for what to look at more closely. A point outside the whiskers might be a data error worth removing — or it might be the single most informative observation in the dataset, like the one day a strategy's tail-risk hedge paid off. Never automatically drop box-plot outliers before understanding, case by case, why each one is there.
Related concepts
Practice in interviews
Further reading
- Tukey, Exploratory Data Analysis, ch. 2
- Wasserman, All of Statistics, ch. 6