You are on page 1of 12

CHAPTER 6

Random Variables
6.1: Discrete and Continuous Random
Variables

The Practice of Statistics, 5th Edition


Starnes, Tabor, Yates, Moore

Bedford Freeman Worth Publishers


Random Variables and Probability Distributions
A probability model describes the possible outcomes of a chance process and
the likelihood that those outcomes will occur.

Consider tossing a fair coin 3 times.


Define X = the number of heads obtained
X = 0: TTT
X = 1: HTT THT TTH
X = 2: HHT HTH THH
X = 3: HHH
Value 0 1 2 3
Probability 1/8 3/8 3/8 1/8

AA random
random variable
variable takes
takes numerical
numerical values
values that
that describe
describe the
the
outcomes
outcomes of
of some
some chance
chance process.
process. The
The probability
probability distribution
distribution ofof
aa random
random variable
variable gives
gives its
its possible
possible values
values and
and their
their probabilities.
probabilities.

The Practice of Statistics, 5th Edition 2


Discrete Random Variables
There are two main types of random variables: discrete and continuous. If we
can find a way to list all possible outcomes for a random variable and assign
probabilities to each one, we have a discrete random variable.

Discrete Random Variables And Their Probability Distributions


A discrete random variable X takes a fixed set of possible values with gaps
between. The probability distribution of a discrete random variable X lists the
values xi and their probabilities pi:
Value: x1 x2 x3 …
Probability: p1 p2 p3 …
The probabilities pi must satisfy two requirements:
1.Every probability pi is a number between 0 and 1.
2.The sum of the probabilities is 1.
To find the probability of any event, add the probabilities pi of the particular
values xi that make up the event.
The Practice of Statistics, 5th Edition 3
Mean (Expected Value) of a Discrete Random Variable
When analyzing discrete random variables, we follow the same strategy we
used with quantitative data – describe the shape, center, and spread, and
identify any outliers.
The mean of any discrete random variable is an average of the possible
outcomes, with each outcome weighted by its probability.

Suppose
Suppose that
that X
X is
is aa discrete
discrete random
random variable
variable whose
whose probability
probability
distribution
distribution is
is
Value:
Value: xx11 xx22 xx33 …

Probability:
Probability: pp11 pp22 pp33 …

To
To find
find the
the mean
mean (expected
(expected value)
value) ofof X,
X, multiply
multiply each
each possible
possible
value
value by
by its
its probability,
probability, then
then add
add all
all the
the products:
products:
 x  E ( X )  x1 p1  x2 p2  x3 p3  ...
  xi pi

The Practice of Statistics, 5th Edition 4


Mean (Expected Value) of a Discrete Random Variable
A baby’s Apgar score is the sum of the ratings on each of five scales, which gives
a whole-number value from 0 to 10.
Let X = Apgar score of a randomly selected newborn

Compute the mean of the random variable X. Interpret this value in context.

We see that 1 in every 1000 babies would have an Apgar score of 0; 6 in every
1000 babies would have an Apgar score of 1; and so on. So the mean (expected
value) of X is:

The mean Apgar score of a randomly selected newborn is 8.128. This is the
average Apgar score of many, many randomly chosen babies.
The Practice of Statistics, 5th Edition 5
Standard Deviation of a Discrete Random Variable
Since we use the mean as the measure of center for a discrete random variable,
we use the standard deviation as our measure of spread. The definition of the
variance of a random variable is similar to the definition of the variance for
a set of quantitative data.

Suppose
Suppose that
that X
X is
is aa discrete
discrete random
random variable
variable whose
whose probability
probability
distribution
distribution is
is
Value:
Value: xx11 xx22 xx33 …

Probability:
Probability: pp11 pp22 pp33 …

and
and that
that µµXX is
is the
the mean
mean of
of X.
X. The
The variance
variance of
of X
X is
is

To get the standard deviation of a random variable, take the square root of
the variance.

The Practice of Statistics, 5th Edition 6


