Back to homeMathematics · Grade 8 · Change subject
Start for free
Math 8 · Mathematics
Statistics · Statistics

Variables, Populations, and Samples

Before you start, make sure you know: Concepts (Math 7)

What is the most popular music artist at your school? How many hours a day do 8th graders spend on their phones? You don't have to ask everyone, but you do have to ask in a smart way. Statistics starts with two decisions: who you ask and what you measure.

Population, Sample, and Individual

A population of 600 students drawn as dots, with a few dots highlighted to show the sample chosen from it. population: 600 students ● sample chosen at random from all grades

Why not study the whole population every time? It can be too expensive, too slow, or impossible. To find out how long phone chargers last, you would have to wear out every one of them, and then there would be none left to sell. When you do study the entire population, it is called a census.

Practice★☆☆Not started
A group of researchers wants to know the favorite video game of American teenagers aged between 12 and 16. To do this, they survey 500 students from several middle and…

A group of researchers wants to know the favorite video game of American teenagers aged between 12 and 16. To do this, they survey 500 students from several middle and high schools in Chicago. State:

  1. a) The population under study.
  2. b) The chosen sample.
  3. c) The individual.
Population Sample Individual
Solve
Practice★★☆Not started
A team of researchers wants to carry out a study on the consumption of energy drinks among teenagers in a city of $50\,000$ inhabitants. To do this, they select $250$…

A team of researchers wants to carry out a study on the consumption of energy drinks among teenagers in a city of $50\,000$ inhabitants. To do this, they select $250$ students aged between $12$ and $18$ years from different middle and high schools and ask them how many cans they have consumed in the last week.

Identify the following elements of the statistical study:

  1. a) The population under study.
  2. b) The chosen sample.
  3. c) The individual.
  4. d) The sample size.
  5. e) The statistical variable and its type.
Solve

Qualitative and Quantitative Variables

A statistical variable is the characteristic we record for each individual. There are two big families.

Tree diagram sorting variables into qualitative and quantitative, and quantitative into discrete (counted) and continuous (measured). Variable Qualitativecategories (words) Quantitativenumbers Discretecounted Continuousmeasured color, sport,favorite app…
Type Values Examples
Qualitative (categorical) Categories or labels, not true amounts Favorite sport, eye color, social media app
Quantitative, discrete Numbers you count (separate, isolated values) Siblings, pets, goals scored
Quantitative, continuous Numbers you measure (any value in an interval) Height, weight, time, temperature
Practice★☆☆Not started
Classify the following statistical variables as qualitative or quantitative: a) The favorite color of a cell phone case. b) The number of followers on a TikTok account.…

Classify the following statistical variables as qualitative or quantitative:

  1. a) The favorite color of a cell phone case.
  2. b) The number of followers on a TikTok account.
  3. c) The time, in minutes, it takes you to get from your house to school.
  4. d) The brand of sneakers preferred by the students in your class.
Solve
Practice★☆☆Not started
Within quantitative variables, we must distinguish between discrete and continuous. State the type of each of the following: a) The number of cousins each student has.…

Within quantitative variables, we must distinguish between discrete and continuous. State the type of each of the following:

  1. a) The number of cousins each student has.
  2. b) The capacity, in gallons, of the water bottles sold in the cafeteria.
  3. c) The number of WhatsApp messages you receive throughout a day.
  4. d) The weight of the backpacks of 8th grade students.
Solve
Practice★☆☆Not started
Match each of the following situations with the nature of its statistical variable (Qualitative, Discrete Quantitative or Continuous Quantitative): 1. The sports played…

Match each of the following situations with the nature of its statistical variable (Qualitative, Discrete Quantitative or Continuous Quantitative):

  1. The sports played at the community sports center.

  2. The maximum daily temperature recorded in your city during the month of July.

  3. The number of television channels tuned in a household.

QUALITATIVE Categories 1 2 3 DISCRETE Isolated values 36.6 36 37 CONTINUOUS Any value
Solve

Nominal and Ordinal Variables

Qualitative variables come in two flavors.

Nominal categories (Pop, Rock, Trap) with no order, next to ordinal categories (S, M, L, XL) arranged in increasing order. Nominal: no order Pop Rock Trap Which is “first”? None. Ordinal: has an order S M L XL small → large
Practice★☆☆Not started
For each of the following survey questions, identify whether the answer would result in a nominal qualitative, discrete quantitative or continuous quantitative variable:…

