37
1 Probability Probability Distributions for Distributions for Discrete Variables Discrete Variables Farrokh Alemi Ph.D. Farrokh Alemi Ph.D. Professor of Health Administration and Policy Professor of Health Administration and Policy College of Health and Human Services, George Mason College of Health and Human Services, George Mason University University 4400 University Drive, Fairfax, Virginia 22030 4400 University Drive, Fairfax, Virginia 22030 703 993 1929 703 993 1929 [email protected] [email protected]

1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

Embed Size (px)

Citation preview

Page 1: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

11

Probability Distributions Probability Distributions for Discrete Variablesfor Discrete Variables

Farrokh Alemi Ph.D.Farrokh Alemi Ph.D.Professor of Health Administration and PolicyProfessor of Health Administration and Policy

College of Health and Human Services, George Mason UniversityCollege of Health and Human Services, George Mason University4400 University Drive, Fairfax, Virginia 220304400 University Drive, Fairfax, Virginia 22030

703 993 1929 703 993 1929 [email protected]@gmu.edu

Page 2: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

22

Lecture OutlineLecture Outline

1.1. What is probability?What is probability?

2.2. Discrete Probability DistributionsDiscrete Probability Distributions

3.3. Assessment of rare probabilitiesAssessment of rare probabilities

4.4. Conditional independence Conditional independence

5.5. Causal modelingCausal modeling

6.6. Case based learningCase based learning

7.7. Validation of risk modelsValidation of risk models

8.8. Examples Examples

Page 3: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

33

Lecture OutlineLecture Outline

1.1. What is probability?What is probability?2.2. Discrete Probability DistributionsDiscrete Probability Distributions

BernoulliBernoulli GeometricGeometric BinomialBinomial PoissonPoisson

3.3. Assessment of rare probabilitiesAssessment of rare probabilities4.4. Conditional independence Conditional independence 5.5. Causal modelingCausal modeling6.6. Case based learningCase based learning7.7. Validation of risk modelsValidation of risk models8.8. Examples Examples

Page 4: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

44

DefinitionsDefinitions

FunctionFunction Density functionDensity function Distribution functionDistribution function

Page 5: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

55

DefinitionsDefinitions

Events

Probability density function

Cumulative distribution

function

0 medication errors 0.90 0.90

1 medication error 0.06 0.96

2 medication errors 0.04 1

Otherwise 0 1

Page 6: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

66

Expected ValueExpected Value

Probability density function can Probability density function can be used to calculate expected be used to calculate expected value for an uncertain event.value for an uncertain event.

