Intuition The ONE core idea
If you line up your data from smallest to largest , then the positions in that line — the middle, the quarter-marks — tell you everything about centre and spread without ever being fooled by one crazy value. A box plot is simply a picture of those position-marks .
This page assumes you know nothing . Before you can read the parent note on Box-and-whisker plots — quartiles, IQR , you need a small toolkit of ideas. We build each one from zero, anchor it to a picture, and say why the topic needs it . Every later idea leans only on earlier ones.
Before symbols, the raw material.
Definition Data set and a value
A data set is just a collection of numbers you measured — heights, incomes, test scores. Each single number is a value . We usually write how many values there are as a letter, most often n .
Picture: imagine each value as a bead . Your whole data set is a handful of loose beads .
Intuition Why we need this word
Everything else — median, quartile, spread — is an operation on this pile of beads . If we can't name "the pile" and "how many beads n ", we can't describe anything we do to it.
n is our very first symbol.
n
n means the count of how many values are in the data set . If your data is 2 , 3 , 4 , 5 , 7 , 9 , 12 , then n = 7 because there are seven numbers.
The single most important move in this whole topic.
Look at the figure. On top, the beads are a jumbled pile (unsorted). On the bottom, the same beads stand in a queue , shortest on the left, tallest on the right. That rearrangement is called sorting ascending .
Definition Sorted (ascending) data
To sort ascending means to rearrange the values so each is ≥ the one before it — smallest first, largest last. Nothing is added or removed; only the order changes.
Intuition Why the topic can't start without it
Quartiles are defined by position in the line ("the one a quarter of the way along"). A position only means something once everyone is standing in order. In a jumbled pile, "the middle one" is nonsense. So Step 0 of every box-plot calculation is: sort.
Common mistake Sorting changes positions, not values
Sorting does not change any number. The value 30 is still 30 ; it just moves to where it belongs in the line. People sometimes fear sorting "loses information" — it never does.
This is subtle and worth its own picture.
Each bead in the sorted queue has two different numbers :
its position — where it stands in line: 1st, 2nd, 3rd, … (shown below the line in yellow).
its value — what number it is (shown inside the bead in blue).
Definition Position (rank)
The position (or rank ) of a value is its place in the sorted queue , counting from 1 on the left.
Intuition Why keep them separate
Quartiles are found by first choosing a position (like "position 4") and then reading off the value there . Confusing the two — treating a position number as if it were a data value — is the classic beginner error. Keep the yellow ruler (positions) and blue beads (values) in separate mental drawers.
A box plot marks the queue at 2 1 , 4 1 , 4 3 of the way. So we must be crystal clear what a fraction of a queue means.
Definition A fraction of the way along
"Halfway along " the queue means the point with equally many beads on each side . "A quarter of the way " means one bead in four is to your left, three in four to your right .
Picture: stand in the sorted queue. Walk until exactly half the people are behind you — that spot is the halfway mark. Walk only a quarter of the crowd — that's the quarter mark.
Intuition Why fractions, not the average?
We could describe the middle by averaging all values. But an average adds every number , so one giant value drags it. A fraction-of-the-way position only cares about order , not size — so a giant is just "the last person in line", no more powerful than anyone else. This is the whole reason position-based measures are called robust (see Outliers and Robust Statistics ).
Now we can name the halfway mark.
Definition Median, written
Q 2
The median is the value at the halfway position of the sorted data. Its symbol is Q 2 (the second "quartile", explained next). About 50% of the data sits below it.
How to find it depends on whether n is odd or even — because "the exact middle" only exists when the count is odd.
n odd (top row, 7 beads): there is a lone middle bead. Its position is 2 n + 1 = 2 7 + 1 = 4 , so the median is the 4th value .
n even (bottom row, 6 beads): no single bead is in the middle — the centre falls between two beads (3rd and 4th). The median is their average .
Intuition Why average the two middle values when
n is even?
With an even count, the fair "centre point" genuinely lies in the gap between two beads. Picking either one alone would tilt slightly left or right. Averaging them lands exactly in the gap — the honest middle. See Median and Measures of Central Tendency for more.
"Quart" means four . Quartiles are the marks that cut the queue into four equal-count groups .
Definition Lower and upper quartiles
==Q 1 == (first / lower quartile): the value a quarter of the way along — about 25% of data below it. It is the median of the lower half .
==Q 3 == (third / upper quartile): the value three-quarters of the way along — about 75% below. It is the median of the upper half .
Together with Q 2 , the three cuts Q 1 , Q 2 , Q 3 make four equal parts .
Intuition Why "median of each half" instead of just counting to position
n /4 ?
A raw position like n /4 often lands between two beads and different textbooks patch that gap differently. The clean, unambiguous rule is: split at the median, then take the median of each half. You already know how to take a median (§4), so this reuses one tool twice — nothing new to learn.
Common mistake Do you keep the median in the halves?
If n is odd , the median is one specific bead that belongs to neither half — drop it, then split the rest. If n is even , there is no single median bead, so the two halves each already hold exactly n /2 beads. This detail decides your Q 1 , Q 3 , so never skip it.
These three symbols are exactly the 25th, 50th, and 75th Percentiles and Quantiles — quartiles are just percentiles at nice quarter-marks.
The parent note's spread measure is Q 3 − Q 1 . Why subtract?
Definition Subtraction as a gap on the number line
On a number line, b − a measures the distance (the gap) between a and b . Bigger difference → they are further apart → the data is more spread out .
Intuition Why this particular gap?
The full range (max − min, see Range and Spread ) measures the gap between the two most extreme beads — the least trustworthy ones. Q 3 − Q 1 instead measures the gap between the quarter-marks, ignoring the outer 25% on each side . One giant can't stretch it. That's why IQR is the robust spread.
Last symbol to unpack: the number 1.5 and the word "fence".
A fence is a boundary line placed a fixed distance beyond the box. Any bead past it is flagged as unusually far out — an outlier .
Lower fence = Q 1 − 1.5 IQR , Upper fence = Q 3 + 1.5 IQR
Intuition Why multiply the IQR by a number at all?
We need a yardstick for "far". The IQR is a natural yardstick — it's how wide the typical middle is. Walking "1.5 box-widths" beyond each edge means the distance scales with your own data's spread: tight data gets tight fences, loose data gets loose fences. The choice 1.5 is a convention tuned so roughly 0.7% of Normal Distribution data gets flagged — rare but not never.
Fractions of the way along
Multiplier 1.5 and fences
Recall Can you answer each without peeking?
What does the symbol n stand for? ::: The count of how many values are in the data set.
What must you always do first (Step 0) with any data before finding quartiles? ::: Sort it ascending (smallest to largest).
What is the difference between a value's position and its value ? ::: Position is where it stands in the sorted queue (1st, 2nd, …); value is the actual number it is.
What does "a quarter of the way along" the queue mean? ::: One bead in four is to your left, three in four to your right.
What is the median Q 2 and how does finding it differ for odd vs even n ? ::: The halfway value; for odd n it's the single middle value at position ( n + 1 ) /2 , for even n it's the average of the two middle values.
What are Q 1 and Q 3 in one phrase each? ::: Q 1 = median of the lower half; Q 3 = median of the upper half.
Why does b − a measure spread? ::: It is the distance/gap on the number line — bigger gap means more spread out.
Write the IQR formula. ::: IQR = Q 3 − Q 1 .
Why multiply the IQR (rather than use a fixed number) to set outlier fences? ::: So the "far" yardstick scales with the data's own spread; 1.5 IQR beyond each edge.