For each of the following survey questions, identify whether the answer would result in a nominal qualitative, discrete quantitative or continuous quantitative variable:

  1. a) "Which social media app do you use most frequently?"
  2. b) "How many hours a day (with decimals) do you spend studying?"
  3. c) "How many times have you been to the movie theater in the last month?"
  4. d) "What is your preferred operating system (Android or iOS)?"
Solve
Practice★☆☆Not started
Look at the following table of data collected on the reading habits of a group of students and classify each column according to the type of statistical variable it…

Look at the following table of data collected on the reading habits of a group of students and classify each column according to the type of statistical variable it represents:

Student name Books read per year Favorite genre Average reading time (h)
Lucía $12$ Fantasy $0,5$
Marcos $4$ Science Fiction $1,2$
Elena $0$ Does not read $0$
  1. a) Books read per year.
  2. b) Favorite genre.
  3. c) Average daily reading time.
Solve
Practice★★☆Not started
The following table presents several variables collected in a survey carried out in an esports club. Classify each of them into qualitative, discrete quantitative or…

The following table presents several variables collected in a survey carried out in an esports club. Classify each of them into qualitative, discrete quantitative or continuous quantitative:

Variable Type of Variable
Favorite video game
Weekly training hours
Number of peripherals (keyboard, mouse...) owned
Brand of monitor used
Internet connection speed (Mbps)
Position in the world ranking
PRO-PLAYER PROFILE ID: ESP-9938 Favorite video game Valorant Weekly hours 34.5 h No. of peripherals 5 Monitor brand Zowie Connection speed 600.2 Mbps Ranking position 14
Solve

Tricky Cases: Rounding, Ratings, and Money

Some variables look discrete because of how we write them. Always think about the quantity itself, not the display.

Top: a number line with isolated dots at 0 through 5 for a discrete variable. Bottom: a number line with a solid segment for a continuous variable. Discrete: number of pets (only whole numbers) 012345 Continuous: height (every value in between is possible) 4 ft6 ft
  • Measurements rounded by a device are still continuous. A sensor that shows $2.00$ in., $2.01$ in., $2.02$ in. is rounding. The true thickness of a steel sheet could be $2.0137\ldots$ in., and a better instrument would show more digits. The thing being measured is continuous.

  • Ratings with fixed steps are discrete. A movie rating from 1 to 5 stars in half-star steps can only be $1, 1.5, 2, \dots, 5$. That is only 9 possible values. But the mean rating of many users can be $3.7284\ldots$, and that is usually treated as continuous. Always say what you are classifying.

  • Money is counted in cents, so strictly it moves in steps of $\$0.01$. With so many tiny steps, "money spent" is usually treated as continuous. If the question only allows whole dollars, you can say discrete.

  • Age is continuous, because time passes without jumps, even though people say "13 years old".

Practice★★☆Not started
A study is carried out on air quality in different locations of a state. To do this, measuring stations are installed to record the concentration of particles $PM_{10}$…

A study is carried out on air quality in different locations of a state. To do this, measuring stations are installed to record the concentration of particles $PM_{10}$ (in $\mu g/m^3$).

State whether the following statements are true or false, justifying each answer:

  1. a) The variable "particle concentration" is qualitative because it indicates air quality.
  2. b) If we measure the concentration at $15$ randomly chosen points, the individual is each of those measuring points.
  3. c) The number of inhabitants in the areas where it is measured is a continuous quantitative variable.
  4. d) The variable "pollution level" with values (Low, Medium, High) is an ordinal qualitative variable.
Solve
Practice★★★Not started
Often, continuous quantitative variables are presented as discrete due to the precision of the measuring instruments. A precision sensor measures the thickness of steel…

Often, continuous quantitative variables are presented as discrete due to the precision of the measuring instruments. A precision sensor measures the thickness of steel sheets produced in a factory. The sensor shows values such as $2,00$ in., $2,01$ in., $2,02$ in....

  1. a) Although the sensor only shows two decimal places, why is the thickness considered a continuous quantitative variable and not discrete?
  2. b) If the factory produces 10,000 sheets a day and quality control decides to measure only those sheets manufactured between 12:00 and 12:15, will the sample be representative of the total daily production? Justify your answer by mentioning possible factors that could vary throughout the day.
