0% found this document useful (0 votes)
25 views38 pages

Lecture 2 - Probability Concepts and Applications

Uploaded by

markassal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views38 pages

Lecture 2 - Probability Concepts and Applications

Uploaded by

markassal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 38

PROBABILITY DISTRIBUTIONS AND

DATA MODELING

Copyright ©2016 Pearson Education, Inc. modified by Nigussie Mengesha


Basic Concepts of Probability
 Probability is a numerical statement about the likelihood that an event
will occur.
• Probabilities are expressed as values between 0 and 1.
• Total of all event probabilities equals 1
Defined from one of three perspectives:
 Classical definition: probabilities can be deduced from theoretical
arguments
 Relative frequency definition: probabilities are based on empirical data
 Subjective definition: probabilities are based on judgment and
experience
Classical Definition of Probability
Roll 2 dice
 36 possible rolls (1,1), (1,2),…(6,5), (6,6)
 Probability = number of ways of rolling a
number divided by 36; e.g., probability of a 3
is 2/36 two consumers try a new product.
Suppose
 Four outcomes:
1. like, like
2. like, dislike
3. dislike, like
4. dislike, dislike
 Probability at least one dislikes product =
Relative Frequency Definition of Probability
• Historical demand for white latex paint at = 0, 1, 2, 3, or 4
gallons per day
• Observed frequencies over the past 200 days
QUANTITY
DEMANDED NUMBER OF DAYS PROBABILITY
(GALLONS)
0 40 0.20 (=
40/200)
1 80 0.40 (=
80/200)
2 50 0.25 (=
50/200)
3 20 0.10 (=
20/200)
4 10 0.05 (=
10/200)
Basics of Probability
 An event is a collection of one or more outcomes from a sample space.
 The probability of any event is the sum of the probabilities of the outcomes
that comprise that event.
 The probability of the complement of any event A is P(Ac) = 1 – P(A).
 If events A and B are mutually exclusive, then P(A or B) = P(A) + P(B).
 If two events A and B are not mutually exclusive, then P(A or B) = P(A)+ P(B)
- P(A and B).
 Joint probability
 Conditional probability
 Dependent/Independent Events
Random Variables
 A random variable assigns a real number to every possible outcome or event in an
experiment
X = number of refrigerators sold during the day

 Discrete random variables is one for which the number of possible outcomes can
be counted.
• outcomes of dice rolls
• whether a customer likes or dislikes a product
 Continuous random variables can assume any one of an infinite set of values
between a lower limit and an upper limit
• daily temperature
• time between machine failures
 A probability distribution is a characterization of the possible values that a random
variable may assume along with the probability of assuming these values.
Discrete Probability Distributions
 For a discrete random variable X, the probability distribution of the
discrete outcomes is called a probability mass function and is
denoted by a mathematical function, f(x).
• The symbol xi represents the ith value of the random variable X and f(xi) is the
probability.
Example: Probability mass function for rolling two dice
Probability Mass Function for Rolling Two
Dice
 xi = values of the random variable X, which represents sum
X (Die Sum) Frequency f(X)
of the rolls of two dice 2 1 0.03
• x1 = 2, x2 = 3, …, x10 = 11, x11 = 12 3 2 0.06
 f(x1) = 1/36 = 0.0278; f(x2) = 2/36 = 0.0556, etc 4 3 0.08
Probability Distribution for Rolling Two Dice 5 4 0.11
0.18 6 5 0.14
0.16 7 6 0.17
0.14
8 5 0.14
0.12
9 4 0.11
0.1
0.08
10 3 0.08
0.06 11 2 0.06
0.04 12 1 0.03
0.02 Sum 36 1
0
2 3 4 5 6 7 8 9 10 11 12
Cumulative Distribution Function
Outc Number Prob. Cumulative
 A cumulative distribution function, F(x), ome of Ways f(x) Prob. F(X)
specifies the probability that the random 2 1 0.0278
variable X assumes a value less than or 3 2 0.0556
4 3 0.0833
equal to a specified value, x; that is, 5 4 0.1111
F(x) = P(X ≤ x) 6 5 0.1389
7 6 0.1667
8 5 0.1389
 Probability of rolling a 6 or less = F(6) = 0.1667
9 4 0.1111
 Probability of rolling between 4 and 8:
10 3 0.0833
= P(4 ≤ X ≤ 8) = P(3 < X ≤ 8) = P(X ≤ 8) – P(X ≤ 3) 11 2 0.0556
= 0.7222 – 0.0833 = 0.6389 12 1 0.0278
Total 36 1.0000
Expected Value of a Discrete
Probability Distribution
 Expected value is a measure of the central tendency of the distribution;
corresponds to the notion of the mean, or average, for a sample.

where
Xi = random variable’s The Expected
possible values Value for
P(Xi) = probability of each Rolling two
dice
of the random variable’s possible
values
= summation sign
indicating we are adding all n
possible values
E(X) = expected value or
Expected Value on Television
Deal or No Deal
 Contestant had 5 briefcases left with $100, $400, $1000, $50,000 or
$300,000 in them.
 Expected value of briefcases is
 Banker offered contestant $80,000 to quit. Is it a good or a bad deal?
