Concept

Median

Definition

The median is the value that sits exactly in the middle of an ordered dataset: half of the observations are smaller, half are larger. To find it, sort the data and pick the central value; with an even number of observations, the median is the average of the two middle values. Unlike the mean, the median depends only on the rank order of observations, not on their numerical magnitudes — extreme values cannot drag it around.

This property makes the median the standard measure of central tendency for distributions that are skewed or contain outliers. Income, house prices, and survival times are routinely reported using the median rather than the mean for exactly this reason.

Why it matters

How it works

Computing the median requires only one operation that the mean does not: sorting. Once the data is ordered from smallest to largest, the median is read off directly — the value at position (n + 1) / 2 for an odd sample size, or the average of positions n / 2 and n / 2 + 1 for an even sample size. No arithmetic on the original values is needed beyond that midpoint average, which is what gives the median its insensitivity to extreme observations.

The median generalizes to other quantiles. The first quartile is the value below which a quarter of the data falls; the third quartile is the value below which three-quarters falls. Together with the minimum, the median, and the maximum, these form the five-number summary. The boxplot visualizes that summary directly and is the standard companion to the histogram when comparing distributions across groups. When the median sits visibly closer to the lower quartile than the upper, the distribution is right-skewed; when closer to the upper, left-skewed.

Where it goes next

Continue exploring

Tags