Solve
Practice★★★Not started
A streaming* platform analyzes its subscribers' data to improve its recommendations. Classify the following variables used by its algorithm: a) Total time (in seconds) a…

A streaming platform analyzes its subscribers' data to improve its recommendations. Classify the following variables used by its algorithm:

  1. a) Total time (in seconds) a user spends watching a video before closing it.
  2. b) Type of device used (Smart TV, Smartphone, Tablet, PC).
  3. c) Number of times a user has shared a platform link in the last month.
  4. d) Mean rating of the movies watched (from 1 to 5 stars, allowing half stars such as 3.5).
  5. e) Position a series occupies in the "Top 10" most watched in the country.

Discuss whether variable (d) could be considered continuous or discrete depending on how the original data is collected (individual votes vs. calculated mean).

Solve

Grouping Data into Intervals and Categories

When a continuous variable has many different values, we often group them into intervals. Intervals are written like $[15, 20)$: the bracket means $15$ is included, and the parenthesis means $20$ is not included. That way each value lands in exactly one interval.

A number line from 10 to 30 inches with the interval from 15 up to but not including 20 highlighted, and its midpoint 17.5 marked. 1015202530 midpoint 17.5 height (inches)

The midpoint is a good stand-in because, if the data in an interval are spread fairly evenly, the values above the midpoint balance the values below it.

Grouping can also change the type of the variable. If you turn measured numbers into labeled categories, you get a qualitative variable and you lose the exact values.

Practice★★☆Not started
A biologist is measuring the growth of a fern species in a greenhouse. After a month, they note down the heights (in inches) of $20$ specimens. The data obtained is a…

A biologist is measuring the growth of a fern species in a greenhouse. After a month, they note down the heights (in inches) of $20$ specimens. The data obtained is a continuous quantitative variable.

  1. a) Explain the difference between a discrete and a continuous quantitative variable using this example.
  2. b) If the data is grouped into intervals such as $[10, 15), [15, 20), [20, 25)$... what would be the midpoint of the second interval?
  3. c) What value does the midpoint represent in statistical calculations?
fᵢ Midpoint 2 4 6 8 Frequency (fᵢ) [ ) 10 15 20 25 Height [in.] xᵢ = 17.5 Class mark Calculation of xᵢ xᵢ=(15+20)/2
Solve
Practice★★★Not started
In a biology laboratory, the growth of a bacteria colony is studied. The researcher decides to record the temperature of the culture every hour. The temperature can take…

In a biology laboratory, the growth of a bacteria colony is studied. The researcher decides to record the temperature of the culture every hour. The temperature can take values such as $36,42 ^\circ C$, $36,45 ^\circ C$, etc. However, to simplify the final report, the researcher groups the results into three categories: "Cold" (less than $30 ^\circ C$), "Optimal" (between $30 ^\circ C$ and $40 ^\circ C$) and "Excess heat" (more than $40 ^\circ C$).

  1. a) What type of variable is the originally measured temperature?
  2. b) What type of variable is the one that finally appears in the report after grouping the data?
  3. c) Has information been lost in this process? Explain what advantage and disadvantage this transformation has from a statistical point of view.
Solve
Practice★★★Not started
A study is carried out on the hearing health of young people. The volume intensity at which they listen to music with headphones is measured (in decibels, dB). 1.…

A study is carried out on the hearing health of young people. The volume intensity at which they listen to music with headphones is measured (in decibels, dB).

  1. Classify the variable "Sound intensity in dB".

  2. If the values obtained range between $65,4$ dB and $105,9$ dB, explain why it would not make sense to treat this variable as a nominal qualitative variable.

  3. The medical team decides that if the intensity exceeds $85$ dB, the risk is "High", and if it is lower, the risk is "Low". Classify this new variable "Hearing risk".

QUALITATIVE VARIABLE (ORDINAL) Low Risk < 85 dB High Risk > 85 dB 85 dB 65,4 105,9 Measured continuous values 60 70 80 90 100 110 Intensity (dB) CONTINUOUS QUANTITATIVE VARIABLE
Solve

Biased and Representative Samples

A sample is representative when it has the same mix as the population, so what you find in the sample is probably true for the whole population. A sample is biased when it leaves out or favors some part of the population.

A population of 20 dots with 4 cyclists highlighted, and a biased sample made up only of cyclists. City: 4 of 20 people cycle Survey at a bike shop every person is a cyclist → biased

