Types of Data
What data are, raw and organised data, and how to classify data as categorical or numerical, and numerical data as discrete or continuous.
Before you start
- In Primary school you read and completed tables, pictograms, bar graphs and line graphs. Each of them shows data that someone had already collected and organised.
- This lesson looks at the data themselves: what raw and organised data are, and what kind of data a set of data is. The kind of data decides how they can be organised and which statistical diagram suits them.
Data, Raw Data and Organised Data
Statistics is the part of mathematics that deals with data. Working with data has four stages: we collect the data, organise them (sort them or set them out in a table), represent them in a statistical diagram such as a bar graph, and interpret them (read them to answer a question or to draw a conclusion).
Data are collected to answer a question: the heights of the students in a class, the CCA each student is in, the rainfall in each month, the number of goals in each match of a season.
Data as they come in, in the order they were collected, are hard to read when there are many of them: it is not easy to see which value is the most common, or how many values are large. Sorted, counted and set out in a table, the same data can be read at a glance.
Data
Data are facts or information, such as numbers, measurements or answers, collected to answer a question.
Raw data are data as they were first collected, before they have been organised. Data are raw whatever way they were collected: by asking people, by watching, by measuring or by looking them up.
Organised data are data that have been sorted, counted or grouped and set out, usually in a table, so that they are easy to read.
Example 1: From raw data to organised data
Mrs Goh asked the 20 students of a club how many hours they spent on homework last week. Their answers, in hours, in the order she wrote them down, were:
5, 8, 6, 10, 7, 5, 9, 8, 6, 7, 8, 5, 9, 10, 6, 7, 8, 6, 9, 7
(a) Are these raw data or organised data? Explain.
(b) Organise the data in a table.
(c) How many students spent 8 hours or more on homework?
Solution
(a) The numbers are in the order Mrs Goh collected them. They have not been sorted or counted, so they are raw data.
(b) The answers go from 5 hours to 10 hours. Go through the list once for each number of hours and count the students who gave it: 5 hours appears 3 times, 6 hours 4 times, 7 hours 4 times, 8 hours 4 times, 9 hours 3 times and 10 hours 2 times.
| Hours | 5 | 6 | 7 | 8 | 9 | 10 | Total |
|---|---|---|---|---|---|---|---|
| Number of students | 3 | 4 | 4 | 4 | 3 | 2 | 20 |
Check: , the number of students asked, so no answer was missed or counted twice.
(c) "8 hours or more" means 8, 9 or 10 hours. From the table, .
(a) Raw data. (b) The table above. (c) 9 students spent 8 hours or more on homework last week.
Once the data are organised in a table, they can be represented in a statistical diagram. The bar graph below shows the same 20 answers. We can now interpret them: 12 of the 20 students spent 6, 7 or 8 hours on homework, and only 2 spent as many as 10 hours. (The lesson Tally and Frequency Tables shows a quicker way to count raw data, with tally marks.)
Categorical and Numerical Data
Some data sort things into groups by a name: a favourite colour, a way of travelling to school, a CCA, the stall a meal was bought from. They are words, not amounts.
Other data are amounts, found by counting or measuring: the number of siblings, a height, a mass, the time taken to run 2.4 km. With amounts it makes sense to compare their sizes, add them or find the difference between two of them.
Categorical and numerical data
Categorical data put each item into a group, or category, described by a name or a label (for example: blue, MRT, badminton).
Numerical data are numbers obtained by counting or measuring (for example: 3 siblings, 152 cm, 41.5 kg).
Numbers that are only labels
Some data are written with numbers but are labels: a bus service number (bus 190), a class (1A), the number on a sports jersey, a postal code. Adding them or finding their difference makes no sense: bus 190 is not "twice" bus 95. Such data are categorical.
Categories may also have an order, such as T-shirt sizes S, M, L and XL. They are still categorical data: they are labels, not amounts.
Ask: is the number an amount that was counted or measured? If not, the data are categorical.
Example 2: Categorical or numerical?
State whether each set of data is categorical or numerical. Give a reason.
(a) The favourite ice-cream flavours of 30 students.
(b) The heights of the students in a class.
(c) The bus service each student takes to school.
(d) The number of goals a school football team scored in each match.
(e) The temperature at noon in Singapore on each day of a month.
Solution
(a) A flavour is a name (chocolate, mango, durian), not an amount: categorical.
(b) A height is measured, for example 158 cm: numerical.
(c) A bus service number such as 190 is a label for a route, not an amount; adding two bus service numbers means nothing: categorical.
(d) Goals are counted: numerical.
(e) A temperature is measured, for example 31.5°C: numerical.
Categorical: (a) and (c). Numerical: (b), (d) and (e).
Discrete and Continuous Data
Numerical data are of two kinds, according to how they are obtained.
Counted data can take only certain separate values, and a count is always a whole number: a family has 2 or 3 children, never 2.4, and there is no possible value between 2 and 3.
Measured data can take any value within a range: a height can be 152 cm, 152.4 cm or 152.43 cm, as exact as the measuring instrument allows. A measurement is rounded when it is written down, so a height written as 152 cm is still measured data, even though it looks like a whole number.
Discrete and continuous data
Discrete data are numerical data that can take only certain separate values. Most are obtained by counting (the number of students, of books borrowed, of goals scored), and a count is always a whole number. Amounts of money are discrete too: they go up in steps of 1 cent.
Continuous data are numerical data that can take any value within a range. They are obtained by measuring: length, height, mass, time, temperature.
Ask: was it counted or measured? Counting gives discrete data; measuring gives continuous data. Amounts of money are discrete although they are not counted, because they go up in steps of 1 cent.
Discrete data need not be whole numbers
Prices go up in steps of 1 cent ($3.50, $3.51, …). A price can take only certain separate values, with nothing in between, so amounts of money are discrete data.
| Type of data | How it is obtained | Examples |
|---|---|---|
| Categorical | Sorting into groups by a name or a label | favourite colour, CCA, bus service number, T-shirt size |
| Numerical, discrete | Counting (a count is always a whole number), or amounts of money (in steps of 1 cent): only certain separate values | number of siblings, goals in a match, books borrowed, number of pages, price, amount spent |
| Numerical, continuous | Measuring (any value within a range) | height, mass, time taken, temperature, rainfall |
Example 3: Classifying data
Classify each set of data as categorical, discrete numerical or continuous numerical. Give a reason.
(a) The number of CCAs each student in a class takes part in.
(b) The time each student takes to run 2.4 km.
(c) The hawker food each person in a queue orders.
(d) The mass of each student's school bag.
(e) The number of library books each student borrowed last term.
(f) The price of each drink sold at the canteen.
Solution
(a) CCAs are counted (0, 1, 2, …): discrete.
(b) Time is measured, for example 13 minutes 42.6 seconds: continuous.
(c) A food is a name (chicken rice, laksa): categorical.
(d) Mass is measured, for example 5.3 kg: continuous.
(e) Books are counted: discrete.
(f) Prices go up in steps of 1 cent, with nothing in between: discrete.
Categorical: (c). Discrete numerical: (a), (e) and (f). Continuous numerical: (b) and (d).
Common Mistakes
- Thinking that every number is numerical data. A bus service number, a class such as 1A or a jersey number is a label, so these are categorical data.
- Thinking that ordered labels are numerical. T-shirt sizes S, M, L and XL are in order, but they are labels, not amounts: categorical data.
- Calling a measurement discrete because it is written as a whole number. A height of 152 cm or a time of 14 minutes was measured and then rounded: continuous data.
- Thinking that discrete data must be whole numbers. Amounts of money ($3.50) are discrete: they go up in steps of 1 cent.
- Thinking that raw data come only from asking people. Data collected in any way are raw until they are organised.
- Organising raw data without checking the total: the counts in the table must add up to the number of values in the list.
Practice
Try each question before you open its solution. The questions get harder as you go.
Practice 1: Raw or organised?
State whether each set of data is raw or organised. Explain.
(a) Siti wrote down the mass of each durian, in kg, as she weighed it: 1.8, 2.3, 1.5, 2.0, 2.6, 1.9.
(b) The number of Secondary 1 students in each of four CCAs:
| CCA | Badminton | Choir | Robotics | Scouts |
|---|---|---|---|---|
| Number of students | 24 | 18 | 15 | 21 |
ShowHide solution
(a) The masses are in the order Siti weighed them, not sorted or counted: raw data.
(b) The students have been counted for each CCA and the counts set out in a table: organised data.
(a) Raw data. (b) Organised data.
Practice 2: Categorical or numerical?
State whether each set of data is categorical or numerical.
(a) The colours of the cars in a car park.
(b) The number of passengers on each bus arriving at a bus interchange.
(c) The number on each runner's vest at Sports Day.
(d) The mass of each baby born in a hospital in one week.
(e) The postal codes of the students' homes.
(f) The T-shirt sizes (S, M, L, XL) ordered for Sports Day.
ShowHide solution
(a) A colour is a name: categorical.
(b) Passengers are counted: numerical.
(c) A vest number only names the runner; it is not an amount: categorical.
(d) Mass is measured: numerical.
(e) A postal code is a label for a place, not an amount: categorical.
(f) Sizes are labels, even though they are in order: categorical.
Categorical: (a), (c), (e) and (f). Numerical: (b) and (d).
Practice 3: Discrete or continuous?
State whether each set of numerical data is discrete or continuous.
(a) The number of students absent from a class on each day of a term.
(b) The time each student takes to travel to school.
(c) The length of each fish caught at a fish farm.
(d) The number of storeys of each block of flats in a town.
(e) The price of a bowl of fishball noodles at each stall of a hawker centre.
(f) The rainfall in Singapore on each day of December.
ShowHide solution
(a) Students are counted: discrete.
(b) Time is measured: continuous.
(c) Length is measured: continuous.
(d) Storeys are counted: discrete.
(e) A price goes up in steps of 1 cent ($4.50, $4.51, …), with nothing in between: discrete.
(f) Rainfall is measured (in millimetres): continuous.
Discrete: (a), (d) and (e). Continuous: (b), (c) and (f).
Practice 4: The types of data on a form
Mei Ling's class filled in a form with these six questions. For each question, state whether the answers are categorical, discrete numerical or continuous numerical data.
1. Which class are you in? (for example, 1A)
2. How many brothers and sisters do you have?
3. What is your height, to the nearest centimetre?
4. What is your favourite subject?
5. How long, in minutes, does your journey to school take?
6. How many pieces of homework did you hand in last week?
ShowHide solution
1. A class is a label, not an amount: categorical.
2. Brothers and sisters are counted: discrete numerical.
3. Height is measured; giving it to the nearest centimetre only rounds it: continuous numerical.
4. A subject is a name: categorical.
5. Time is measured: continuous numerical.
6. Pieces of homework are counted: discrete numerical.
Categorical: 1 and 4. Discrete numerical: 2 and 6. Continuous numerical: 3 and 5.
Practice 5: Three types of data from one race
At Sports Day, the teachers in charge of the 100 m race record these data. Classify each as categorical, discrete numerical or continuous numerical.
(a) The house (Red, Blue, Green or Yellow) of each runner.
(b) The number of runners in each heat.
(c) The time each runner takes, in seconds.
(d) The number of races each runner has entered that day.
ShowHide solution
(a) A house is a name: categorical.
(b) Runners are counted: discrete numerical.
(c) Time is measured, for example 14.37 seconds: continuous numerical.
(d) Races are counted: discrete numerical.
Categorical: (a). Discrete numerical: (b) and (d). Continuous numerical: (c).
Practice 6: True or false?
Say whether each statement is true or false. Give a reason.
(a) The block numbers of the students' homes (for example, Block 512) are numerical data.
(b) The times taken to swim 50 m at the school swimming carnival, recorded to the nearest second, are discrete data.
(c) The amount of pocket money each student gets in a week is discrete data.
(d) Ali stood at the school gate and wrote down how each student arrived (walk, bus, car, …) in the order they came. He asked no one, so his list is not raw data.
(e) The number of people in the queue at a chicken rice stall, counted every 10 minutes, is discrete data.
ShowHide solution
(a) False. A block number names a block of flats; it is a label for a place, not an amount, so the data are categorical.
(b) False. A time is measured. Recording it to the nearest second only rounds it (38 s may really be 38.27 s), so the data are continuous.
(c) True. An amount of money goes up in steps of 1 cent ($5.00, $5.01, …), with nothing in between, so it is discrete, even though it is not a whole number of dollars.
(d) False. Ali collected his data by watching. Data collected in any way are raw until they are organised, and his list is in the order the students came, not sorted or counted: raw data.
(e) True. People are counted, and a count is always a whole number: discrete.
(a) False. (b) False. (c) True. (d) False. (e) True.
Practice 7: Give your own examples
Mrs Goh's class is collecting data about how the students travel to school. Give one example of data the class could collect that is:
(a) categorical; (b) discrete numerical; (c) continuous numerical; (d) written with numbers but categorical.
ShowHide solution
Many answers are possible. For example:
(a) The way each student travels (walk, bus, MRT, car): each answer is a name, so the data are categorical.
(b) The number of buses or trains each student takes: these are counted, so the data are discrete.
(c) The time each journey takes, or the distance from home to school: these are measured, so the data are continuous.
(d) The bus service number each student takes: it is a label for a route, not an amount, so the data are categorical.
For example: (a) the way of travelling; (b) the number of buses or trains taken; (c) the time the journey takes; (d) the bus service number.
Practice 8: Organising raw data
Ravi asked 16 classmates for their favourite fruit and wrote down their answers in order:
durian, mango, durian, banana, watermelon, durian, mango, banana, durian, watermelon, mango, durian, banana, durian, mango, watermelon
(a) Are these data categorical or numerical?
(b) Organise the data in a table.
(c) Which fruit is the most common favourite? What fraction of the classmates chose it?
ShowHide solution
(a) Each answer is the name of a fruit: categorical data.
(b) Count each fruit through the list: durian appears 6 times (the 1st, 3rd, 6th, 9th, 12th and 14th answers), mango 4 times, banana 3 times and watermelon 3 times.
| Fruit | Durian | Mango | Banana | Watermelon | Total |
|---|---|---|---|---|---|
| Number of classmates | 6 | 4 | 3 | 3 | 16 |
Check: , the number of classmates asked.
(c) Durian has the largest count, 6. Fraction .
(a) Categorical. (b) The table above. (c) Durian, chosen by of the classmates.
Practice 9: Bean plants
For a science project, Ravi measured the height of each of 10 bean plants after two weeks, to the nearest centimetre. His results, in cm, were:
12, 14, 13, 12, 15, 14, 12, 13, 14, 12
(a) Ravi says, "All the heights are whole numbers, so the data are discrete." Explain why he is wrong.
(b) Organise the data in a table.
(c) How many plants were 14 cm tall or taller?
ShowHide solution
(a) The heights were measured, and a height can take any value within a range, such as 12.6 cm. They are whole numbers only because Ravi rounded them to the nearest centimetre. The data are continuous.
(b) The heights go from 12 cm to 15 cm: 12 cm appears 4 times (the 1st, 4th, 7th and 10th), 13 cm 2 times, 14 cm 3 times and 15 cm once.
| Height (cm) | 12 | 13 | 14 | 15 | Total |
|---|---|---|---|---|---|
| Number of plants | 4 | 2 | 3 | 1 | 10 |
Check: , the number of plants.
(c) 14 cm or taller means 14 cm or 15 cm: .
(a) The heights were measured and only rounded to whole numbers, so they are continuous. (b) The table above. (c) 4 plants were 14 cm tall or taller.
Practice 10: Spending at the canteen
Siti recorded the amount each of 12 classmates spent at the canteen at recess:
$2.50, $3.00, $2.00, $3.00, $2.50, $3.50, $2.50, $3.00, $2.00, $2.50, $3.00, $2.50
(a) Siti says, "The amounts have decimals, so the data are continuous." Is she right? Explain.
(b) Organise the data in a table.
(c) What fraction of the 12 classmates spent $3.00 or more?
ShowHide solution
(a) No. Amounts of money go up in steps of 1 cent, with nothing in between: an amount can be $2.50 or $2.51, but nothing between them. So the data are discrete, even though they are written with decimals.
(b) Count each amount through the list: $2.00 appears 2 times (the 3rd and 9th), $2.50 5 times (the 1st, 5th, 7th, 10th and 12th), $3.00 4 times (the 2nd, 4th, 8th and 11th) and $3.50 once (the 6th).
| Amount spent | $2.00 | $2.50 | $3.00 | $3.50 | Total |
|---|---|---|---|---|---|
| Number of classmates | 2 | 5 | 4 | 1 | 12 |
Check: , the number of classmates.
(c) $3.00 or more means $3.00 or $3.50: classmates. Fraction .
(a) No: amounts of money are discrete. (b) The table above. (c) of the classmates spent $3.00 or more.
Key Points
- Working with data has four stages: collect, organise, represent and interpret.
- Data are facts or information collected to answer a question. Raw data are data as first collected; organised data have been sorted or counted and set out, usually in a table.
- When organising raw data, check that the counts add up to the number of values.
- Categorical data are names or labels that sort things into groups; numerical data are numbers obtained by counting or measuring.
- A number used as a label (a bus service, a class, a jersey number, a postal code) gives categorical data; so do labels in order, such as T-shirt sizes.
- Discrete data take only certain separate values: counts (always whole numbers) and amounts of money (in steps of 1 cent). Continuous data are measured and can take any value within a range.
- A measurement written as a whole number is still continuous; amounts of money are discrete.