You are on page 1of 37

Random Variables &

Probability Distributions
Consider the random experiment of observing
outcomes of a treatment in two patients.

Sample space, S = {RR, RN, NR, NN}

Let X = the number of “R” in the outcome

S* = { 0, 1, 1, 2}
Random Variable
• a real-valued function defined over a sample
space
• assigns a real number to every sample point of
the sample space

Types:
– Discrete
– Continuous
Consider S* = { 0, 1, 1, 2}

Frequency Distribution of X
x 0 1 2

Frequency 1 2 1
Probability Distribution of X
x 0 1 2

f(x) 1/4 2/4 1/4

0.6
0.5
0.4
P[ X = x ]

0.3
0.2
0.1
0
0 1 2
x
Probability Distribution for
Discrete Variables

• a table, graph or a formula listing all possible


values of a discrete random variable together
with its corresponding probability
Example

Given: Probability Function of Y

f ( y ) = 3 C y ( 0.5) y ( 0.5) 3- y , y = 0,1, 2,3

Present it in tabular form.


Expected Value or Mean of the Random
Variable X

• the sum of all possible values of the random


variable, each weighted by its probability

E[X] =  X =  x  f ( x)
x
Variance of the Random Variable X

V(X )  2X  E[( x  )2 ]    x    2  f (x )


x
Try it now!
An employee for a vending concession at a ball park
must choose between working behind the ‘hotdog counter’
and receiving a fixed sum of $50 for the evening versus
walking around the stands selling beer on a commission
basis. If the latter is chosen, the employee can earn $90 on a
warm night, $70 on a moderate night, $45 on a cool night,
and $15 on a cold night. At this time of year, the probability
of a warm, moderate, cool, or cold night is 0.2, 0.4, 0.3, and
0.1, respectively. Let X be the earnings of the employee for
the evening by selling beer walking around the stands.
1. Present the probability distribution of X.
2. Find the mean or the expected value to be earned by
selling beer walking around the stands.
3. Which product should the employee sell, hotdog or
beer? Justify.
Special Discrete Probability
Distributions
Binomial Distribution
• Binomial Process
– a sequence of n independent trials
– each trial results to either success or failure
– the probability of success, p, does not change
from trial to trial.
• (Sequence of n independent Bernoulli trials).
Binomial Distribution
• From this sequence of n independent trials, a
sample point would consist of x “S” and (n-x)
“F”. Rearranging such a point we have

SSSS  S FFFF
     F
x n x
• The probability that such a sample point would
be observed is

ppp  p (1  p)(1  p ) (1  p )  p x (1  p ) n  x
           
x n x
Binomial Distribution
• There would be a total of n Cx such sample
points [sample points consisting of exactly x
“successes” out of n trials].
• Thus,
n x
P[ X  x]    p (1  p ) n  x
 x
Binomial Distribution
• Let X be the number of successes in n such trials.
Then X is a binomial random variable and it’s density
function is given by

 n  x n x
 x  p (1  p ) , x  0,1, 2,..., n
 

f ( x; n, p)  P[ X  x]  
0 , otherwise



• Notation: X~bin(n,p)
Binomial Distribution
• If X has a binomial distribution, then

E[ X ]  np
V [ X ]  npq
Example
The probability that a patient recovers from a rare blood
disease is 0.4. Suppose 5 people are known to have
contracted this disease. Let X be the number of persons who
recover from the rare blood disease.
1.Find and completely specify the distribution of X.
2.Find the mean and variance of the number of persons
who recover from the rare blood disease.
Example
3.What is the probability that exactly 5 persons recover
from the rare blood disease?
4.What is the probability that at least 13 persons recover
from the rare blood disease?
5.What is the probability that from 3 to 5 persons
(inclusive) recover from the rare blood disease?
Poisson Distribution
• A random variable X is said to be a Poisson
random variable if its probability mass function
is given by

 e  x
 , x  0,1, 2,...;   0
f ( x;  )  P[ X  x]   x !
0 , otherwise
Poisson Distribution
• If X has a Poisson distribution, then

E[ X ]  
V[X ]  
Poisson Distribution
• The Poisson distribution provides a realistic
model for many phenomenon that involves
counts. Examples are the number of accidents
occurring for a given time interval, the number of
emergency cases admitted for a given time
period, number of telephone calls entering a
switchboard for a large company. The parameter
 is the mean number of occurrences for a given