Common sources of bias:

  • Convenience sample: you ask whoever is easiest to reach (the first 25 students who walk in, or the people at one place and time).

  • Voluntary response: only people who choose to answer, such as an online poll. They tend to have strong opinions.

  • Leaving groups out: surveying only one location, one age group, or one time of day.

The fix is random selection: every individual has the same chance of being chosen. A simple random sample could be drawn by picking student ID numbers out of a hat or with a random number generator.

Practice★☆☆Not started
Imagine you want to carry out a study on the amount of money young people in your neighborhood spend weekly on leisure. a) What type of variable is "money spent"? b) If…

Imagine you want to carry out a study on the amount of money young people in your neighborhood spend weekly on leisure.

  1. a) What type of variable is "money spent"?
  2. b) If $1.200$ young people live in the neighborhood and you ask $60$, what is the sample size?
  3. c) Would it be representative if you only ask the young people at the door of a movie theater on a Saturday afternoon? Justify your answer.
Solve
Practice★☆☆Not started
A study on fruit consumption in a school is to be carried out. Determine whether the following samples are random (chosen at random and representative) or biased: a)…

A study on fruit consumption in a school is to be carried out. Determine whether the following samples are random (chosen at random and representative) or biased:

  1. a) Asking the first 25 students who arrive at school in the morning.
  2. b) Choosing 5 students at random from the roster of each class in the school.
  3. c) Asking only the students who are buying food in the cafeteria.
  4. d) Drawing 50 student ID numbers among all the students in the school and asking their owners.
Solve
Practice★★☆Not started
To find out the citizens' opinion on the construction of a new bike lane downtown, a local newspaper conducts a survey at the entrance of a shop specializing in mountain…

To find out the citizens' opinion on the construction of a new bike lane downtown, a local newspaper conducts a survey at the entrance of a shop specializing in mountain biking.

  1. a) Do you think the chosen sample is representative of the city's population? Justify your answer.
  2. b) Is there any kind of bias in this choice? Explain why.
  3. c) Propose a sampling method that is more appropriate so that the results are reliable.
Solve

Stratified Sampling and Estimating

A simple random sample can still, by bad luck, include very few 6th graders or too many 8th graders. In a stratified random sample you:

  1. Split the population into groups called strata that matter for the study (grade levels, age groups, neighborhoods).

  2. Take a random sample from each stratum.

  3. Make each stratum's share of the sample match its share of the population:

$$\text{students from a stratum} = \frac{\text{stratum size}}{\text{population size}} \times \text{sample size}$$

We can also use a representative sample to estimate something about the whole population. Find the fraction in the sample, then apply it to the population size.

Practice★★☆Not started
In a school there are $600$ enrolled students. We want to extract a representative sample of $60$ students using stratified sampling by grade levels to carry out a study…

In a school there are $600$ enrolled students. We want to extract a representative sample of $60$ students using stratified sampling by grade levels to carry out a study on reading habits. The distribution by grade levels is as follows:

  • Grade $1º$: $180$ students.

  • Grade $2º$: $160$ students.

  • Grade $3º$: $140$ students.

  • Grade $4º$: $120$ students.

Calculate how many students from each grade level should be chosen so that the sample maintains the proportionality of the population.

Solve
Practice★★☆Not started
A local council wants to know the number of pets in the households of a newly built neighborhood where $1\,200$ families live. To avoid asking everyone, they decide to…

A local council wants to know the number of pets in the households of a newly built neighborhood where $1\,200$ families live. To avoid asking everyone, they decide to send a survey to the $120$ families living at the first addresses on the alphabetical list of streets.

  1. a) State the population and the sample.
  2. b) Is this a simple random sampling method? Why?
  3. c) Identify the variable and state its type.
  4. d) If $15\%$ of the families in the sample do not have a pet, how many families in the neighborhood are estimated to have at least one pet?
Solve
Practice★★★Not started
A city council wants to know the level of acceptance of a new traffic regulation. To do this, they set up an information booth outside a school at 9:00 in the morning…

A city council wants to know the level of acceptance of a new traffic regulation. To do this, they set up an information booth outside a school at 9:00 in the morning and ask the first 100 adults who pass by.

  1. a) Define the population under study.
  2. b) Describe the selected sample.
  3. c) Critically analyze the sample selection method. Do you think all citizens had the same probability of being chosen? Propose a stratified random sampling method that would be fairer for this study.
Solve

Putting It All Together

