The Honest Middle
US median household income ≈ 100k. The gap exists because billionaires pull the mean up. The median tells you what a typical household earns — the mean tells you the mathematical centre.
Core Insight: The median splits sorted data in half — 50% below, 50% above. It is completely unaffected by how extreme the extremes are.
Formula
Worked Examples
Odd (n=5): 3, 7, 1, 9, 5 → Sorted: 1, 3, 5, 7, 9 → Median = 5
Even (n=6): 3, 7, 1, 9, 5, 11 → Sorted: 1, 3, 5, 7, 9, 11 → Median = 6
Odd: 1 3 [5] 7 9 ← centre element
Even: 1 3 [5 7] 9 11 ← average of pair
Python Implementation
import numpy as np
import statistics
odd_data = [3, 7, 1, 9, 5]
even_data = [3, 7, 1, 9, 5, 11]
print(np.median(odd_data)) # 5.0
print(np.median(even_data)) # 6.0
salaries = [45000, 50000, 52000, 48000, 1_000_000]
print(f"Mean: {np.mean(salaries):,.0f}") # 239,000 ← distorted
print(f"Median: {np.median(salaries):,.0f}") # 50,000 ← honest
R Implementation
odd <- c(3, 7, 1, 9, 5)
even <- c(3, 7, 1, 9, 5, 11)
median(odd) # 5
median(even) # 6
salaries <- c(45000, 50000, 52000, 48000, 1000000)
cat("Mean:", mean(salaries), "Median:", median(salaries), "\n")
Skewness Indicator
Median = Mean → symmetric distribution
Median < Mean → right-skewed (long right tail)
Median > Mean → left-skewed (long left tail)
| Use Case | Recommended |
|---|---|
| Income / wealth | Median |
| House prices | Median |
| Normal exam scores | Either |
| Response times | Median |
| Temperature | Either |
Key Takeaways
- Sort first — median only makes sense on ordered data
- Odd n — exact middle element at position
- Even n — average of the two middle elements
- Outlier resistant — extreme values don't move the median
- 50th percentile — median equals the 50th percentile by definition
- Skew detector — large mean-median gap signals skewed distribution