You are on page 1of 39

Topic Three Probability

Distributions
Part One: Discrete Distributions

Copyright 2010 Pearson


Education, Inc. Publishing as
Prentice Hall

Ch. 3-1

So far...
Uncertainty was formalised as Probability
Theory.
Working with Events too Clumsy

Probabilistic Events transformed into Random


Variables which are easier to apply standard
tools to.
Can be summarised as a probability distribution
But distributions are problem specific
Copyright 2010 Pearson
Education, Inc. Publishing as
Prentice Hall

Ch. 3-2

Analogy to Economic Theory


Useful to have standardised probability
distributions:
Theoretical statistics
Hypothesis testing

The named probability distributions (binomial,


normal etc.) are described by
equations
Statistical tables (for hypothesis testing
Copyright 2010 Pearson
Education, Inc. Publishing as
Prentice Hall

Ch. 3-3

Two groups of Probability Distributions


Probability
Distributions
Discrete
Probability
Distributions

Continuous
Probability
Distributions

Binomial

Uniform

Hypergeometric

Normal

Poisson
4

Discrete Distributions Introduction


Recall a discrete random variable is one that
only takes on countable values
We review three distributions for discrete
random variables:
Binomial
Hypergeometric
Poisson

Binomial and Poisson are regularly used by


econometricians.
Copyright 2010 Pearson
Education, Inc. Publishing as
Prentice Hall

Ch. 3-5

Binomial Distribution
Used extensively.
Applied to generate the probability
distribution of observing X successes from N
trialsl
Will build up in three steps:
1. Introduce the Bernouilli distribution to
describe the probability distribution for a
single event.
Copyright 2010 Pearson
Education, Inc. Publishing as
Prentice Hall

Ch. 3-6

Binomial Distribution II
2. Review expression for Combinations so to
extend probability for single event to the
number of successes from a larger number of
trials.
3. Put the two together to produce the Binomial
Distribution equation.

Copyright 2010 Pearson


Education, Inc. Publishing as
Prentice Hall

Ch. 3-7

Bernoulli Distribution
 Random experiment with only two possible outcomes:
Consider only two outcomes: success or failure
 Let P denote the probability of success
 Let 1 P be the probability of failure
 Define random variable X:
x = 1 if success, x = 0 if failure
 Then the Bernoulli probability function is

P(0) = (1 P) and P(1) = P


8

Bernoulli Distribution
Mean and Variance
 The mean is = P
Proof:

 The variance is 2 = P(1 P)


Proof:

Sequences of x Successes
in n Trials
 The number of sequences with x successes in n independent
trials is:

n!
C =
x! (n x)!
n
x

Where n! = n(n 1)(n 2) . . . 1 and 0! = 1


 These sequences are mutually exclusive, since no two can occur
at the same time

Binomial Probability Distribution


 A binomial random variable describes the outcome of a series
of n independent Bernoulli trials
 Two mutually exclusive and collectively exhaustive categories
 Generally called success and failure
 Probability of success is P , probability of failure is 1 P

 Constant probability for each observation


 e.g., Probability of getting a tail is the same each time we toss the coin

 Observations are independent


 The outcome of one observation does not affect the outcome of the
other

11

Generalising
Examples:
 The number of heads thrown when tossing a coin 100 times
 The number of students that show up in a tutorial
 The number of correct answers in a test
 In principle, we could work out the probabilities corresponding
to a binomial distribution in this way
 However, this would quickly become impractical
 Suppose the student applies to 20 colleges. What is the
probability that exactly 8 colleges admit her?
 We can use a formula that generates the probabilities

12

Generalising
 If
 A random experiment can have only two outcomes
 The probability of a successful trial (p) is constant across
experiments
 Each trial is independent of the rest
 The random variable X defines the number of successes in n
independent trials with a probability p of success in each trial

13

Generalising
Binomial Distribution Formula
n

P ( X = x) = P( x) = Cx p x (1 p) n x
n!
where C x =
x!(n x)!
n

P(x) = probability of x successes in n trials,


with probability of success P on each trial
x = number of successes in sample,
(x = 0, 1, 2, ..., n)
n = sample size (number of trials
or observations)
P = probability of success

Example: Flip a coin


four times, let x = #
heads:
n=4
P = 0.5
1 - P = (1 - 0.5) = 0.5
x = 0, 1, 2, 3, 4
14

Using the formula: Example (1)


The probability that a student applying to a college will
be admitted is 60%
 Suppose the student applies to 6 colleges.
 What is the probability that exactly 2 colleges admit her?
 Number of trials n = 6
 Number of successes x = 2
 Probability of success p = 0.60
n

P( X = x) = Cx p x (1 p) n x
15

Calculating a Binomial Probability:


Example (2)
What is the probability of one success in five observations if the
probability of success is 0.1?
x = 1, n = 5, and P = 0.1

n!
P(x = 1) =
P X (1 P) n X
x! (n x)!
= ??

16

Binomial Distribution
 The shape of the binomial distribution depends on the values
of P and n
n = 5 P = 0.1

Mean

Here, n = 5 and P = 0.1

P(x)

.6
.4
.2
0

x
0

P(x) n = 5 P = 0.5

Here, n = 5 and P = 0.5

.6
.4
.2
0

x
0

Binomial Distribution
Mean and Variance
Mean

= E(x) = nP

Variance and Standard Deviation

2 = nP(1- P)
= nP(1- P)
Where n = sample size
P = probability of success
(1 P) = probability of failure

18

Binomial Characteristics
Examples

Mean = nP = ??
= nP(1 - P) = ??

n = 5 P = 0.1

P(x)
.6
.4
.2
0

x
0

= nP = ??
= nP(1 - P) = ??

P(x) n = 5 P = 0.5
.6
.4
.2
0

x
0

Example (3)
1) Bits are sent over a communications channel in packets of 12. If
the probability of a bit being corrupted over this channel is 0.1 and
such errors are independent, what is the probability that no more
than 2 bits in a packet are corrupted?
2) If 6 packets are sent over the channel, what is the probability that
at least one packet will contain 3 or more corrupted bits?
3) Let X denote the number of packets containing 3 or more
corrupted bits. What is the probability that X will exceed its mean
by more than 2 standard deviations?

