KS Maths
Topic 4.1 · AA and AI, SL and HL

Sampling, bias and outliers

Where the data came from

Sampling, bias and outliers. The part of statistics that decides whether anything after it is worth calculating.

This video lesson is a free sample. The plans open the rest of the lessons in this course, each with a figure to move and questions that check your answer as you type. See the plans.
Words you need (10 key words in this lesson)

The maths words this lesson uses, in plain English. Open this before you start if English is not your first language.

sample
A small group chosen from a bigger group.We asked a sample of 50 students.
outlier
A value far away from the rest of the data.One score of 100 among scores near 20 is an outlier.
bias
Unfair in a way that favours some results.Asking only your friends gives a biased sample.
population
The whole group that we want to know about.The population is all students in the school.
random
Chosen by chance, with no pattern.A random number is picked by chance.
mean
The total of all values divided by how many values there are.The mean of 2, 4, 6 is 4.
quartile
One of three values that cut ordered data into four equal parts.The upper quartile has 75% of the data below it.
fraction
A part of a whole. It is written with a top number and a bottom number.One half is a fraction.
median
The middle value when data is in order.The median of 2, 5, 9 is 5.
interquartile range
The distance between the upper quartile and lower quartile. It shows the spread of the middle half.IQR = upper quartile minus lower quartile.

Warm-up

Four quick ones from earlier work. Try each on paper before you open the answer; a slip here shows you what to watch for later in the lesson.

  1. Simplify 160/480.
    Answer

    160/480 = 1/3, by dividing top and bottom by 160. A group’s share of a population is a fraction, and the fraction is easier to use when it is simple.

  2. Find 2/5 of 60.
    Answer

    60 ÷ 5 = 12, and 2 × 12 = 24. A fraction of a number is found by dividing and then multiplying. The same step shares out a stratified sample.

  3. Find the median of the four values 12, 3, 9 and 7.
    Answer

    Put them in order: 3, 7, 9, 12. With four values the median is halfway between the middle two, (7 + 9) ÷ 2 = 8. Taking 7 or 9 is the slip.

  4. Find 1.5 × 12.
    Answer

    12 + 6 = 18. One and a half times is the number plus half of it. This is the multiplier in the outlier rule.

Words used in this lesson
population
everyone or everything your question is about. For example: all the teachers in one school.
sample
the part of the population you actually collect data from. For example: 20 of those teachers.
bias
a built-in unfairness that pushes results in one direction. For example: asking only the early arrivals.
representative
a fair small copy of the population. For example: a sample with the same mix of ages as the whole group.
random
every member has an equal chance of being chosen. For example: numbers drawn from a hat.
stratified
split into groups, then a random sample from each group in proportion to its size. For example: a larger sample from the larger year group.
quota
a fixed number from each group, chosen however is convenient. For example: ask until you have 10 from each group.
outlier
a value far from the rest, flagged by a rule. For example: a time much longer than all the others.
quartile
a value that cuts ordered data into four equal parts. For example: the upper quartile has three quarters of the data below it.
justify
give a reason that is based on the facts in the question. For example: justify keeping a value by saying it was checked and is genuine.

Predict first. The ninth student’s reading time is moved from 34 minutes up to 95 minutes while the other eight stay fixed. Which will move more, the mean or the median, and by roughly how much? Decide before you move the slider.

Then check

Now drag the slider slowly from the start to the far end, watching both markers and the gap between them. Does either marker stop moving at some point? Where, and why do you think that happens?

Nearly every mark lost on this topic comes from one belief: that a bigger sample is a better sample. It is not. A badly chosen sample of 5000 is worse than a well chosen sample of 50, because it is confidently wrong.

Start with one value out of place

Nine students recorded how long they read for. Eight of them are fixed. Move the ninth, and watch the two markers.

34 min
–mean
–median
–gap between them

Push it out to 95 and back. Nothing is stored and nothing is sent.

The mean uses every value, so one extreme number drags it. The median only cares about position, so with these nine values it stays inside a narrow stretch however far you push the ninth. That is the main reason a median is reported alongside a mean.

Push one value out to 95 and the mean chases it while the median barely moves. That is the whole argument for quoting both.

Population and sample

The population is every member of the group your question is about. If the question is about Year 12 at your school, the population is those students, not everyone in the country. A population does not have to be large. It has to be all of them.

A sample is the part you actually collected from. The moment you take one, everything you say about the population becomes an estimate.

Discrete or continuous

Discrete data can only take separate values, usually counts: the number of siblings, goals scored, books read. There is nothing between 2 and 3 siblings.

