Statistics & probability · AA SL & HL
Data and summary statistics
Choose and calculate measures of centre and spread, read frequency tables and distinguish exact values from grouped estimates.
Course focus: AA SL & HL: shared methods are taught first. Sections labelled HL extension go beyond SL requirements.
Before you start: Ordering numbers, arithmetic and interpreting tables.
Build it from the beginning
A measure of centre describes a typical value; a measure of spread describes variation. Sort the data before finding the median. The mean uses every value, so one extreme observation can move it substantially.
A first walkthrough
Find the mean, median and range of 2, 3, 3, 4, 8.
- The sum is 20 and there are five values, so the mean is 4.
- The ordered middle observation is 3, the median.
- The range is \(8-2=6\). Each statistic answers a different question.
The foundations behind the method
Understand what the symbols mean
A statistic compresses information, so choose it for a purpose. A centre describes a typical location; a spread describes variation. The mean uses all values and is sensitive to extremes, while the median depends on ordered position. Frequency tables weight values by how often they occur.
How the ideas connect
Adding a constant to every observation shifts measures of location but leaves distances from the centre unchanged. Multiplying by a positive factor scales both location and standard deviation, while variance scales by its square. Quartile and sample-standard-deviation conventions must match the task or calculator setting.
Start with the idea
Build your understanding
A summary compresses a distribution, so every measure hides some information. Combine a measure of centre with a measure of spread, and refer to the original context. Exact raw data and grouped intervals permit different levels of precision.
Resistance
The median and interquartile range are less sensitive to extreme values than the mean and standard deviation. This is a property of how each is calculated, not a rule that one is always better.
Estimates from groups
Midpoints and interpolation replace unknown positions inside classes by modelling assumptions. The resulting values are estimates even if the arithmetic is exact.
Compare the approaches
Choose by the information in the question, rather than the formula you recognise first.
Mean and standard deviation
When it helpsUseful when using all numerical observations and their spread.
Check before using itExtreme values can have a strong effect.
Median and interquartile range
When it helpsUseful for skewed data or outlier-resistant comparisons.
Check before using itThey do not describe the detailed behaviour of the tails.
Your method plan
- Identify data type, grouping and any outliers.
- Choose centre and spread suited to the purpose.
- State estimates, units and the feature lost in the summary.
Learn the methods
Learn step by step
1. Centre
Order raw data before finding the median. The mode is the most frequent value and may be absent or nonunique. The mean uses every observation and is sensitive to outliers; the median depends on rank and is often more resistant. A table frequency counts repeated observations; do not average its listed values as if each occurred once.
Weighted mean
Why this formula works
A frequency fᵢ means that value xᵢ appears fᵢ times. Its contribution to the total is therefore fᵢxᵢ. Divide the weighted total by the number of observations, not by the number of rows in the table.
\(\bar x=\sum f_ix_i/\sum f_i\). For grouped estimates replace xᵢ with class midpoint.
Quick example
Values 2 and 5 with frequencies 3 and 1 have mean \(\frac{3\times 2+1\times 5}{4}=2.75\), not \(\frac{2+5}{2}\).
Worked example: A small ordered data set
For 2, 3, 3, 4, 8, find mean, median, mode and range.
- The sum is 20 and there are five observations, so \(\text{mean}=4\).
- The middle observation is 3, giving \(\text{median}=3\). The repeated value 3 is the mode.
- \(\text{Range}=8-2=6\). The large final value raises the mean above the median.
Worked example: A frequency table
Values \(1,2,3\) have frequencies \(2,3,5\). Find mean and median.
- There are 10 observations. The weighted sum is \(2+6+15=23\), so \(\text{mean}=2.3\).
- The fifth observation is 2 and the sixth is 3, so \(\text{median}=\frac{2+3}{2}=2.5\).
- The mode is 3. Averaging the three listed values would incorrectly give mean 2.
2. Spread
The range is largest minus smallest. Quartiles split ordered data into parts, and \(IQR=Q_{3}-Q_{1}\) describes the middle half. Quartile conventions can differ for small data sets, so use the convention specified or that used in the course/question. Standard deviation uses all values and expresses spread around the mean.
Population spread
Why this formula works
Variance averages squared deviations from the mean, avoiding positive and negative deviations cancelling. Expanding \((x-\text{mean})^{2}\) and using the definition of the mean produces the shortcut \(E(X^2)-[E(X)]^2\). Standard deviation takes the square root to restore the original units.
\(\sigma^2=\sum f_i(x_i-\bar x)^2/\sum f_i=\sum f_ix_i^2/\sum f_i-\bar x^2\). Sample variance instead divides squared deviations by \(n-1\).
Quick example
For \(2,4,6\), the mean is 4. Population variance is \(\frac{4+0+4}{3}=\frac{8}{3}\); the sample variance would instead divide by 2.
3. Frequency and unknown frequencies
Total observations are the sum of frequencies. A known mean gives a weighted-total equation. Combined with the total frequency this can determine missing frequencies. Require frequencies to be nonnegative integers and check the final table.
4. Grouped data
Individual observations inside each class are unknown. Use class midpoints for an estimated mean, and name the modal class rather than claiming an exact mode. On histograms with unequal widths, frequency is represented by area: frequency density is frequency divided by class width.
IQR and density
Why this formula works
IQR subtracts the lower quartile from the upper to measure the middle half’s spread. For a histogram, bar area represents frequency, so height must equal frequency divided by width when widths differ.
\(\mathrm{IQR}=Q_3-Q_1\). Histogram density is frequency divided by class width. A common outlier rule is below \(Q_1-1.5\,\mathrm{IQR}\) or above \(Q_3+1.5\,\mathrm{IQR}\).
Quick example
A class of width 5 containing 20 observations needs density 4. A class of width 10 with the same frequency needs density 2, giving the same area 20.
Worked example: A grouped estimate
Scores in [0,10), [10,20), [\(20,30\)] have frequencies \(2,5,3\). Estimate the mean.
- Use class midpoints \(5,15,25\); individual observations are unknown.
- The weighted midpoint sum is \(2\times 5+5\times 15+3\times 25=160\) and total frequency is 10.
- The estimated mean is 16. It is not necessarily the exact mean; the modal class is [10,20), not a known exact mode of 15.
5. Read what a box plot can and cannot tell you
The box spans \(Q_{1}\) to \(Q_{3}\) and marks the median, describing the middle half of the data. Whiskers follow the stated minimum/maximum or outlier convention. A long region indicates a wide interval of values, not necessarily more observations than a short region. A box plot does not reveal every data value, the mean or the shape of each quarter. Asymmetry can suggest skew, but a few summary statistics cannot establish the complete distribution.
6. Calculate quartiles explicitly and state the convention
Order raw values first. For odd n, the median is the middle observation; for even n, average the two middle observations. Under the median-of-halves convention used in these core-book examples, exclude the single overall median when n is odd, then find the median of each remaining half. With even n, split all observations into equal halves. Some software uses interpolated quartiles or includes the median in both halves, so follow any convention specified by the question and do not silently mix outputs from different methods.
Calculate quartiles explicitly and state the convention
Why this formula works
The quartiles divide the ordered observations into lower and upper halves. Taking the median of each half identifies their centres; excluding a single odd-sample median gives equal numbers of observations in both halves.
Median rank is \(\frac{n+1}{2}\); for even \(n\), average ranks \(\frac n2\) and \(\frac n2+1\). Under the stated halves convention, \(Q_1\) is the median of the lower half and \(Q_3\) the median of the upper half.
Quick example
For ordered values \(2,4,5,7,9,11,14\), the median is 7. Exclude it: \(Q_{1}=4\) and \(Q_{3}=11\), so \(IQR=7\).
Worked example: An even sample with averaged quartiles
Find median, \(Q_{1}\), \(Q_{3}\) and IQR for \(1,3,4,6,8,10,13,17\) using median-of-halves.
- There are eight observations. The median averages the fourth and fifth: \(\frac{6+8}{2}=7\).
- The lower half is \(1,3,4,6\), with median 3.5. The upper half is \(8,10,13,17\), with median 11.5.
- Thus \(Q_{1}=3.5\), \(Q_{3}=11.5\) and \(IQR=8\). The range is \(17-1=16\), a different statistic.
7. Use outlier fences and compare distributions in context
The 1.5-IQR rule flags values strictly below \(Q_{1}-1.5\) IQR or strictly above \(Q_{3}+1.5\) IQR. A value on a fence is not outside it. A modified box plot draws whiskers to the most extreme non-outliers and marks outliers separately; an ordinary five-number plot may instead extend to minimum and maximum. Read the convention used. Compare data sets using both a centre measure and a spread measure, with units and a conclusion in context. A lower median does not imply every observation is lower.
Use outlier fences and compare distributions in context
Why this formula works
IQR measures the middle half’s spread. Extending it by 1.5 times at each end is a conventional screening rule, not a proof that a flagged observation is wrong. Modified whiskers keep flagged extremes separate from the main spread.
Lower \(\text{fence}=Q_{1}-1.5(Q_{3}-Q_{1})\); upper \(\text{fence}=Q_{3}+1.5(Q_{3}-Q_{1})\). Outliers satisfy strict exterior inequalities.
Quick example
With \(Q_{1}=10\) and \(Q_{3}=18\), \(IQR=8\) and fences are −2 and 30. A value 31 is flagged; a value 30 is not.
Worked example: Compare two processing methods
Method A has median 16 min, \(Q_{1}=12\) and \(Q_{3}=20\). Method B has median 15 min, \(Q_{1}=13\) and \(Q_{3}=17\). Compare typical time and consistency.
- B has the smaller median: a typical central processing time is 1 minute shorter.
- A has \(IQR=8\) min and B has \(IQR=4\) min. B’s middle half is less spread out, suggesting more consistent times.
- Neither statement proves every B time is shorter, or that its maximum is smaller; those conclusions need more data.
8. Cumulative frequency, percentiles and interpolation
A cumulative total counts observations up to a class boundary. Plot grouped cumulative values at the upper boundaries, with an initial zero at the lowest boundary. To estimate a percentile, find the corresponding cumulative count and read horizontally to the curve, then down to the data axis. If no graph is supplied and linear interpolation is appropriate, interpolate within the containing class, explicitly treating this as an estimate. For an “above” count subtract the cumulative count from the total. Exact proportions inside a class are not known from grouped data alone.
Cumulative frequency, percentiles and interpolation
Why this formula works
Under a uniform-within-class approximation, the fraction of a class width traversed equals the fraction of its frequency accumulated. Solving this proportion gives the linear-interpolation estimate, not an exact recovered observation.
Estimated percentile \(x_p=L+w(pN-C)/f\), where p is a decimal proportion, L lower class boundary, w width, C cumulative count before the class and f its frequency.
Quick example
With \(N=40\), median target is 20. If the containing class is [10,20), preceding cumulative count 12 and frequency 16, the estimate is \(10+10\frac{20-12}{16}=15\).
Worked example: Estimate several percentiles from groups
Classes [0,10), [10,20), [\(20,30\)] have frequencies \(5,15,10\). Estimate the median and 90th percentile by linear interpolation.
- The total \(N=30\) and cumulative counts at \(10,20,30\) are \(5,20,30\).
- Median target 15 lies in [10,20): estimate \(10+10\frac{15-5}{15}=\frac{50}{3}\approx 16.67\).
- The 90th-percentile target is 27, in [\(20,30\)]: estimate \(20+10\frac{27-20}{10}=27\). Both estimates rely on the within-class approximation.
9. Transform data and choose a resistant measure
Adding a constant shifts every centre but leaves differences between observations unchanged. Multiplying by a scales differences by \(|a|\) and squared differences by \(a^{2}\). For a negative scale, the order reverses and the lower and upper quartiles swap roles before transforming. Outliers affect mean and standard deviation strongly; median and IQR often describe skewed or outlier-heavy data more robustly. State which measure you used and why it fits the distribution rather than declaring one measure always best.
Transform data and choose a resistant measure
Why this formula works
For \(y=ax+b\), deviation from the new mean is a(x−mean x), because the additive shift cancels. Taking absolute or squared deviations explains the \(|a|\) and \(a^{2}\) factors; order reversal explains the quartile swap for \(a<0\).
\(\bar y=a\bar x+b\) \(\sigma_y=|a|\sigma_x\) \(\operatorname{Var}(Y)=a^2\operatorname{Var}(X)\), range and IQR scale by \(|a|\).
Quick example
Adding 10 to every mark adds 10 to mean and median, but changes neither standard deviation nor IQR.
Worked example: A score transformation
Scores X have mean 12, standard deviation 3 and IQR 5. Find these summaries for \(Y=2X+10\).
- The new mean is \(2(12)+10=34\).
- The standard deviation is \(|2|(3)=6\) and IQR is \(|2|(5)=10\).
- The variance is \(6^{2}=36\). Adding 10 has no effect on the spread measures.
10. Grouped estimates and unequal-width histograms
Class intervals must account for every observation once: interpret boundary symbols before counting “at least” or “below”. Midpoints estimate unknown values, so a grouped mean and standard deviation are generally estimates. A modal class gives the most frequent class; it is not a known exact mode. When histogram widths differ, the bar’s area represents frequency, so the height is frequency density. The tallest density bar need not contain the most observations. State whether your comparison concerns frequency, density or approximate centre.
Grouped estimates and unequal-width histograms
Why this formula works
Histogram area is width times height. To make this equal the class frequency f, choose height \(f/\text{width}\). Midpoint estimates replace the unobserved individual values by a representative centre, so they cannot recover within-class variation exactly.
Frequency density =\(\frac{f}{w}\); frequency =\(\text{density}\times \text{width}\). Grouped mean estimate \(\bar x\approx\sum f_im_i/\sum f_i\), with midpoint mᵢ.
Quick example
A width-5 class with frequency 12 has density 2.4. A width-10 class with frequency 18 has density 1.8: the first bar is taller, but the second represents more observations.
Worked example: An unequal-width table
Classes [0,5), [5,15), [\(15,20\)] have frequencies \(12,18,10\). Find histogram heights and estimate the mean.
- The widths are \(5,10,5\), so densities are \(2.4,1.8,2\) respectively.
- The midpoints are \(2.5,10,17.5\). The weighted midpoint total is \(12(2.5)+18(10)+10(17.5)=385\).
- With total frequency 40, the estimated mean is \(\frac{385}{40}=9.625\). The highest frequency class is [5,15), despite not having the tallest density bar.
Quick formula reference
For revision once you understand the methods above. Check the conditions before using a formula.
Weighted mean
\(\bar x=\sum f_ix_i/\sum f_i\). For grouped estimates replace xᵢ with class midpoint.
Return to the explanation →Population spread
\(\sigma^2=\sum f_i(x_i-\bar x)^2/\sum f_i=\sum f_ix_i^2/\sum f_i-\bar x^2\). Sample variance instead divides squared deviations by \(n-1\).
Return to the explanation →IQR and density
\(\mathrm{IQR}=Q_3-Q_1\). Histogram density is frequency divided by class width. A common outlier rule is below \(Q_1-1.5\,\mathrm{IQR}\) or above \(Q_3+1.5\,\mathrm{IQR}\).
Return to the explanation →Calculate quartiles explicitly and state the convention
Median rank is \(\frac{n+1}{2}\); for even \(n\), average ranks \(\frac n2\) and \(\frac n2+1\). Under the stated halves convention, \(Q_1\) is the median of the lower half and \(Q_3\) the median of the upper half.
Return to the explanation →Use outlier fences and compare distributions in context
Lower \(\text{fence}=Q_{1}-1.5(Q_{3}-Q_{1})\); upper \(\text{fence}=Q_{3}+1.5(Q_{3}-Q_{1})\). Outliers satisfy strict exterior inequalities.
Return to the explanation →Cumulative frequency, percentiles and interpolation
Estimated percentile \(x_p=L+w(pN-C)/f\), where p is a decimal proportion, L lower class boundary, w width, C cumulative count before the class and f its frequency.
Return to the explanation →Transform data and choose a resistant measure
\(\bar y=a\bar x+b\), \(\sigma_y=|a|\sigma_x\), \(\operatorname{Var}(Y)=a^2\operatorname{Var}(X)\), range and IQR scale by \(|a|\).
Return to the explanation →Grouped estimates and unequal-width histograms
Frequency density =\(\frac{f}{w}\); frequency =\(\text{density}\times \text{width}\). Grouped mean estimate \(\bar x\approx\sum f_im_i/\sum f_i\), with midpoint mᵢ.
Return to the explanation →Learn to diagnose an error
Spot the mistake
The statement below is incorrect. Identify the missing condition or reasoning before opening the explanation.
The mean of values 1 and 5 with frequencies 9 and 1 is 3.
Explain and repair the mistake
Three ignores frequencies. The weighted mean is \((9\times1+1\times5)/10=1.4\). The denominator counts observations, not different categories.
Connect and apply
Put the ideas together
A more demanding application of this guide’s methods. This is a learning stage; any additional HL content is labelled separately.
One extreme observation changes different summaries
Compare datasets 2, 3, 4, 5, 6 and 2, 3, 4, 5, 36.
- Both medians are 4. The means are \(20/5=4\) and \(50/5=10\).
- The first dataset has population variance \((4+1+0+1+4)/5=2\). The second has squared deviations about 10 summing to 850, so population variance is 170.
- The population standard deviations are \(\sqrt2\) and \(\sqrt{170}\). Specify population versus sample convention when using technology.
- The unchanged median hides the extreme upper tail. A good comparison says the second set has the same middle observation but a much larger upper extreme and overall spread.
Is “the datasets are the same because their medians match” justified?
Check your reasoning
No. A median is one summary value. Matching centres can coexist with very different spread, skewness and extremes.
Common mistakes and how to avoid them
- Order raw data before selecting middle positions.
- Use frequencies as weights.
- A grouped mean is an estimate, not an exact observation mean.
- Check whether your calculator displays population \(\sigma \) or sample s.
Practise independently
Build confidence, then apply it
Try each question before opening its hint or solution. If a method is new, return to the walkthrough, then try again. These learning stages describe the practice sequence; additional HL content is labelled separately.
- 1
Build confidence
Replace 8 by 18. Find the new mean and median.
Need a starting point?
Only the total and extreme value change.
Show the worked solution
- The total becomes 30, so the mean becomes 6.
- The median stays 3, showing its resistance to this extreme change.
- 2
Apply and explain
Values 1 and 4 occur with frequencies 3 and 2. Find the mean.
Need a starting point?
Add all values using their frequencies.
Show the worked solution
- The weighted total is \(1(3)+4(2)=11\).
- There are 5 observations, so the mean is \(11/5=2.2\).
- 3
Check your understanding
Every value increases by 7. What happens to the mean and range?
Show the worked solution
The mean increases by 7; the range is unchanged because both maximum and minimum increase by the same amount.
- 4
Use the method
A class has scores \(4,6,6,8\). Find the mean and population variance.
Show the worked solution
\(\text{Mean}=6\). Squared deviations sum to \(4+0+0+4=8\), so population \(\text{variance}=\frac{8}{4}=2\) and standard \(\text{deviation}=\sqrt{2}\).
- 5
Combine the skills
Calculate quartiles explicitly and state the convention
For \(1,2,3,4,7,9,12\), find \(Q_{1}\) and \(Q_{3}\) under the stated halves convention.
Show the worked solution
The median is 4. Excluding it leaves lower \(1,2,3\) and upper \(7,9,12\), so \(Q_{1}=2\) and \(Q_{3}=9\).
- 6
Combine the skills
Use outlier fences and compare distributions in context
For \(Q_{1}=6\) and \(Q_{3}=10\), is 16 an outlier under the strict 1.5-IQR rule?
Show the worked solution
\(IQR=4\), so the upper fence is 16. A value exactly on that boundary is not an outlier under this rule.
- 7
Combine the skills
Cumulative frequency, percentiles and interpolation
Classes [0,10), [10,20), [\(20,30\)] have frequencies \(5,15,10\). How many observations are known to be below 20?
Show the worked solution
20 observations lie in the first two classes, and both classes exclude 20 at their upper end. No interpolation is required at that boundary.
- 8
Combine the skills
Transform data and choose a resistant measure
If \(Y=-X\) and X has quartiles 4 and 9, what are the quartiles of Y?
Show the worked solution
The order reverses. \(Q_{1}(Y)=-9\) and \(Q_{3}(Y)=-4\); the IQR stays 5.
- 9
Combine the skills
Grouped estimates and unequal-width histograms
A histogram bar has width 8 and height 3.5 in frequency-density units. Find its frequency.
Show the worked solution
Frequency is its area: \(8\times 3.5=28\).
Finished? Use the linked question bank below to practise selecting the method without a guide telling you which rule to use.
Using these methods in exam questions
AA Paper 1
No calculatorPractise the algebra and exact values by hand. Keep fractions, surds and multiples of π exact where required. Show the steps that justify the result.
AA Paper 2
GDC requiredUse graphing, numerical solving or statistical tools when appropriate. Write the setup before giving the output, and keep extra precision until the final answer.
For this topic: Define the variable or events, write the probability statement or hypotheses, then calculate. Name the distribution and its parameters; interpret the result using the original population or context.
Paper 3: build a connected argument
Both AA HL and AI HL Paper 3 contain two extended problem-solving questions. A question develops a theme, so keep useful earlier results, test small cases and explain any proposed general rule. A calculator pattern can suggest a result; your mathematical reasoning must support it.
- Identify what the first part establishes and record the conditions under which it holds.
- When a later part introduces a new definition or model, connect it to methods you already know rather than assuming a new formula must have been memorised.
- Check the conclusion against an earlier numerical case and explain its meaning or limitation.
For the first-assessment-2021 courses. IB assessment reference ↗
Find a specific method or formula
Now practise the method
If you opened this guide from a question, return to that tab and try the method without looking at the example. Your answer stays in the question tab.
Practise this subtopic →Want a broader practice session? Explore IB Maths AA SL practice questions →Explore IB Maths AA HL practice questions →Try free IB Maths exam-style questions and worked solutions →
Core-topic coverage checked against Haese Core Topics SL (2019), chapters 11–12; Haese Core Topics HL (2019), chapters 12–13. The explanations, diagrams and exercises here are original Arc material.
Original Arc Practice teaching notes for Maths AA. Core and HL sections are distinguished above. These notes follow the first-assessment-2021 course and are not an official IB publication or a complete syllabus checklist. IB course reference. Report a correction.