Download Chapter 5

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
Chapter 5
Discrete Probability Distributions
Random Variable
A numerical description of the result of an experiment.
Discrete Random Variable
A random variable that can only assume some finite
number of values.
Continuous Random Variable
A random variable that can assume any numerical value
in an interval.
Discrete Probability Distribution
A list of the possible values of a discrete random
variable and the associated probabilities.
Value
Probability
1
1/6
2
1/6
3
1/6
4
1/6
5
1/6
6
1/6
Discrete Probability Function, f(x)
A function that provides the probability for each value
of the discrete random variable
Required Conditions for a Discrete
Probability Function
f(x) > 0 for all x
Sf(x) = 1
Discrete Uniform Probability Function
f(x) = 1/n
Where n is the number of values the random variable
can assume.
Expected Value of a Random Variable
The average value of the variable over an infinite
number of experiments.
E(x) = m = Sxf(x)
Example
Suppose your population consisted of 100 families
with children where:
Number of
Children
1
2
3
Number of
Families
30
50
20
Example, cont.
Using the formula for the weighted mean, we could
write:
m = (Swixi)/(Swi)
= [(1)(30)+(2)(50)+(3)(20)]/[30+50+20]
= (1)(30/100)+(2)(50/100)+(3)(20/100)
= (1)(.3)+(2)(.5)+(3)(.2)
More generally: m = S[xi(wi/Swi)] = Sxf(x)
Variance of a Random Variable
The sum of the squared deviations from the mean
weighted by the probabilities of a value occurring.
Var(x) = s2 = S(x-m)2f(x)
Standard Deviation of a Random
Variable
s
 (x  m  f (x 
2
Random Variable, Example
Assume a random variable can take on the following
three values with the corresponding probabilities:
x
f(x)
1
0.1
2
0.4
3
0.5
Find the expected value and variance of the random
variable
Random Variable, Example
E(x) = (1)(.1) + (2)(.4) + (3)(.5) = 2.4
s2 = (1 - 2.4)2(.1) + (2 - 2.4) 2(.4) + (3 - 2.4) 2(.5)
= (1.96)(.1) + (.16)(.4) + (.36)(.5)
= .196 + .064 + .18
= .44
Random Variable, Example
Random variables.xlsx
Binomial Experiment
1. The experiment consists of a sequence of n
identical trials.
2. Two outcomes are possible on each trial, one
outcome is labeled success the other failure.
3. The probability of success, denoted by p, does
not change from trial to trial.
4. The trials are independent.
Binomial Probability Function
n!
(n  x 
x
f ( x) 
p (1  p 
x!(n  x)!
Binomial Example
A die will be rolled three times. Success is defined as rolling
a 1 or a 2. Failure is defined as rolling a 3 or higher. Assume
we want to find the probability of having one success.
Given that definition:
x=1
n=3
p = 1/3
(1 - p) = 2/3
Binomial Example, Cont.
Success,1/3
Success,1/3
Failure, 2/3
Success,1/3
Success,1/3
Failure, 2/3
Failure, 2/3
Success,1/3
Success,1/3
Failure, 2/3
Failure, 2/3
Success,1/3
Failure, 2/3
Failure, 2/3
Binomial Example, Cont.
Success,1/3
Success,1/3
Failure, 2/3
Success,1/3
Success,1/3
Failure, 2/3
Failure, 2/3
Success,1/3
Success,1/3
Failure, 2/3
Failure, 2/3
Success,1/3
Failure, 2/3
Failure, 2/3
Binomial Example, Cont.
The portion of the binomial formula:
px(1-p)(n-x)
represents the probability of going down one
branch where there are x successes
In this case:
(1/3)1(2/3)2
Binomial Example, Cont.
The other portion of the formula calculates how
many ways we can have a given number of
successes and failures.
n!
x!(n-x)!
Getting x successes in n trials can be thought of as
how many ways can x items be drawn from a
group of n; a questions answered by the
combinations formula.
Binomial Example, Cont.
In this case:
S F F Position 1 is drawn
F S F Position 2 is drawn
F F S Position 3 is drawn
n!
=
3!
= 3! = 3
x!(n-x)!
1!(3-1)!
2!
Expected Value and Variance for
the Binomial Distribution
E(x) = m = np
Var(x) = s2 = np(1 – p)
Practice
Assume the probability of getting a bad part (success)
is 20 percent and the probability of getting a good
part (failure) is 80 percent.
1. If we draw 6 parts and test them, what is
probability of drawing 3 bad parts?
2. If we drawing at least 2 bad parts (given we draw
5)?
3. What is the expected value of the distribution?
The variance?
Practice, cont.
n!
(n x 
x
f ( x) 
p (1  p 
x!(n  x)!
6!
(6 3 
3

.2 (1  .2
3!(6  3)!
6! 3 .3 6  5  4
(0.008(0.512

.2 .8 
3!3!
3  2 1
 0.08192
( ( 
Practice, cont.
f ( x 2)  1  [ f (1  f (0
 6!
6!
(6 1
(6  0  
1
0
 1 
.2 (1  .2 
.2 (1  .2 
0!(6  0)!
1!(6  1)!

( ( 
( ( 
6! 0 .6 
 6! 1 .5
 1 
.2 .8 
.2 .8 
0!6!
1!5!

 1  [6(0.2(0.32768  1(1(0.262144
 1  [0.393216  0.262144  0.34464
Practice, cont.
E ( x)  np  6(.8)  .48
s  np(1  p)  6(.2(.8  0.96
Binomial Applet
http://stattrek.com/Tables/Binomial.aspx
Graded Homework
P. 199-200, #21, 23
P. 209-210, #29,31
Binomial Applet
http://onlinestatbook.com/stat_sim/index.html
Related documents