Continuous data is measured and can take any value in a range: height, time, mass. A reading of 172 cm is really “somewhere from 171.5 to 172.5”, because the measurement was rounded.

Quick check: which is which?

Sort these before you open the answer: shoe size in whole and half sizes, the time to run 100 m, the number of people in a household, a person’s age in completed years.

Shoe size is discrete: it jumps in halves, with nothing between. Running time is continuous. Household size is discrete, a count. Age is continuous underneath, but “completed years” has been recorded as whole numbers, so the data you hold behaves as discrete. Say which one you mean, and why, in an answer.

Can you trust the source?

Before choosing how to sample, ask about any data you did not collect yourself. Who collected it, and why? Was everyone in the population able to appear in it? How much is missing, and is it missing at random or for a reason? A data source is reliable if it was collected carefully enough that the same process would give similar results again. A website that lets anyone vote any number of times is not, however many votes it shows.

The five techniques

Quota and stratified are not the same. Both fix how many come from each group. Only stratified chooses randomly inside the group. Somebody standing in the playground asking until they have twenty of each is doing quota sampling, and it is biased by who happened to be standing there.

Worked example: a stratified sample

A school has 300 students in Year 11, 200 in Year 12 and 100 in Year 13. A stratified sample of 60 is taken. How many come from Year 12?

total= 300 + 200 + 100 = 600 the whole population first Year 12= 200600 = 13 what fraction of the school it is sample= 13 × 60 = 20 the same fraction of the sample

So 20 students are chosen at random from Year 12. That last phrase is what makes it stratified rather than quota.

Outliers

A value is treated as an outlier if it falls below Q₁ − 1.5 × IQR, or above Q₃ + 1.5 × IQR, where IQR = Q₃ − Q₁.

Worked example: testing a value

For a set of data, Q₁ = 24 and Q₃ = 36. Is a value of 58 an outlier?

IQR= 36 − 24 = 12 always the interquartile range first upper= 36 + 1.5 × 12 one and a half IQRs above Q₃ = 36 + 18 = 54 58 > 54, so it is an outlier by this rule. 52 would have failed and still looked large, so compare rather than eyeball

What the rule does not say. It does not say the value is a mistake, and it does not give you permission to delete it. A correct extreme value is information. Removing an awkward number quietly changes your results and hides that you changed them.

A second example, finished by you

The same method on a new school. The first three steps are written out with the reason for each; the last one is yours. Cover the reasons and see whether you can say them first.

A school has 280 students in Year 10, 320 in Year 11 and 400 in Year 12. A stratified sample of 50 students is taken. How many of them come from Year 10?

  1. Total = 280 + 320 + 400 = 1000You need the whole population before you can say what fraction a group is. Always find this first.
  2. Year 10 is 280/1000 of the school.This is the share of the whole school that Year 10 makes up. Keep it as a fraction until the last step, so no rounding creeps in.
  3. The sample must keep the same share: 280/1000 of 50.Stratified means in proportion. The sample is a small copy of the school, so each year group has the same fraction in the sample as it has in the school.
  4. Work out 280/1000 of 50. Then say how the students in Year 10 would be chosen so that the sample is stratified, not quota.Your step. Write it out in full before you type the answer below.

Your answer. Type the number of Year 10 students in the sample.

Check before you go on

One question that tells you whether the main idea has landed. Each wrong option is a different common slip, so the reply tells you which one you made.

A researcher stands at the school gate and asks students as they arrive until she has 25 boys and 25 girls. Which sampling method is this?

A researcher stands at the school gate and asks students as they arrive until she has 25 boys and 25 girls. Which sampling method is this?

Where it decides something

A timing system records reaction times in milliseconds for a group of sprinters. The lower quartile is 210 and the upper quartile is 250. The system flags a time as unusual if it is below the lower boundary of the outlier rule. A time of 95 is recorded, which is very quick, and the starter wants to know whether it could be a genuine reaction or a false start.

Find the lower boundary below which a time is treated as an outlier. Then decide whether 95 is flagged.

Your turn

1. A school has 450 students in Year 11, 300 in Year 12 and 150 in Year 13. A stratified sample of 60 is taken. How many come from Year 11?

2. For a set of data, Q₁ = 23 and Q₃ = 39. Find the value above which a result is treated as an outlier.

3. A student surveys 500 people outside one Bangkok shopping centre and writes: "Because the sample is large, it is representative of the country." What is the mistake?

4. A student's height is recorded as 17.2 cm. Every other height is between 150 cm and 190 cm. What should happen?

