6.3c Geometric Random Variables

Download Report

Transcript 6.3c Geometric Random Variables

Geometric
Random Variables
Target Goal:
I can find probabilities involving geometric random
variables
6.3c
h.w: pg 405: 93 – 99 odd, 101 - 103
Review Binomial:





The # of trials n is fixed.
X counts the number of successes.
Possible values of X are 0, 1, 2…, n
Probability for success same for all n
Independence
Consider:



Flip a coin until you get a head.
Roll a die until you get a 3.
Shoot three pointers until you make 1.
What is the main difference?
Geometric Distributions
Counts the number of trials until an event
happens.
1. Success or failures
2. The probability of success p is the same for
all events.
3. Observations are independent.
4. The variable of interest is (X = 1, 2, 3, …, );
the number of trials required to obtain the
first success.
What does

 represent?
You will never get a success loser.
Which is a Geometric Distribution?

Check the conditions.
Roll Die until “3”
Success or failures
The prob. same
for all events
Y
Y:1/6
Observations are
independent
Y
Execute until
event occurs?
Y
Draw an Ace
Y
N: First draw: 4/52
2nd draw: 4/51
N: previous pick effects
the next.
Y
Rules for Calculating Geometric
Probabilities
The probability of the first success on the
nth trial is:
P(X=n) = (1-p)n-1p for X = 1, 2, 3, …..
{s/a qn-1p}
(1-p) s/a q: Probability of failure with
p being the probability of success
Note:


The longer it takes to get the first success,
the closer the probability gets to 0.
The table of probabilities could have no
end.
Example: Roll a Die
Construct the probability distribution table
for X= the number of rolls of a die until a
three occurs.
P(X=n) = (1-p)n-1p




P(X=1) = (5/6)0(1/6)1 = 0.1667
P(X=2) = (5/6)1(1/6)1 =
P(X=3) =
P(X=4) =
Complete and fill in table.
The probability histogram for a
geometric distribution is always skewed
to the right.
Exercise: Hard Drive
Suppose we have data that suggest that
3% of a company’s hard drives are
defective.
You have been asked to determine the
probability that the first defective hard drive
is the fifth unit tested.
a) Verify that this is a geometric setting.




Success or failures?
The prob. same for all events?
Observations are independent?
Execute until event occurs?
Identify the random variable:

X = number of drives tested in order to find
thefirst defective
What constitutes success in this situation?
 Success is a defective hard drive.
b) What is the probability that the first defective
hard drive is the fifth unit tested?
P(X=n) = (1-p)n-1p

P(X=5) = (1-0.03)5-1 (.03)
= (0.97)4(.03)
= .0266
c) Find the first four entries in the table of the
pdf for the random variable X.
P(X=1), P(X=2), etc. (2min)
X
P(X)
1
.03
2
.0291
3
.0282
4
.0274
Mean or Expected Value
The Mean or Expected Value of a geometric
variable is:
1
 x=
p
The Variance of X is:
σ2 = (1-p)/p2
σ = q / p2


The probability that it takes more than n
trails to see the first success is:
P(X>n) = (1-p)n or qn
Ex. Roll a die until a 3 is observed.
The probability that it takes more than 6
rolls to observe a 3 is:
P(X>6) = (1-p)n
= (5/6)6
 0.335
Exploring Geometric Distributions:
Calculator
Verify our previous results.
 Enter the list of the # of trials, 1 to 7 in L1.
Highlight L2 and enter geometric pdf’s;
Select 2nd VARS: geometpdf (1/6,L1):
Nspire: name after you enter formula

Menu:data;summary plot
Plot Histogram on Plot1



Set windows to X[0,11]1 and Y[-.05, .2]0.1
Xlist: L1, freq: L2
Trace
Simulating Geometric Experiments
Called “wait time” because you continue to
conduct trails until a success is observed.
Example : Show me the Money!
 Cheerios claims a free $1 bill every 20th
box.
 Let’s simulate to determine how many
boxes you need to buy to get the money.
Simulation with Table D




Let 2 digit numbers 00 to 99 represent a
box of Cheerios.
Let 01 to 05 represent a box with $1.
Let 00, 06 to 99 represent a box w/o $1
Read Table B, line 127:
Form pairs and organize into 5 rows, ten
across until a 01 to 05 is found.
Ex. 23 33 06 …

How many boxes did it take? 55!

Why? Check the variation.
Calculate the Variance and Standard
Deviation to better understand the large
number of trails.
p = 1/20 = 0.05
E(X) = 1/p = 20
So why did we get 50?
σ2 = (1-p)/p2 = .95/.0025 = 380
σ (X) = 19.49
How many standard deviations is our result
from the mean?
55 is about 1.8 σ’s to the right of the mean
20. (35 away from 20)
So it is reasonable.
Recall:
σ is not an appropriate measure of spread
for strongly skewed distributions.
Our geometric distribution is strongly
skewed right.