Why?
Expected Value of a Charitable Raffle
 Cost of raffle ticket is $50
 1000 raffle tickets are sold.
 Winning prize is $25,000
 What is the expected value?
 Is it worth to play the game?
Variance of a Discrete Probability
Distribution
 For rolling two dice
where
X i= random variable’s possible values
E(Xi) = expected value of the random
variable
[Xi – E(X)] = difference between each
value of the random variable and
the expected value
E(X) = probability of each possible value
of the random variable
The Binomial Distribution
 Many business experiments can be characterized by the Bernoulli
process.
 The Bernoulli process is described by the binomial probability
distribution
1. Each trial has only two possible values
2. The probability of each outcome stays the same from one trial to the next
3. The trials are statistically independent
4. The number of trials is a positive integer
The Binomial Distribution
 The binomial distribution is used to find the probability of a specific
number of successes in n trials
We need to know
 The binomial formula is
n = number of trials Probability of r success in n trials
p = the probability of
success on any single
trial
The symbol ! means factorial, and n! =
We let
n(n – 1)(n – 2)…(1)
r = number of successes
q = 1 – p = the probability of a failure 4! = (4)(3)(2)(1) = 24
Also, 1! = 1 and 0! = 1 by definition
Solving Problems with the Binomial
Formula
 Find the probability of getting 4 heads in 5 tosses
of a coin
n = 5, r = 4, p = 0.5, and q = 1 – 0.5 = 0.5
P(4 success in
5 trials)

Excel function:
=BINOM.DIST(number_s, trials, probability_s, cumulative)
If cumulative = TRUE :> function will provide cumulative probabilities;
otherwise the probability mass function, f(x).
Solving Problems with Excel
 Suppose 10 individuals receive a telemarking promotion. Each
individual has a 0.2 probability of making a purchase. Find the
probability that exactly 3 of the 10 individuals make a purchase.
n= ,p= , and r =
 MSA Electronics is experimenting with the manufacture of a new
transistor
 Every hour a random sample of 5 transistors is taken
 The probability of one transistor being defective is 0.15
 What is the probability of finding 3, 4, or 5 defective?
n = , p = , and r =
The Poisson Distribution
 A discrete probability distribution
• Often used in queuing models to describe arrival rates over time
• Probability function given by

where

P(X) = probability of exactly X arrivals or occurrences


= average number of arrivals per unit of time (the mean arrival rate)
e= 2.718, the base of natural logarithms
X= number of occurrences (0, 1, 2, 3, …)
Computing Poisson Probabilities
 Suppose the average number of customers arriving at a Subway
restaurant during lunch hour is λ =12 per hour.
 The probability that exactly x customers arrive during the hour is
given by the Poisson distribution with a mean of 12.

 Excel function: =POISSON.DIST(x, mean, cumulative)


Probability Distribution of a
Continuous Random Variable
 A probability density function is a mathematical function that
characterizes a continuous random variable.
 Properties
• f(x) ≥ 0 for all values of x
• Total area under the density function equals 1.
• P(X = x) = 0
• Probabilities are only defined over intervals.
• P(a ≤ X ≤ b) is the area under the density function between a and b.
Normal Distribution
 f(x) is a bell-shaped curve
 Characterized by 2 parameters:
 (mean)
 (standard deviation)
 Properties
1. Symmetric
2. Mean = Median = Mode
3. Range of X is unbounded
4. Empirical rules apply
Computing Normal Probabilities
 Excel function:
=NORM.DIST(x, mean, standard_deviation, cumulative).
• NORM.DIST(x, mean, standard_deviation, TRUE) calculates the cumulative probability
• If cumulative is set to FALSE, the function simply calculates the value of the density function
f(x), which has little practical application.
Using the NORM.DIST Function to Compute
Normal Probabilities
 The distribution for customer demand (units per month) is normal
with mean = 750 and standard deviation = 100
 Find the probability that demand will be:
1. at most 900 units/month
2. exceed 700 units/month
3. be between 700 and 900 units/month
Questions 1 and 2
 Probability that demand will be  Probability that demand will exceed
at most 900 units, or P(X ≤ 900): 700 units, or P(X > 700).
=1-NORM.DIST(700,750,100,TRUE) = 1 -
=NORM.DIST(900,750,100,TRUE) 0.3085 = 0.6915
= 0.9332.
Question 3
 Probability that demand will be
between 700 and 900, or P(700 <
X < 900):
=NORM.DIST(900,750,100,TRUE) -
NORM.DIST(700,750,100,TRUE)
=0.9332 - 0.3085 = 0.6247
The Normal Inverse
 Normal Inverse function: =NORM.INV(probability, mean, stdev)
provides the x value with F(x) = probability
 What level of demand would be exceeded at most 10% of the time?
 Find x such that F(x) = 0.90:
= NORM.INV(0.90, 750, 100) = 878.155
Exponential Distribution
 Models the time between randomly occurring events
 Density function:

 Cumulative distribution function:

 Mean = m = 1/l
 Excel function:
• =EXPON.DIST(x, lambda, cumulative)
If the number of events occurring
during an interval of time has a
Poisson distribution, then the time
between events is exponentially
distributed.
Using the Exponential Distribution
 The mean time to failure of a critical engine
component is µ = 8,000 hours. What is the
probability of failing before 5000 hours?
 P(X < x) =EXPON.DIST(x, lambda,
cumulative)
 λ = 1/8000
 P(X < 5000) =EXPON.DIST(5000, 1/8000,
TRUE)
= 0.4647
Data Modeling and Distribution Fitting
 Using sample data may limit our ability to predict uncertain events that may occur
because potential values outside the range of the sample data are not included.
 “Fitting” a theoretical distribution to the data and verifying the goodness of fit
statistically.
• Examine a histogram for clues about the distribution’s shape
• Look at summary statistics such as the mean, median, standard deviation, coefficient of
variation, and skewness
 Analytically fit the data to the best type of probability distribution.
 Three statistics measure goodness of fit:
• Chi-square
• Kolmogorov-Smirnov
• Anderson-Darling
Chi-Square Goodness of Fit
Test
Chi-Square Goodness of Fit Test
• Example: A researcher claims that the distribution of favorite pizza toppings among teenagers is
as shown below.

Each outcome is Topping Frequency, f The probability for


classified into Cheese 41% each possible
categories. Pepperoni 25% outcome is fixed.
Sausage 15%
Mushrooms 10%
Onions 9%

A Chi-Square Goodness-of-Fit Test is used to test whether a


frequency distribution fits an expected distribution.
Chi-Square Goodness-of-Fit Test
 To calculate the test statistic for the chi-square goodness-of-fit test, the
observed frequencies and the expected frequencies are used.
 The observed frequency O of a category is the frequency for the
category observed in the sample data.
 The expected frequency E of a category is the calculated frequency for
the category.
• Expected frequencies are obtained assuming the specified (or hypothesized)
distribution. The expected frequency for the ith category is
Ei = npi
where n is the number of trials (the sample size) and pi is the assumed probability
of the ith category.
Chi-Square Goodness-of-Fit Test
For the chi-square goodness-of-fit test to be used, the following must be true.
1. The observed frequencies must be obtained by using a random sample.
2. Each expected frequency must be greater than or equal to 5.
The Chi-Square Goodness-of-Fit Test
If the conditions listed above are satisfied, then the sampling distribution for the
goodness-of-fit test is approximated by a chi-square distribution with k – 1
degrees of freedom, where k is the number of categories. The test statistic for the
chi-square goodness-of-fit test is

2 (O  E )2 The test is always a right-


χ 
where O represents the observed
E frequency tailed test.
of each category and E represents the
expected frequency of each category.
Chi-Square Goodness-of-Fit Test
Performing a Chi-Square Goodness-of-Fit Test
1. Identify the claim. State the null and alternative hypotheses. State H0 and Ha.
2. Specify the level of significance.

3. Identify the degrees of freedom. d.f. = k – 1

4. Determine the critical value.

5. Determine the rejection region.


If χ2 is in the rejection
6. Calculate the test statistic. 2 (O  E )2 region, reject H0.
χ 
7. Make a decision to reject or fail to reject theEnull hypothesis. Otherwise, fail to
8. Interpret the decision in the context of the original claim. reject H0.
Chi-Square Goodness-of-Fit Test
Example:
A researcher claims that the distribution of favorite pizza toppings among teenagers
is as shown below (Column 1). 200 randomly selected teenagers are surveyed, and
results are presented in column 2.
% of Resu lt s E xpect ed
Toppin g
t een a ger s (n = 200) F r equ en cy
Ch eese 41% 78 82
P epper on i 25% 52 50
Sa u sa ge 15% 30 30
Mu sh r oom s 10% 25 20
On ion s 9% 15 18
Using  = 0.01, and the observed and expected values indicated in the table,
test the surveyor’s claim using a chi-square goodness-of-fit test.
Chi-Square Goodness-of-Fit Test
Example continued:
H0: The distribution of pizza toppings is 41% cheese, 25% pepperoni, 15%
sausage, 10% mushrooms, and 9% onions. (Claim)
Ha: The distribution of pizza toppings differs from the claimed or expected
distribution.
Because there are 5 categories, the chi-square distribution has k – 1 = 5
– 1 = 4 degrees of freedom.

With d.f. = 4 and  = 0.01, the critical value is χ20 = 13.277 =CHISQ.INV.RT(, df)
Chi-Square Goodness-of-Fit Test
Example continued:
Topping Observed Expected
Rejection Frequency Frequency
region
Cheese 78 82
  0.01 Pepperoni 52 50
Sausage 30 30
X2 Mushrooms 25 20
χ20 = 13.277 Onions 15 18

2 (O  E )2 (78  82)2 (52  50)2 (30  30)2 (25  20)2 (15  18)2
χ      
E 82 50 30 20 18
 2.025
Fail to reject H0.
There is not enough evidence at the 1% level to reject the surveyor’s claim.
Chi-Square Goodness of Fit Test

 See handouts on Chi-Square Distribution and Notes p. 229-237

You might also like