To classify a variable, ask two questions: Does it make sense to average it? and then Does order matter? or Is it counted or measured?

Flowchart for classifying a variable: if averaging makes no sense it is qualitative (ordinal if order matters, otherwise nominal); if it does, it is quantitative (discrete if counted, continuous if measured). Does it make sense to average it? noyes Qualitative Quantitative Does the order matter? Counted or measured? yes → ordinalno → nominalcounted → discretemeasured → continuous
Practice★★☆Not started
Imagine you work in the marketing department of a music streaming platform. You want to investigate the relationship between the age of the users and the style of music…

Imagine you work in the marketing department of a music streaming platform. You want to investigate the relationship between the age of the users and the style of music they listen to the most.

To do this, you design a database with the following fields for each user:

  1. Age (completed years).

  2. Daily listening minutes.

  3. Preferred musical genre (Pop, Rock, Trap, Others).

  4. Degree of satisfaction with the service (from $1$ to $5$).

Classify each of the four previous variables and explain which type of chart (bar chart, pie chart or histogram) you think would be most suitable to represent the data for the variable "Preferred musical genre".

Variable: Musical Genre Clasificación: Nominal Qualitative 0 10 20 30 40 50 Histogram Continuous variables Pop Rock Trap Bar Chart Separate categories Pop Rock Trap Pie Chart Proportions Para variables qualitative, los gráficos adecuados son el Bar Chart o el Pie Chart.
Solve
Practice★★★Not started
A video game developer is analyzing player behavior in a Beta* phase. To optimize performance, they record the following data for each user: 1. The name of the server…

A video game developer is analyzing player behavior in a Beta phase. To optimize performance, they record the following data for each user:

  1. The name of the server they connect to (North, South, East, West).

  2. The unique account identifier code (an 8-digit number).

  3. The response time or ping measured in milliseconds.

  4. The number of times the player has pressed the "pause" button in an hour.

  5. The user's satisfaction level, rated as: "Very dissatisfied", "Dissatisfied", "Neutral", "Satisfied" or "Very satisfied".

Reason and classify each of the above variables. Pay special attention to variable number 2: does the fact that it is a number imply that it is a quantitative variable? Justify your answer.

user_session_data.log 1. Server_Region: "West" 2. Account_ID: 87402119 ? 3. Ping_Latency: 42 ms 4. Pause_Count_per_Hour: 3 5. Satisfaction_Level: "Satisfied"
Solve
Practice★★★Not started
A delivery company wants to improve its efficiency. To do this, it defines the population as "all packages sent in the United States during a year." Since it is…

A delivery company wants to improve its efficiency. To do this, it defines the population as "all packages sent in the United States during a year." Since it is impossible to study them all, they select a sample of 500 packages.

For each package they note down: weight in pounds, volume in $m^3$, destination state, and number of delivery attempts.

  1. a) Identify the population, the sample, and the individuals of the study.
  2. b) Classify the recorded variables.
  3. c) If out of the 500 packages in the sample, 450 have been collected solely from an office in a luxury area of New York, can we say that the sample is representative to draw conclusions about the service throughout the United States? Justify your answer using the concept of statistical bias.
Solve
Practice★★★Not started
Imagine you want to carry out a statistical study on the use of social media among teenagers in your city. You must design a survey that contains exactly: 1. A nominal…

Imagine you want to carry out a statistical study on the use of social media among teenagers in your city. You must design a survey that contains exactly:

  1. A nominal qualitative variable.

  2. An ordinal qualitative variable.

  3. A discrete quantitative variable.

  4. A continuous quantitative variable.

Write a question for each case that is realistic and useful for your research. Explain why each question corresponds to the requested type of variable.

VARIABLES Qualitative NOMINAL [A,B] Qualitative ORDINAL [1º,2º] Quantitative DISCRETE [1,2] Quantitative CONTINUOUS [1.5] SURVEY DESIGN NOMINAL Q1. Question... ORDINAL Q2. Question... Q3. Drag here... Q4. Drag here... Quantitative DISCRETE [1,2]
Solve

Back to the start: To find the favorite artist at your school or the daily phone time of 8th graders, first define the population (all students at your school, or all 8th graders). Then take a random, representative sample, using stratified sampling if you want every grade or group included fairly. Favorite artist is a nominal qualitative variable. Hours on the phone is a quantitative continuous variable.

Summary

See all the exercises in this section