Standard Deviation of a Discrete Random Variable
A baby’s Apgar score is the sum of the ratings on each of five scales, which gives
a whole-number value from 0 to 10.
Let X = Apgar score of a randomly selected newborn

Compute and interpret the standard deviation of the random variable X.


The formula for the variance of X is

The standard deviation of X is σX = √(2.066) = 1.437.


A randomly selected baby’s Apgar score will typically differ from the mean
(8.128) by about 1.4 units.
The Practice of Statistics, 5th Edition 7
Analyzing Random Variables On Graphing Calculator
• Enter the values of the random variable in L1/list 1 and the corresponding
probabilities in L2/list 2.
1. TI-83/84: Press Stat and select enter for lists.
2. TI-89: Go to data/matrix editor and create a name for list.
• To graph the histogram:
1. Set up Stat Plot:
TI-83/84: Press 2nd Stat Plot: change to histogram, xlist: L1, freq: L2
TI-89: Press F2 (Plots): change to histogram, xlist: L1, freq: L2
2. Adjust window: leave some extra space for min and max
3. Press Graph. Press Trace button & scroll left/right to move along histogr
• Calculate the mean and standard deviation: use one variable statistics with the
values in L1 and L2.
1. TI-83/84: Press Stat, arrow over to Calc, select 1-Var Stats type L1, L2, Press
Enter.
2. TI-89: Go back to your data in data/matrix editor, Press F4 (Calc), select 1-Var
Stats, inputs: c1, freq: c2, Press Enter.
The Practice of Statistics, 5th Edition 8
Continuous Random Variables
Discrete random variables commonly arise from situations that involve
counting something. Situations that involve measuring something often result
in a continuous random variable.

A
A continuous
continuous random
random variable
variable X X takes
takes on
on all
all values
values in
in an
an interval
interval
of
of numbers.
numbers. The
The probability
probability distribution
distribution of
of X
X is
is described
described byby aa
density
density curve.
curve. The
The probability
probability ofof any
any event
event isis the
the area
area under
under the
the
density
density curve
curve and
and above
above the
the values
values of
of XX that
that make
make upup the
the event.
event.

The probability model of a discrete random variable X assigns a probability


between 0 and 1 to each possible value of X.

A continuous random variable Y has infinitely many possible values. All


continuous probability models assign probability 0 to every individual
outcome. Only intervals of values have positive probability.

The Practice of Statistics, 5th Edition 9


Example: Normal probability distributions
The heights of young women closely follow the Normal distribution with mean µ
= 64 inches and standard deviation σ = 2.7 inches.

Now choose one young woman at random. Call her height Y.


If we repeat the random choice very many times, the distribution of values
of Y is the same Normal distribution that describes the heights of all young
women.

Problem: What’s the probability


that the chosen woman is
between 68 and 70 inches tall?

The Practice of Statistics, 5th Edition 10


Example: Normal probability distributions
Step 1: State the distribution and the values of interest.
The height Y of a randomly chosen young woman has the N(64, 2.7) distribution. We want
to find P(68 ≤ Y ≤ 70).
Step 2: Perform calculations—show your
work! Remember: P(68 ≤ Y ≤ 70) = area
under the curve.
1.) Find z-score
2.) Use table A and look up area
under curve with corresponding z-score.

The standardized scores (z-scores) for the


two boundary values are

x   mean
z
   std. dev.
(Area under normal distribution
curve is from ch 2)
The Practice of Statistics, 5th Edition 11
Discrete and Continuous Random Variables
Section Summary
In this section, we learned how to…
 COMPUTE probabilities using the probability distribution of a discrete
random variable.
 CALCULATE and INTERPRET the mean (expected value) of a discrete
random variable.
 CALCULATE and INTERPRET the standard deviation of a discrete random
variable.
 COMPUTE probabilities using the probability distribution of certain
continuous random variables.

The Practice of Statistics, 5th Edition 12

You might also like