time interval.
Example
On the average, a certain intersection results in 3 traffic
accidents per month. Let X be the number of traffic
accidents in that intersection.
1.Find and completely specify the distribution of X.
2.What is the probability that in any given month at this
intersection
a) exactly 5 accidents will occur?
b) less than 3 accidents will occur?
c) at least 2 accidents will occur?
Try it now!!!
1.A baseball player’s batting average is 0.25. Suppose it
is of interest to find the probability, that in his next 5 times
at the bat, he gets exactly 1 hit, or more than 3 hits, or at
most 2 hits.
a) Define a discrete random variable. Find and
completely specify its distribution.
b) What is the probability, that in his next 5 times at
the bat, he gets exactly 1 hit?
c) What is the probability, that in his next 5 times at
the bat, more than 3 hits?
d) What is the probability, that in his next 5 times at
the bat, at most 2 hits?
Try it now!!!
2. The average number of days school is closed due to snow
during winter in a certain city in the western part of United
States is 4. Suppose it is of interest to find the probability
that the schools in this city will close for 6 days, more than 2
days, or from 1 to 3 days during a winter.
a) Define a discrete random variable. Find and
completely specify its distribution.
b) What is the probability that the schools in this city
will close for 6 days?
c) What is the probability that the schools in this city
will close for more than 2 days?
d) What is the probability that the schools in this city
will close from 1 to 3 days?
Normal Distribution

Visualizing the Normal Distribution


http://www.mathsisfun.com/data/quincunx.html
Normal Distribution
• A random variable X is said to have a
normal distribution if its density
function is given by
1  x    2
1  
2   
f(x) e    x  
2  ,
Normal Distribution
• The normal distribution is visualized
by the normal curve given by

μ
Standard Normal Distribution
• a normal random variable with mean 0 and
variance 1
1 2
1 z
f ( z)  e2
2
Standard Normal Distribution
• The standard normal distribution is
visualized by the normal curve given
by

0
Standard Normal Distribution
NOTE:
• areas under the normal curve correspond
to probabilities
• areas under the standard normal curve
are summarized in the normal
distribution table or z –table
Standard Normal Distribution
Examples: If Z ~ N(0,1), find
1.P[Z > 1.24]
2.P[Z < -2.37]
3.P[-2.37 < Z < 1.24]
4.a such that P[Z < a] = 0.9147
5.b such that P[Z > b] = 0.0526
Standard Normal Distribution
NOTE:
• a normal random variable X with mean
 and variance 2 can be transformed
to a standard normal random variable z
by
x
z

Applications
The distribution of IQs of applicants to a
certain university is normally distributed
with a mean of 115 and a standard
deviation of 12.
1. What percentage of the applicants has an
IQ between 103 and 127?
2. Suppose the university accepts only
applicants whose IQ belongs to the top
2.5%. What is the lowest IQ of the
applicant who gets accepted to the
university?
Try it now!!!
A lawyer commutes daily from his suburban
home to his midtown office. On the average, the
trip takes 24 minutes with a standard deviation of
3.8 minutes. Assume the distribution of trip times
to be normally distributed.

1.What is the probability that a trip will take at


least ½ hour?
Try it now!!!
2. If the office opens at 9:00 A.M. and he
leaves his house at 8:45 A.M. daily, what
percentage of the time is he late for work?

3. Find the length of time above which we


find the slowest 15% of the trips.
Try it now!!!
Grades on an examination is known to follow
a normal distribution with mean 76 and
standard deviation of 6.5.
1. What percentage of the students will have
a grade between 72 and 85?
2. Suppose 12% of the class is given a grade
of 4.0. Determine the lowest possible
grade for a 4.0.
Try it now!!!
The heights of students of a university are normally distributed
with a mean of 174.5 centimeters and a standard deviation of 6.9
centimeters. Assume that the heights are recorded to the nearest
centimeter.
1.What percentage of the class has heights of at least 172
centimeters?
2.Suppose 10% of the students in this university were given a
vitamin that boosts the growth system of a person. What were
the heights of the students who were given this vitamin?

You might also like