20

Other Distributions:
The Hypergeometric Distribution
 n trials in a sample taken from a finite population of size N
 Sample taken without replacement
 Outcomes of trials are dependent
 Concerned with finding the probability of X successes in the
sample where there are S successes in the population

21

Hypergeometric Distribution
Formula
CSxCnNxS
P(x) =
CnN

S!
(N S)!

x!(S x)! (n x)!(N S n + x)!


=
N!
n!(N n)!

Where N = population size


S = number of successes in the population
N S = number of failures in the population
n = sample size
x = number of successes in the sample
n x = number of failures in the sample
22

Using the
Hypergeometric Distribution
Example: 3 different computers are checked from 10 in the
department. 4 of the 10 computers have illegal software
loaded. What is the probability that 2 of the 3 selected
computers have illegal software loaded?

23

Poisson Distribution
In many practical situations we are interested in measuring how
many times a certain event occurs in a specific time interval or in a
specific length or area. For instance:
 The number of phone calls received at an exchange or call centre
in an hour;
 The number of customers arriving at a toll booth per day;
 The number of flaws on a length of cable;
 The number of cars passing using a stretch of road during a day.
The Poisson distribution plays a key role in modelling such problems.
24

Poisson Distribution
Suppose we are given an interval (this could be time, length, area or
volume) and we are interested in the number of successes in that
interval.
Assume that the interval can be divided into very small subintervals
such that:
 The probability that an event occurs in one subinterval is very
small
 The probability of one success in a subinterval is constant for all
subintervals and is proportional to its length;
 Subintervals are independent of each other.
25

Poisson Distribution
Formula
We assume the following:
 The random variable X denotes the number of successes in
the whole interval.
 is the mean number of successes in the interval.
X has a Poisson Distribution with parameter and

e
P(x) =
x!

where:
x = number of successes per unit
= expected number of successes per unit
e = base of the natural logarithm system (e=exp(1)=2.71828...)

26

Poisson Distribution - Example: Hurricanes


