CalculatorsToolsGuides 日本語
BenchFig › Guides › How to read and make a box plot (quartiles, whiskers, outliers)
Publication figures

How to read and make a box plot (quartiles, whiskers, outliers)

A box plot shows the median, quartiles, spread and outliers of a data set in one compact figure. Because it does not rely on the mean and SD, it suits skewed data, data with outliers, and results of nonparametric tests. But the definition of the whiskers and the way quartiles are computed differ between programs, so unless the legend says which, readers may misread it.

Updated: BenchFig日本語

The parts of a box plot

How to read it
  • Centre line: the median (middle value)
  • Box: from the first quartile (25%) to the third quartile (75%); it holds the middle 50% of values. Its height is the interquartile range (IQR)
  • Whiskers: in the most common (Tukey) definition, they reach the most extreme data point within 1.5 × IQR of the box
  • Points: values beyond the whiskers (drawn as outliers). Some plots overlay every data point

If the median line sits towards one end of the box, or the whiskers are of unequal length, the distribution is skewed. If two boxes barely overlap, the distributions clearly differ.

Example: computing it from 12 values

Diameters of 12 cells (µm, made up), in order:

12.1, 13.4, 14, 14.2, 14.8, 15.1, 15.5, 15.9, 16.3, 17, 17.6, 24.5

ValueCalculationResult
MedianAverage of the 6th and 7th values, (15.1 + 15.5)/215.3
First quartile Q1Position (12 − 1) × 0.25 + 1 = 3.75: 14.0 + 0.75 × (14.2 − 14.0)14.15
Third quartile Q3Position (12 − 1) × 0.75 + 1 = 9.25: 16.3 + 0.25 × (17.0 − 16.3)16.475
IQRQ3 − Q12.325
Whisker limits (fences)Q1 − 1.5 × IQR to Q3 + 1.5 × IQR10.66 to 19.96
Whisker endsSmallest and largest data inside the fences12.1 and 17.6
Outliers (points)Data outside the fences24.5

24.5 is above the upper fence of 19.96, so the whisker stops at 17.6 and 24.5 is drawn as a point. That one value pulls the mean (15.87) above the median (15.3) and inflates the SD to 3.12.

0510152025ControlTreatedCell diameter (µm)
Bar + SD
10152025ControlTreatedCell diameter (µm)
Box plot
10152025ControlTreatedCell diameter (µm)
Box plot + points
The same data (made up, n = 12 each) drawn three ways. The bar + SD hides that 24.5 in Control pulls up the mean and SD. The box plot shows 24.5 as an outlier point, and the median and quartiles show the center and spread. Overlaying the points shows n and the shape best.

Quartiles differ between programs

There are at least nine definitions of sample quantiles (Hyndman and Fan’s types 1 to 9), so the same data can give slightly different Q1 and Q3 in different software. The smaller n, the bigger the difference.

MethodWhere it is usedQ1Q3
Linear interpolation (type 7, position (n − 1)p + 1)R quantile() and ggplot2 box plots, numpy default, Excel QUARTILE.INC, BenchFig14.1516.475
Position (n + 1)p (type 6)Excel QUARTILE.EXC, SPSS percentiles by default (its Explore box plots use Tukey’s hinges), Minitab and others14.0516.825
Tukey’s hinges (medians of the lower and upper halves)R boxplot() (fivenum), Tukey’s original definition14.116.65

Even within R, quantile() and boxplot() can disagree. None is “the” correct one; naming your software in the paper is enough, but remember these differences when comparing figures made with different programs.

Whisker definitions vary too

Whisker definitionNotes
Most extreme data within 1.5 × IQR of the quartiles (Tukey)The most common. Shows outliers as points. BenchFig uses this definition
Minimum to maximumNo outlier points; a single extreme value stretches the whisker
10th–90th or 5th–95th percentiles, etc.Used with large n; values outside are usually drawn as points

The definition changes how the figure looks, so always state it in the legend. If you just write “whiskers”, readers may assume minimum to maximum.

Draw the sample data as a box plotChoose “Box plot” under Graph type and turn on “Overlay individual points” to get the third panel above. Significance brackets work the same way.
Open for free →

Box plot, bar graph or points + median?

How to describe it in a paper

State in the legend what the box, center line, whiskers and points show, and n. For example: “Boxes show the interquartile range, center lines the median, and whiskers extend to the most extreme values within 1.5 × IQR of the quartiles; points beyond the whiskers are plotted individually. n = 12.” BenchFig writes this sentence for you in the Methods text, matching the graph type you chose.

FAQ

Does an “outlier” in a box plot mean I can delete it?

No. The points only highlight values beyond the whiskers (more than 1.5 × IQR from the quartiles); they do not mean the values may be removed. Exclude data only for experimental reasons such as a failed measurement, and report the rule and how many were excluded.

Can I use a box plot with a small n?

You can draw one, but with n ≈ 5 the quartiles depend on one or two values and the box is unstable. With small n, plot every point or use points with the median; if you use a box plot, overlay the points.

Can I add the mean to a box plot?

Some people do (a “+” or “×” marker). A box plot is rank-based, so if you add the mean, say so in the legend. A large gap between mean and median signals a skewed distribution.

How is it different from a violin plot?

A violin plot draws the distribution’s shape (density) as a mirrored outline and can reveal, for example, two peaks. A box plot shows only a five-number summary. Both can mislead with small n, so overlaying the points is the safe choice.

Draw a box plot with sample dataChoose “Box plot” under Graph type on the Graph screen to redraw with boxes (IQR), median, whiskers (1.5 × IQR) and outliers. You can overlay the individual points too.
Open for free →
Your own data, all the way to the final figure.Loading your files, saving, and journal-ready export (PDF, TIFF, PNG, SVG) are in BenchFig Pro for Windows, updated based on researchers’ requests: ¥3,980/year (2 PCs), with lab and perpetual licenses too.
About the app →

Related guides

Product and journal names are trademarks or registered trademarks of their respective owners.