01 / 20

Data Representation
& Summary Stats

Master the tools for organising data and computing measures of central tendency and spread: mean, median, quartiles, and IQR.

IB Mathematics

Why Summarise Data?

Raw datasets can contain hundreds or thousands of values. Summary statistics let us describe an entire dataset with just a few numbers, making patterns, centre, and spread immediately visible.

Centre
Where most data clusters: mean and median
Spread
How far data values extend: range, IQR, standard deviation
Shape
Symmetry, skewness, and outliers visible in displays

Common Data Displays

Histogram
Bars show frequency of values in equal-width intervals (continuous data)
Box Plot
Five-number summary at a glance: min, \(Q_1\), median, \(Q_3\), max
Cumulative Frequency
Running total curve used to estimate median and quartiles

The Mean \(\bar{x}\)

The arithmetic mean is the sum of all data values divided by the number of values. It is the "balance point" of the dataset.

The Median

The median is the middle value when data are arranged in ascending order. It splits the dataset into two equal halves.

1
Sort the data in ascending order.
2
If \(n\) is odd: median = the \(\left(\frac{n+1}{2}\right)\)th value.
3
If \(n\) is even: median = mean of the \(\frac{n}{2}\)th and \(\left(\frac{n}{2}+1\right)\)th values.

Quartiles & the IQR

Quartiles divide sorted data into four equal parts. The interquartile range measures the spread of the central 50% of data.

\(Q_1\)
Lower quartile: median of the lower half (25th percentile)
\(Q_2\)
Median of the full dataset (50th percentile)
\(Q_3\)
Upper quartile: median of the upper half (75th percentile)

Anatomy of a Box Plot

10 20 30 40 50 60 Min 13 \(Q_1\) 23 Median 33 \(Q_3\) 43 Max 52 \(\text{IQR} = 43 - 23 = 20\)

Mean vs Median: When to Use Which?

Mean \(\bar{x}\) Median
Calculation Sum ÷ count Middle value when sorted
Affected by outliers? Yes No
Best for Symmetric data Skewed data
Uses all values? Yes No
IB notation \(\bar{x}\) \(Q_2\)

How to Find Quartiles

1
Sort all \(n\) data values in ascending order.
2
Find the median (\(Q_2\)). This splits the data into a lower half and an upper half.
3
Lower quartile \(Q_1\): find the median of the lower half (values below \(Q_2\)).
4
Upper quartile \(Q_3\): find the median of the upper half (values above \(Q_2\)).
5
Compute IQR: \(\text{IQR} = Q_3 - Q_1\).

Worked Example 1

Find the mean, median, \(Q_1\), \(Q_3\), and IQR for the dataset:
3, 7, 8, 5, 12, 14, 21, 13, 18

1
Sort: 3, 5, 7, 8, 12, 13, 14, 18, 21  (\(n = 9\))
2
Mean: \(\bar{x} = \frac{3+5+7+8+12+13+14+18+21}{9} = \frac{101}{9} \approx\) 11.2
3
Median: 5th value = 12
4
\(Q_1\): median of {3, 5, 7, 8} = \(\frac{5+7}{2} =\) 6
5
\(Q_3\): median of {13, 14, 18, 21} = \(\frac{14+18}{2} =\) 16

Worked Example 2: Grouped Data

A grouped frequency table shows test scores. Find the estimated mean.

Score Range Midpoint \(x_i\) Frequency \(f_i\) \(f_i \cdot x_i\)
0 – 2010440
20 – 40308240
40 – 605015750
60 – 807010700
80 – 100903270

Worked Example 3: Cumulative Frequency

Using the same data (\(n=40\)), estimate the median and quartiles from a cumulative frequency curve.

0 10 20 30 40 Cumulative Freq. 0 20 40 60 80 100 Score ~50 20 ~36 ~65

Effect of Outliers

Consider the dataset: 5, 6, 7, 8, 9, 10, 50. The extreme value 50 is an outlier.

0 10 20 30 40 50 outlier mean ≈ 13.6 median = 8

Common Mistakes

✕ Forgetting to sort
The median requires data in ascending order. Finding the "middle" of unsorted data gives a wrong answer.
✕ Including the median in halves
When \(n\) is odd, the median value itself should be excluded from both halves when computing \(Q_1\) and \(Q_3\).
✕ Using endpoints instead of midpoints
For grouped data, the mean formula requires the midpoint of each class interval, not the upper or lower boundary.

Summary of Key Formulas

Statistic Formula / Rule Resistant?
Mean \(\bar{x} = \frac{\sum x_i}{n}\) No
Median Middle value when sorted Yes
\(Q_1\) Median of lower half Yes
\(Q_3\) Median of upper half Yes
\(\text{IQR}\) \(Q_3 - Q_1\) Yes
\(\text{Range}\) \(\text{Max} - \text{Min}\) No

Question 1 of 5

The dataset is 2, 5, 7, 9, 11. What is the mean?

Question 2 of 5

For the sorted dataset 3, 5, 8, 12, 15, 18, 22, what is \(Q_1\)?

Question 3 of 5

A box plot shows \(Q_1 = 20\), \(Q_3 = 48\). What is the IQR?

Question 4 of 5

Which measure of centre is most appropriate for a heavily right-skewed dataset?

Question 5 of 5

A grouped frequency table has class intervals 0–10, 10–20, 20–30 with frequencies 5, 12, 3. What is the estimated mean?