The number of Hurricanes over a period of a year in the
Caribbean is known to have a Poisson distribution with = 13.1
Determine the probability function of X.
Compute the probability that X is at most 8.
Compute the probability that X is at least 10.
Given that at least 10 hurricanes occur, what is the probability
that X is at most 15?
Solution:

Poisson Distribution - Example: Hurricanes


We build the following table using the formula:
x
0
1
2
3
4
5
6
7
8
9

p (x )
0.000002
0.000027
0.000175
0.000766
0.002510
0.006575
0.014356
0.026866
0.043994
0.064036

x
10
11
12
13
14
15
16
17
18
19

p (x )
0.083887
0.099901
0.109059
0.109898
0.102833
0.089807
0.073530
0.056661
0.041237
0.028432

Poisson Distribution - Example: Hurricanes


P [a t m o s t 8 ] = P [ X 8 ]

P [ a t le a st 1 0 ] = P [ X 1 0 ] = 1 P [ X 9 ]

P a t m o s t 1 5 a t le a s t 1 0 = P X 1 5 X 1 0

Poisson Distribution: Example(2)


The number of flaws in a fibre optic cable follows a Poisson
distribution. The average number of flaws in 50m of cable is 1.2.
(i) What is the probability of exactly three flaws in 150m of cable?

30

Poisson Distribution: Example(2)


The number of flaws in a fibre optic cable follows a Poisson
distribution. The average number of flaws in 50m of cable is 1.2.
(ii) What is the probability of at least two flaws in 100m of cable?

31

Poisson Distribution: Example(2)


The number of flaws in a fibre optic cable follows a Poisson
distribution. The average number of flaws in 50m of cable is 1.2.
(iii) What is the probability of exactly one flaw in the first 50m of
cable and exactly one flaw in the second 50m of cable?

32

Poisson Distribution: Example(3)


The number of visitors to a webserver per minute follows a
Poisson distribution. If the average number of visitors per minute
is 4, what is the probability that:
(i) There are two or fewer visitors in one minute?

33

Poisson Distribution: Example(3)


The number of visitors to a webserver per minute follows a
Poisson distribution. If the average number of visitors per minute
is 4, what is the probability that:
(i) There are two or fewer visitors in one minute?
We need the average number of visitors in a minute. In this
case the parameter = 4.
We wish to calculate
P(X = 0) + P(X = 1) + P(X = 2).

So the probability of two or fewer visitors in a minute is


e4 + 4e4 + 8e4 = 0.238.

34

Poisson Distribution: Example(3)


The number of visitors to a webserver per minute follows a
Poisson distribution. If the average number of visitors per minute
is 4, what is the probability that:
(ii) There are exactly two visitors in 30 seconds?.

35

Poisson Distribution - Mean and Variance


The mean and variance of a Poisson random variable with
parameter are both equal to .
E(X) = ,

V (X) = .

Example: It believed that the number of bookings taken per hour


at an online travel agency follows a Poisson distribution. Past
records indicate that the hourly number of bookings has a mean of
15 and a standard deviation of 2.5.
Comment on the suitability of the Poisson distribution for this
example?

36

Poisson Approximation to
Binomial Distribution
The Poisson distribution can be derived as a limiting case to the
binomial distribution as 1) the number of trials goes to infinity 2)
the expected number of successes remains fixed
1) n
2) p 0 with np staying constant
Then, writing := np, it can be shown that the binomial
probabilities bin(k; n, p) tend to the Poisson probability
Poisson probabilities can be used to approximate binomial
probabilities when n is large and p is small.
As a rule of thumb, this approximation is acceptable if n 20 and p
0.05 If n 100 and np 10, it is usually an excellent
37
approximation.

Poisson Approximation to
Binomial Distribution
Example: It is known that 3% of the circuit boards from a
production line are defective. If a random sample of 120 circuit
boards is taken from this production line, use the Poisson
approximation to estimate the probability that the sample contains:
(i) Exactly 2 defective boards.

38

Poisson Approximation to
Binomial Distribution
Example: It is known that 3% of the circuit boards from a
production line are defective. If a random sample of 120 circuit
boards is taken from this production line, use the Poisson
approximation to estimate the probability that the sample contains:
(ii) At least 2 defective boards.

39

You might also like