n iixpxE 1 )()(

Expected Value

for variable X

Pro

babi

lity

of

even

t “i”

Value of event “i”

Summed over all

possible events

Page 7: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

77

Calculation of Expected Value Calculation of Expected Value from Density Functionfrom Density Function

Events

Probability density function

Value times probability

0 medication errors 0.90 0*(0.90)=0

1 medication error 0.06

2 medication errors 0.04

Otherwise 0

n iixpxE 1 )()(

Page 8: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

88

Calculation of Expected Value Calculation of Expected Value from Density Functionfrom Density Function

Events

Probability density function

Value times probability

0 medication errors 0.90 0*(0.90)=0

1 medication error 0.06 0.06

2 medication errors 0.04 0.08

Otherwise 0 0

Page 9: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

99

Calculation of Expected Value Calculation of Expected Value from Density Functionfrom Density Function

Events

Probability density function

Value times probability

0 medication errors 0.90 0

1 medication error 0.06 0.06

2 medication errors 0.04 0.08

Otherwise 0 0

Total 0.12

Expected

medication

errors

Page 10: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1010

ExerciseExercise

Chart the density and distribution Chart the density and distribution functions of the following data for functions of the following data for patients with specific number of patients with specific number of medication errors & calculate medication errors & calculate expected number of medication expected number of medication errorserrors

10Otherwise

10.042 medication errors

0.960.221 medication error

0.740.740 medication errors

Cumulative distribution

function

Probability density functionEvents

10Otherwise

10.042 medication errors

0.960.221 medication error

0.740.740 medication errors

Cumulative distribution

function

Probability density functionEvents

Page 11: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1111

Probability Density & Cumulative Probability Density & Cumulative Distribution FunctionsDistribution Functions

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

0 errors 1 error 2 errors Otherwise

Probability densityfunction

Cumulative distribution function

Page 12: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1212

ExerciseExercise

If the chances of medication If the chances of medication errors among our patients is 1 in errors among our patients is 1 in 250, how many medication 250, how many medication errors will occur over 7500 errors will occur over 7500 patients? Show the density and patients? Show the density and cumulative probability functions.cumulative probability functions.

Page 13: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1313

Typical Probability Density Typical Probability Density FunctionsFunctions

BernoulliBernoulli BinomialBinomial GeometricGeometric PoissonPoisson

Page 14: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1414

Bernoulli Probability Density Bernoulli Probability Density FunctionFunction Mutually Mutually

exclusiveexclusive ExhaustiveExhaustive Occurs with Occurs with

probability of pprobability of p

pOccurs

1-PDoes not occur

Probability density functionEvents

pOccurs

1-PDoes not occur

Probability density functionEvents

Daily Probability of Elopment

00.10.20.30.40.50.60.70.80.9

1

None Elopment

Density function Cumulative distribution

Page 15: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1515

ExerciseExercise

If a nursing home takes care of 350 If a nursing home takes care of 350 patients, how many patients will patients, how many patients will elope in a day if the daily probability elope in a day if the daily probability of elopement is 0.05?of elopement is 0.05?

Daily Probability of Elopment

00.10.20.30.40.50.60.70.80.9

1

None Elopement

Density function Cumulative distribution

Page 16: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1616

Independent Repeated Independent Repeated Bernoulli TrialsBernoulli Trials Independence means that the Independence means that the

probability of occurrence does not probability of occurrence does not change based on what has change based on what has happened in the previous dayhappened in the previous day

Patient elopes

No event

Patient elopes

No event

Patient elopes

No event

Day 1 Day 2 Day 3

Page 17: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1717

Geometric Probability Density Geometric Probability Density FunctionFunction

Number of trials till first Number of trials till first occurrence of a repeating occurrence of a repeating independent Bernoulli eventindependent Bernoulli event

ppkf k 1)1()( K-1

non

-

occu

rrenc

e of

the

even

t

occurrence of

the event

Page 18: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1818

Geometric Probability Density Geometric Probability Density FunctionFunction

Expected number of trials prior Expected number of trials prior to occurrence of the eventto occurrence of the event

ptrialsE

1)(

)(1trialsE

p

2

1)(

pp

trialsVariance

Page 19: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

1919

ExerciseExercise

No medication errors have No medication errors have occurred in the past 90 days. occurred in the past 90 days. What is the daily probability of What is the daily probability of medication error in our facility?medication error in our facility?

The time between patient falls The time between patient falls was calculated to be 3 days, 60 was calculated to be 3 days, 60 days and 15 days. What is the days and 15 days. What is the daily probability of patient falls?daily probability of patient falls?

Page 20: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2020

Binomial Probability Binomial Probability DistributionDistribution

Independent repeated Bernoulli Independent repeated Bernoulli trialstrials

Number of k occurrences of the Number of k occurrences of the event in n trialsevent in n trials

Page 21: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2121

Repeated Independent Repeated Independent Bernoulli TrialsBernoulli Trials

Probability of exactly two elopement in 3 days

On day 1 and 2 not 3 p p (1-p)

On day 1 not 2 and 3 p (1-p) p

On day 2 3 and not 1 P p (1-p)

Patient elopes

No event

Patient elopes

No event

Patient elopes

No event

Day 1 Day 2 Day 3

Patient elopes

No event

Patient elopes

No event

Patient elopes

No event

Patient elopes

No event

Patient elopes

No event

Patient elopes

No event

Day 1 Day 2 Day 3

Page 22: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2222

Binomial Probability Binomial Probability DistributionDistribution

knk ppknk

nkf

)1(

)!(!!

)(

Possible ways of getting

k occurrences in n tria

ls

n! is n factorial and is calculated as

1*2*3*…*n

Page 23: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2323

Binomial Probability Binomial Probability DistributionDistribution

knk ppknk

nkf

)1(

)!(!!

)(k occurrences of

the even

Possible ways of getting

k occurrences in n tria

ls

Page 24: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2424

Binomial Probability Binomial Probability DistributionDistribution

knk ppknk

nkf

)1(

)!(!!

)(

n-k

non-

occu

rren

ce o

f

the

even

t

k occurrences of

the even

Possible ways of getting

k occurrences in n tria

ls

Page 25: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2525

Binomial Density Function for Binomial Density Function for 6 Trials, p=1/26 Trials, p=1/2

0.000

0.050

0.100

0.150

0.200

0.250

0.300

0.350

0 1 2 3 4 5 6

Number of occurences of the event

Pro

ba

bili

ty

The expected value of a Binomial distribution is np. The variance is np(1-p)

Page 26: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2626

Binomial Density Function for Binomial Density Function for 6 Trials, p=0.056 Trials, p=0.05

0.000

0.100

0.200

0.300

0.400

0.500

0.600

0.700

0.800

0 1 2 3 4 5 6

Number of occurences of the event

Pro

ba

bili

ty

Page 27: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2727

ExerciseExercise

If the daily probability of elopement is If the daily probability of elopement is 0.05, how many patients will elope in 0.05, how many patients will elope in a year? a year?

Daily Probability of Elopment

00.10.20.30.40.50.60.70.80.9

1

None Elopement

Density function Cumulative distribution

Page 28: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2828

ExerciseExercise

If the daily probability of death due to injury If the daily probability of death due to injury from a ventilation machine is 0.002, what is from a ventilation machine is 0.002, what is the probability of having 1 or more deaths the probability of having 1 or more deaths in 30 days? What is the probability of 1 or in 30 days? What is the probability of 1 or more deaths in 4 months?more deaths in 4 months?

Number of trials = 30

Daily probability = 0.002

Number of deaths = 0

Probability of 0 deaths = 0.942

Probability of 1 or more deaths= 0.058

Page 29: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

2929

ExerciseExercise

If the daily probability of death due to injury If the daily probability of death due to injury from a ventilation machine is 0.002, what is from a ventilation machine is 0.002, what is the probability of having 1 or more deaths the probability of having 1 or more deaths in 30 days? What is the probability of 1 or in 30 days? What is the probability of 1 or more deaths in 4 months?more deaths in 4 months?

Number of trials = 30

Daily probability = 0.002

Number of deaths = 0

Probability of 0 deaths = 0.942

Probability of 1 or more deaths= 0.058

Page 30: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3030

ExerciseExercise

Which is more likely, 2 patients Which is more likely, 2 patients failing to comply with medication failing to comply with medication orders in 15 days or 4 patients orders in 15 days or 4 patients failing to comply with medication failing to comply with medication orders in 30 days.orders in 30 days.

Page 31: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3131

Poisson Density FunctionPoisson Density Function

Approximates Binomial Approximates Binomial distributiondistribution Large number of trialsLarge number of trials Small probabilities of occurrenceSmall probabilities of occurrence

Page 32: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3232

Poisson Density FunctionPoisson Density Function

!)(

ke

kfk

Λ is the expected number of trials = n pk is the number of occurrences of the sentinel event

e = 2.71828, the base of natural logarithms

Page 33: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3333

ExerciseExercise

What is the probability of What is the probability of observing one or more security observing one or more security violations. when the daily violations. when the daily probability of violations is 5% probability of violations is 5% and we are monitoring the and we are monitoring the organization for 4 monthsorganization for 4 months

What is the probability of What is the probability of observing exactly 3 violations in observing exactly 3 violations in this period?this period?

Page 34: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3434

Take Home LessonTake Home Lesson

Repeated independent Bernoulli trials Repeated independent Bernoulli trials is the foundation of many distributionsis the foundation of many distributions

Page 35: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3535

ExerciseExercise

What is the daily probability of What is the daily probability of relapse into poor eating habits relapse into poor eating habits when the patient has not when the patient has not followed her diet on January 1followed her diet on January 1stst, , May 30May 30thth and June 7 and June 7thth? ?

What is the daily probability of What is the daily probability of security violations when there security violations when there has not been a security violation has not been a security violation for 6 months?for 6 months?

Page 36: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3636

ExerciseExercise

How many visits will it take to How many visits will it take to have at least one medication have at least one medication error if the estimated probability error if the estimated probability of medication error in a visit is of medication error in a visit is 0.03?0.03?

If viruses infect computers at a If viruses infect computers at a rate of 1 every 10 days, what is rate of 1 every 10 days, what is the probability of having 2 the probability of having 2 computers infected in 10 days?computers infected in 10 days?

Page 37: 1 Probability Distributions for Discrete Variables Farrokh Alemi Ph.D. Professor of Health Administration and Policy College of Health and Human Services,

3737

ExerciseExercise

Assess the probability of a Assess the probability of a sentinel event by interviewing a sentinel event by interviewing a peer student. Assess the time peer student. Assess the time to sentinel event by interviewing to sentinel event by interviewing the same person. Are the two the same person. Are the two responses consistent?responses consistent?