3 - Random Variables and Probability Distributions

You might also like

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 57

Chapter 3

Random
Variables and
Probability
Distributions

Copyright © 2017 Pearson Education, Ltd. All rights reserved.


Section 3.1
Concept of a
Random Variable

Copyright © 2017 Pearson Education, Ltd. All rights reserved.


Randomness

• A random variable is a numerical measurement


of the outcome of a random phenomenon.

•Often, the randomness results from


– the use of random sampling
or
– a randomized experiment to gather the data.

6-3 Copyright © 2017, Pearson Education, Ltd. All Rights Reserved


Random Variable

• Use letters near the end of the alphabet, such as x, to symbolize:


– variables
– a particular value of the random variable.

• Use a capital letter, such as X, to refer to the random variable itself.

• Example: Flip a coin three times.


– X = number of heads in the 3 flips; denotes the random
variable.
– x = 2; represents a possible value of the random variable.

6-4 Copyright © 2017, Pearson Education, Ltd. All Rights Reserved


Probability Distribution

•The probability distribution of a random


variable specifies its possible values and their
probabilities.

•An advantage of a variable being a random


variable is that it’s possible to specify such
probabilities. Without randomness, we would not
be able to predict the probabilities of the possible
outcomes in the long run.

6-5 Copyright © 2017, Pearson Education, Ltd. All Rights Reserved


Probability Distribution of a
Discrete Random Variable

•A discrete random variable X takes a set of separate


values (such as 0, 1, 2, . . .). Its probability
distribution assigns a probability P(x) to each
possible value x.

For each x, the probability P(x) falls between 0 and 1.

The sum of the probabilities for all the possible x


values equals 1.

6-6 Copyright © 2017, Pearson Education, Ltd. All Rights Reserved


Example: Best of Seven
• What is the probability that a best of seven series
will be decided by at least six games?

Table 6.1 Probability Distribution of Number of Games Needed to Determine a


Winner in a Best of Seven Series

6-7 Copyright © 2017, Pearson Education, Ltd. All Rights Reserved


Example: Best of Seven
• What is the probability that a best of seven series
will be decided by at least six games?

Table 6.1 Probability Distribution of Number of Games Needed to Determine a


Winner in a Best of Seven Series

• The probability of at least six games in a best of seven series is


• P(6) + P(7) = 5/16 + 5/16 = 10/16 = 0.625.

6-8 Copyright © 2017, Pearson Education, Ltd. All Rights Reserved


Definition 3.1

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3-9


Definition 3.2

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 10


Definition 3.3

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 11


Section 3.2
Discrete
Probability
Distribution

Copyright © 2017 Pearson Education, Ltd. All rights reserved.


Example

• Consider an experiment in which a fair coin is


tossed 3 times
• X=The number of heads
• Let’s assign 1 for head and 0 for tail.
• Sample space is
• S={TTT,TTH,THT,HTT,THH,HTH,HHT,HHH}
• Possible values of X is 0,1,2,3

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 13


Example

X 0 1 2 3 Total
f(x) 1/8 3/8 3/8 1/8 1

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 14


Definition 3.4

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 15


Distribution and Relative
Frequencies
• Example: The number of TVs per household.
# of TVs # of households p(x)
0 1.218
1 32.379
2 37.961
3 19.387
4 7.714
5 2.842

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 16


Distribution and Relative
Frequencies
• Example: The number of TVs per household.
# of TVs # of households p(x)
0 1.218 1.218/101.501=0.12
1 32.379 0.319
2 37.961 0.374
3 19.387 0.191
4 7.714 0.076
5 2.842 0.028
101.501 1

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 17


Distribution and Relative
Frequencies
• Example: The number of TVs per household.
# of TVs # of households p(x)

0 1.218 1.218/101.501=0.12

1 32.379 0.319

2 37.961 0.374

3 19.387 0.191

4 7.714 0.076

5 2.842 0.028

101.501 1

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 18


Example

• A shipment of 20 similar laptop computers to a


retail outlet contains 3 that are defective. If a
school makes a random purchase of 2 of these
computers find the prob. dist. For the number of
defectives.

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 19


Example

x 0 1 2
f(x) 68/95 51/190 3/190

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 20


Definition 3.5

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 21


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 22


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 23


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 24


Figure 3.1 Probability mass
function plot

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 25


Figure 3.2 Probability histogram

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 26


Figure 3.3 Discrete cumulative
distribution function

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 27


Section 3.3
Continuous
Probability
Distributions

Copyright © 2017 Pearson Education, Ltd. All rights reserved.


Figure 3.4 Typical density
functions

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 29


Figure 3.5 P(a < X < b)

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 30


Definition 3.6

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 31


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 32


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 33


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 34


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 35


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 36


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 37


Definition 3.7

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 38


Figure 3.6 Continuous cumulative
distribution function

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 39


Section 3.4
Joint Probability
Distributions

Copyright © 2017 Pearson Education, Ltd. All rights reserved.


Definition 3.8

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 41


Definition 3.9

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 42


Example

• Two pens are selected at random from a bowl


that contains 3 blue, 2 red, 3 green. Find the
joint prob. dist.?

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 43


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 44


Table 3.1 Joint Probability
Distribution for Example 3.14

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 45


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 46


Example

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 47


Definition 3.10

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 48


Table 3.1 Example 3.14

h(0)

h(1)
h(2)

g(0) g(1) g(2)

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 49


Example 2

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 50


Definition 3.11

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 51


Example 3.14

a) Find conditional probability distribution of X


given that Y=1
b) P(X=0|Y=1)

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 52


Example 3.14

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 53


Definition 3.12

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 54


Example

• Let X and Y have distribution given in table


a)Marginal dist. of X and Y?
b)Are they statistically independent
1 2
1 0.2 0.3
2 0.4 0.1

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 55


Example

y\x 1 2
1 0.2 0.3
2 0.4 0.1

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 56


Definition 3.13

Copyright © 2017 Pearson Education, Ltd. All rights reserved. 3 - 57

You might also like