Educerie

Educerie · AP · Statistics

AP Statistics 1.2

Variables

How do we describe data about one variable, and how must the data be collected before we can trust what they say?

What you will learn

  • Understand that each observational unit has values for one or more variables
  • Know how to classify a variable as categorical or quantitative, and a quantitative one as discrete or continuous
  • Understand the difference between a parameter and a statistic and the symbols for each
  • Know that a statistic changes from sample to sample

You must be able to

  1. Classify a variable as categorical or quantitative, and as discrete or continuous
  2. Identify the observational unit and the variable of interest in a study
  3. State whether a number is a parameter or a statistic, with its symbol
  4. Explain why a sample statistic may differ from the population parameter
  5. Recognize a numeric label such as a postal code as categorical

In the exam. Section I multiple choice, where a scenario asks you to name the observational unit, classify a variable, or say whether a number is a parameter or a statistic. In Section II, Question 1 and Question 3 begin by asking you to identify and classify the variables of a study. That is worth two points in the sample free-response question on inference. Every later choice, from a graph to a test, depends on classifying the variable correctly.

1Observational units and variables

Observational unit = the item or individual from which one datum is collected.

Variable = a characteristic that may change from one observational unit to another.

Example: a hospital records the blood type and the waiting time of each patient who arrives on one night. The observational unit is a patient. The variables are blood type and waiting time.

The unit is the "thing" that gets one row of data. The variable is the column. A data set with 60 patients and two variables has 60 rows and two columns.

Variables are not only numbers typed into a table. Photographs, sounds, videos and text also carry information when you record a characteristic from them. A researcher who codes each customer review as "positive" or "negative" has made a categorical variable out of text.

2Categorical and quantitative variables

Categorical variable = takes values that are category names or group labels. It is also called a qualitative variable.

Quantitative variable = takes numerical values for a measured or counted quantity, and generally has units of measure. It is also called a numerical variable.

A fast test: can you sensibly add the values and divide by the count to get an average? If yes, the variable is quantitative. If the average would mean nothing, it is categorical.

VariableObservational unitTypeWhy
Blood typeA patientCategoricalValues are group names
Time spent waiting (minutes)A patientQuantitativeA measured amount with units
Number of siblingsA studentQuantitativeA count
Favorite sportA studentCategoricalGroup names
Jersey numberA playerCategoricalThe number is a label, not an amount
Postal codeA householdCategoricalA label, even though it is made of digits

The last two rows are the traps. A number that only names or identifies a unit is a label. Averaging jersey numbers does not describe anything. Look at what the number does, not what it looks like.

3Discrete and continuous

A quantitative variable is one of two kinds.

Discrete variable = takes a countable number of values. The values can be finite (0, 1, 2, 3) or countably infinite, like the whole numbers.

Continuous variable = can take every value between any two values in an interval. It can be measured but its values cannot be counted one by one.

  • Counts are discrete: the number of siblings, the number of goals in a match, the number of errors on a page.
  • Measurements on a scale are continuous: waiting time, height, mass, temperature.

Between 3 and 4 siblings there is no value. Between 3.0 and 4.0 minutes there are infinitely many.

Rounding does not change the type. A waiting time recorded to the nearest minute is still continuous, because time itself can take any value. The recording is coarse, not the variable. Ask what the variable could in principle be, not how it was written down.

4Parameters and statistics

Parameter = a numerical attribute or summary of the variable of interest for a population.

Statistic = a numerical attribute or summary of the variable of interest for a sample.

The exam uses fixed symbols for the common ones. You will see them from Topic 1.7 onward and throughout the course.

SummaryPopulation (parameter)Sample (statistic)
Meanμ\muxˉ\bar{x}
Standard deviationσ\sigmass
Proportionppp^\hat{p}

Type "mu", "x-bar", "p-hat" and "sigma" on the digital exam if the toolbar is slow. The reference sheet lists these keyboard options.

Example (invented): a company has 3,000 employees and wants the mean number of minutes they spend commuting. It surveys 100 of them and gets a mean of 34 minutes.

  • The value 34 minutes is a statistic: it summarizes a sample. Its symbol is xˉ\bar{x}.
  • The mean commute of all 3,000 employees is the parameter. Its symbol is μ\mu. It is unknown.

A statistic is used to estimate a parameter. The sample result is known and the population value is not.

5Why a statistic may not equal the parameter

Different samples from the same population give different statistics. The value of a statistic is often not equal to the unknown parameter, but it can help us make inferences about it.

A small population shows this. Six students took a quiz. Their scores are 60, 70, 75, 80, 85 and 90.

μ=60+70+75+80+85+906≈76.7the parameter, for all six students\mu = \frac{60 + 70 + 75 + 80 + 85 + 90}{6} \approx 76.7 \qquad \textcolor{#838c91}{\text{the parameter, for all six students}}

Three students are chosen to make a sample. Here are three possible samples:

SampleScoresSample mean xˉ\bar{x}
160, 75, 9075.0
270, 80, 8578.3
375, 80, 9081.7

The parameter μ≈76.7\mu \approx 76.7 is one fixed value. The statistics are 75.0, 78.3 and 81.7. None equals μ\mu, and no two are the same. This is not a mistake. It is the ordinary behavior of a sample, and the later units of the course measure how large it is likely to be.

When you meet a number in a scenario, ask: does it describe everyone in the population, or only those sampled?

6Worked example: classify everything

Example (invented): a researcher studies 200 adult cyclists chosen from the members of a large cycling club. For each cyclist she records the number of rides in the past month, the type of bicycle (road, mountain, other) and the total distance ridden in the past month in kilometers. She finds that 0.37 of the cyclists in the sample own a mountain bicycle, and the mean distance is 312 km.

  • Observational unit: one cyclist.
  • Population: all adult members of the club. Sample: the 200 chosen.
  • Number of rides: quantitative, discrete (a count).
  • Type of bicycle: categorical.
  • Total distance in km: quantitative, continuous (measured, with units).
  • 0.37: a statistic. It is a proportion of the sample, so the symbol is p^\hat{p}.
  • 312 km: a statistic, the sample mean xˉ\bar{x}.

Each answer is short and ties to a feature of the scenario. That is the pattern to copy.

7Choosing the variable of interest

Sometimes a scenario describes a study in words and you must pick out the variable. Read the investigative question.

  • "Do students who sleep more earn higher marks?" has two variables: hours of sleep (quantitative) and marks (quantitative).
  • "What proportion of residents support the new park?" has one variable: support, yes or no (categorical). The proportion is a statistic computed from it.
  • "Is the mean battery life of this phone greater than 12 hours?" has one variable: battery life in hours (quantitative, continuous). The mean is the parameter.

A proportion or mean is a summary of a variable. It is not itself the variable. The variable is the characteristic recorded on each unit, such as "supports the park" or "battery life".

Practice questions

30 questions on this note, from easy to hard. Each one you get right lights a star of this topic's constellation.