Unit 2 · Topic 2.8 · about 20 minutes
AP Statistics 2.8: Introduction to Random Variables and Probability Distributions
Define a discrete random variable in context and construct its probability distribution, including its cumulative distribution, from the rules of probability or from a simulation.
Unit 2: 15 to 25% of the multiple-choice section
What you'll be able to do
- Build the probability distribution of a discrete random variable.
Key vocabulary
| Term | What it means | The exam trap |
|---|---|---|
| Random variable | A variable whose values are numbers produced by a random process, such as the larger of two dice. | Capital names the variable and lowercase names one of its values, so means the probability that the variable takes the value . |
| Discrete random variable | A random variable that takes a countable set of values, such as 0, 1, 2 and so on. | A time or a height can take any value in an interval, so it is not discrete; those variables come in 2.11 The Normal Distribution. |
| Probability distribution | A table, graph or function giving the probability of every possible value of a discrete random variable. The probabilities add to 1. | Adding to 1 is not enough on its own: 0.60, 0.50, and 0 add to 1, but no probability can be negative. |
| Cumulative probability distribution | A table or function giving , the probability that the variable is less than or equal to each value. | Each cumulative entry already includes every value to its left, so if and , then is 0.30, not 0.85. |
Predict first
Roll two fair dice and let X be the larger of the two numbers (if they match, X is that number). Which value of X is the most likely?
Random variables
A random variable is a variable whose values are numbers produced by a random process. It is named with a capital letter, like , and its possible values are written in lowercase, like . The larger of two dice is a random variable. So are the number of free throws a player makes in a game and the number of texts you get in the next hour.
This lesson is about discrete random variables, which take a countable set of values such as 0, 1, 2 and so on. Variables that can take any value in an interval, like a time or a height, come in 2.11 The Normal Distribution.
Probability distributions
A probability distribution for a discrete random variable gives the probability of every possible value. Every probability in it is between 0 and 1, and the probabilities add to exactly 1.
A distribution can be worked out with the rules of probability, or estimated with a simulation. It can be shown as a table, as a graph, or as a function, meaning a formula that gives the probability for each value.
Worked exampleThe distribution of the larger die
Two fair dice are rolled, and X is the larger of the two numbers. Construct the probability distribution of X.
List the possible values. X can be 1, 2, 3, 4, 5 or 6.
Count the outcomes for each value. All 36 ordered pairs are equally likely. X = 1 only for (1, 1). X = 2 for (1, 2), (2, 1) and (2, 2), three pairs. Each step up adds two more pairs, so the counts are 1, 3, 5, 7, 9 and 11.
Divide each count by 36. The probabilities are and .
Check the total. , so the probabilities add to , as every distribution must.
The table below. As a function, for .
| 1 | 2 | 3 | 4 | 5 | 6 | |
|---|---|---|---|---|---|---|
| As a decimal | 0.028 | 0.083 | 0.139 | 0.194 | 0.250 | 0.306 |
The same distribution as a graph
Each bar's height is the probability of that value of X, and the six heights add to 1.
Cumulative probabilities
A cumulative probability distribution gives, for each value, the probability that X is less than or equal to that value. Build it by adding probabilities from the left: .
For the larger die the cumulative probabilities are square numbers over 36, so as a function, . The grid of rolls from 2.4 Introduction to Probability shows why: means both dice show 3 or less, which is a 3-by-3 block of 9 cells.
| 1 | 2 | 3 | 4 | 5 | 6 | |
|---|---|---|---|---|---|---|
A cumulative table answers "at most" questions directly and "at least" questions through the complement: . The larger die is 5 or 6 more than half the time.
Estimating a distribution by simulation
Some distributions are easier to simulate than to work out. In basketball's one-and-one, a player shoots one free throw. A miss ends the trip with 0 points. A make earns a second shot, so the trip ends with 1 or 2 points. Take a 70% shooter whose shots are independent, and let X be the points she scores. A simulation of 1,000 trips to the line gave the counts below.
The rules of probability give the exact distribution to compare against: , and . Each simulated relative frequency lands within 0.02 of the exact value.
| Points scored, | 0 | 1 | 2 | Total |
|---|---|---|---|---|
| Simulated count | 292 | 228 | 480 | 1,000 |
| Relative frequency | 0.292 | 0.228 | 0.480 | 1 |
| Exact probability | 0.30 | 0.21 | 0.49 | 1 |
Check your understanding
Each list gives probabilities for the values 0, 1, 2 and 3 of a random variable X, in that order. Which list is a valid probability distribution?
Let X be the number of cars owned by a randomly chosen household in a town. Its distribution is below, with one probability missing.
Find . Give a decimal.
The number of siblings X of a randomly chosen student at a school has this cumulative distribution:
What is ?
Let X be the number of goals a soccer team scores in a randomly chosen game, with , , and . What is ?
A player who makes 60% of her free throws goes to the line for a one-and-one. If she makes the first shot she takes a second; if she misses the first, the trip is over. Her shots are independent. Let X be the number of points she scores. What is ?
Exam strategy for this topic
- Section I, Multiple Choice: 42 questions in 90 minutes.
- Section II, Free Response: 4 questions in 90 minutes.
- A graphing calculator with statistical capabilities is expected on both sections.
Questions students ask
Can a value in a probability distribution have probability 0?
Yes. A probability of 0 just means the variable never takes that value. What a distribution cannot have is a negative probability, or probabilities that add to something other than 1.
How do I get from a cumulative table?
Subtract the cumulative probability just before it. For the larger die, .
Why is 6 the most likely value of the larger of two dice?
The larger number is 6 whenever either die shows a 6, which happens in 11 of the 36 rolls. It is 1 only when both dice show 1, which is a single roll.
Should I build a distribution from the rules of probability or from a simulation?
Use the rules when you can work them out, and simulate when the process is awkward to analyze. For a 70 percent shooter on a one-and-one, the rules give 0.30, 0.21 and 0.49, and 1,000 simulated trips landed within 0.02 of each.
How do I find an at least probability from a cumulative table?
Use the complement. For the larger die, .
Course alignment, for teachers
AP Statistics topic 2.8, Unit 2: Probability, Random Variables, and Probability Distributions.
- Skill 3.A: Construct tabular and graphical representations of data and distributions.