Where the marks go

Stratified sample sizes are nearly free marks, and students lose them by rounding badly. Work with the fraction, not a decimal.

On outliers, the calculation is one mark and the judgement is the other. An answer that says "58 is an outlier so I removed it" scores worse than one that says "58 is an outlier, so I checked it, and it is genuine".

On bias, examiners want the mechanism: who was more likely to be asked and who could not be asked at all. "The sample is too small" earns nothing, and it is the most common answer given.

Something to think about

What if a ninth student’s reading time is added to eight fixed ones: 20, 24, 26, 28, 30, 31, 33 and 36 minutes? What is the lowest and the highest the median of the nine can possibly be, however long the ninth student reads? And can the mean be pushed as high as you like?

One way to think about it

Put the eight values in order, then think about where the ninth could slot in. The median of nine is the fifth value. Which values could end up fifth? Then compare with the mean, which adds the ninth value into a total divided by nine.

Climb to an exam question

Four steps, each one a little harder than the last. Every step is a piece of the exam question at the end, so by the top you have already done each part once.

Step 1 of 4: share out a stratified sample. A town has 1600 adults: 640 in the North district, 560 in the Central district and 400 in the South district. A stratified sample of 55 adults is taken. How many of the sample come from the North district?

Step 2 of 4: find the outlier boundary. In the sample, the weekly travel times, in minutes, have lower quartile 15 and upper quartile 27. A time is an outlier if it is more than 1.5 times the interquartile range above the upper quartile. Find the upper boundary.

Step 3 of 4: spot the source of bias. A club posts a survey question on its web page and uses the first 50 answers it receives. A member says: “Everyone in the club could see the question, so the sample is not biased.” Why is this reasoning wrong?

A club posts a survey question on its web page and uses the first 50 answers it receives. A member says: β€œEveryone in the club could see the question, so the sample is not biased.” Why is this reasoning wrong?

Step 4 of 4: decide what to do with a flagged value. A recorded time of 51 minutes is above the boundary you found. A group member says: “Delete it, it is an outlier.” What is the best response?

A recorded time of 51 minutes is above the boundary you found. A group member says: β€œDelete it, it is an outlier.” What is the best response?

The exam question

Written for this site in the style of the real papers. Do it on paper first, as you would in the exam, and show your working: most of the marks are for method. Give answers to 3 significant figures unless the question says otherwise. Then check each part below.

Paper 2 style · calculator (GDC) allowed · 8 marks · about 9 minutes

A sports club has 600 members: 300 juniors, 180 intermediates and 120 seniors. The club wants to survey 50 of its members about training times.

(a) A stratified sample of 50 members is taken. Find the number of seniors in the sample. [2]

(b) Instead, the club secretary proposes to ask the first 50 members who arrive at Saturday’s session. Explain why this sample may be biased. [2]

(c) In the survey, the weekly training times, in hours, have lower quartile 4 and upper quartile 10. A time is an outlier if it is more than 1.5 times the interquartile range above the upper quartile. Find the upper boundary for outliers. [2]

(d) One member records a training time of 21 hours a week. Hence state whether this time is an outlier, giving a reason, and comment on whether the club should remove it from the data. [2]

Check (a). Type the number of seniors in the sample.

Check your working for (b)

Two separate reasons, each linked to this plan: one about which members could be chosen, and one about how the members who are chosen might differ from the rest of the club.

Check (c). Type the upper boundary, in hours.

Check your working for (d)

A clear statement, with the comparison between this time and the boundary from part (c) that supports it. Then a comment on what the club should do with the value, with a reason that refers to this member.

Want the rest of this topic?

This is a free sample lesson. The IB Diploma plan opens every other Diploma lesson, AA and AI, SL and HL, and every lesson from Year 7 for the refreshers. It covers every child in the family and includes all seven revision packs.

$99 for 12 months, or $149 for 2 years

One plan opens every Diploma lesson, AA and AI, SL and HL, for the whole family.

That is $8.25 a month for the whole family.

Student without a card? in one tap.

One payment. Nothing renews. Full refund within 30 days. Prices are in US$; Gumroad shows your local currency at checkout. Already paid? Type the email you paid with in the sign-in box, then click the link we send. See every price, including $19 revision packs.

Teaching this lesson?

Every lesson here has a teacher page beside it: worked answers, what each common wrong answer tells you about a student's thinking, and questions at three levels for the board. Every unit has a free sample lesson for students, and a plan opens every other lesson.

See the teacher pages