Download Baye`s Theorem - PatrickDooleyDHS

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

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

Document related concepts
no text concepts found
Transcript
Baye’s Theorem
Working with Conditional
Probabilities
Drug Testing
• Suppose it is assumed that about 5% of the
population uses drugs. A drug test that is given to
employees of a certain company is 95%
accurate; that is, it correctly labels a drug user
95% of the time and correctly labels a nonuser
95% of the time. If a random employee takes the
drug test and tests positive, what is the
probability that he/she is a drug user?
Baye’s Theorem
1) P(A and B) = P(A) * P(B | A)
2) P(B and A) = P(B) * P(A | B)
Since the P(A and B) is the same as the P(B and A),
we can equate statements 1 and 2
3) P(A) * P(B | A) = P(B) * P(A | B)
Divide both sides by P(A) to get
P( B)  P( A | B)
4) P( B | A) 
P( A)
Solution to Drug Problem
Let A = event that a person tests positive on the drug test
Let B = event that a person is a drug user
We are looking for the probability that a person
is a drug user given that their test turned out positive.
P(drug user | positive test result) =
P(drug user )  P(positive test result | drug user )
P(positive test result )
P(drug user) = 0.05
P(positive test result | drug user) = 0.95
P(positive test result) =
P(positive test result and drug user) +
0.95*0.05
P(positive test result and nonuser)
0.05*0.95
given in problem
given in problem
= 0.095
0.05  0.95
 0.5
P(drug user | positive test result) =
0.05  0.95  0.95  0.05
Another Method
P(drug user | Test positive) =
475
 0.5
950
Test Positive
result
Negative
Drug Status
Drug
User
Non User
0.95*500
= 475
475
950
25
0.95*9500 9050
= 9025
500
9500
10000
Positive
Test
0.95
Drug user
0.05
0.95
Non-Drug
user
0.05*0.095 = 0.0475
0.05
Negative
Test
Positive
Test
Negative
Test
0.05*0.05 = 0.0025
0.95*0.05 = 0.0475
0.05
0.95
0.95*0.95 = 0.9025
Related documents