## anonymous one year ago I need someone to explain this to me, I really don't understand... Using Baye's Theorem: It is known that 2% of the population has a certain allergy. A test correctly identifies people who have the allergy 98% of the time. The test correctly identifies people who do not have the allergy 94% of the time. A doctor decides that anyone who tests positive for the allergy should begin taking anti-allergy medication. Do you think this is a good decision? Why or why not? I know it's pretty long and a little bit of reading but it's on paper so I had to copy it, I wouldn't have if I didn't need the

• This Question is Open
1. anonymous

this is often very confusing one good way to approach this is to use some actual numbers and see what happens

2. anonymous

it makes "baye's theorem" far more undersantable

3. anonymous

Okay but how do I choose my numbers?

4. anonymous

i would pick a large number for the population, so that we get all whole number answers (although once we get the answer, we can redo it without using that crutch) lets say the population is 1000 people ok?

5. anonymous

okay

6. anonymous

and if 2% of the population suffers from the allergies, how many people exactly will have it? i.e what is 2% of 1000 ?

7. anonymous

Umm...40? I'm not sure I did this right

8. anonymous

yes that is right

9. anonymous

oops sorry that is wrong

10. anonymous

dang it

11. anonymous

2% of 1,000 is $$.02\times 1000=20$$

12. anonymous

that is why i picked a nice round number like 1000 so the it would be easy to compute the percents

13. anonymous

That what I did but my calculator said i was 40...oh well what do I have to do next?

14. anonymous

ok so 20 people have the allergy, how many do not?

15. anonymous

By the way that already helps a lot

16. anonymous

20 out of 1000 which is... 20/10000=0.2%?

17. anonymous

hold on i think i have confused you

18. anonymous

we have a population of 1,000 2% have the allergy, so 20 have the allergy if out of 1,000 people, 20 have the allergy, how many (not what percent) do not have the allergy

19. anonymous

ooooh, sorry with the 10000 I got confused with another problem on my paper sorry. Umm so 980 don't have the allergy?

20. anonymous

right

21. anonymous

so we know how many have it, and how many do not now lets see how many people will test positive for it

22. anonymous

of the 20 people that have it, the test is 98% accurate what is 98% of 20?

23. anonymous

btw i hope it is clear that you do $$.98\times 20$$

24. anonymous

19.6?

25. anonymous

right

26. anonymous

yeah I'm good with the percentage....most of the time

27. anonymous

i guess we have to work with the decimal, should have chosen a population of 10,000 then it would be whole numbers but too late now

28. anonymous

now we know $$980$$ so NOT have the allergy, lets see how many of those will also test positive

29. anonymous

for them the test is 96% accurate so 96% of them will test negative, but that means 6% of them will test positive what is 6% of 980?

30. anonymous

31. anonymous

4% will test positive what is 4% of 980

32. anonymous

39.2?

33. anonymous

yeah i get that too

34. anonymous

ok so now how many people total (it is a decimal) will test positive?

35. anonymous

0.04 people? I'm confused

36. anonymous

we computed two numbers of people that test positive right? the ones with the allergy, 19.6 and the ones without the allergy, 39.2 what is the total?

37. anonymous

oh, 58.8?

38. anonymous

right, that is the total number that test positive

39. anonymous

out of those, we know that 19.6 actually have the allergy

40. anonymous

okay

41. anonymous

so the question is, IF you test positive, what is the probabilty you actually have the allergy that is the number of people who test positive and have the allergy, divided by the total number of people who test postive ie$\frac{ 19.6}{58.8}$

42. anonymous

or whatever you get when you write that as a decimal, i get $$0.337$$ rounded, a little more than a third

43. anonymous

okay I get 0.33333etc.

44. anonymous

oh maybe i put the wrong numbers in yeah you are right

45. anonymous

one third in other words

46. anonymous

would you like to redo this using "baye's formula" ? will will do pretty much the same arithmetic, and get the same answer

47. anonymous

yeah, it would help a lot, my teacher just throws a formula and exercises at us

48. anonymous

ok do you have the formula you are supposed to use? i can make a guess if you like

49. anonymous

yeah I have it

50. anonymous

go ahead and write it, we can walk through it slowly

51. anonymous

It's $P(A|B)=\frac{P(A|B)*P(A)}{ P(B)}$

52. anonymous

ok good

53. anonymous

I have it right in front of me

54. anonymous

first off, it this is going to make sense, you need to know what $$P(A|B)$$ means do you know what it means?

55. anonymous

oh crap your definition is wrong, but we will get to that in a second

56. anonymous

It means probability of A given B

57. anonymous

ok good

58. anonymous

and the definition (not baye's theorem) is $P(A|B)=\frac{P(A\cap B)}{P(B)}$

59. anonymous

My teacher made us study about a formula like that, but I really didn't get a thing

60. anonymous

baye's theorem, at least one form, is not quite what you wrote, the condition is switched on the right it is $P(A|B)=\frac{P(B|A)*P(A)}{ P(B)}$

61. anonymous

ok lets see if we can get it

62. anonymous

oh yeah my mistake

63. anonymous

ok now the numerator in your fraction $P(B|A)P(A)$ is just another way to find $$P(A\cap B)$$ the probability that both A and B occur

64. anonymous

That's where I get extremely confused

65. anonymous

lets use our example you want the probability you have the allergy GIVEN you test positive

66. anonymous

okay

67. anonymous

we can put A = you have the allergy, B = you test positive then we are trying to find $$P(A|B)$$ the probability you have the allergy given that you test positive

68. anonymous

let me know if i lost you, we need to go slow i am sure

69. anonymous

okay so far I think I'm okay...I think so for now

70. anonymous

ok to compute that we need the numerator $$P(A\cap B)$$ i.e. the probability you have it AND test positive we were not told that number

71. anonymous

so far so good

72. anonymous

but we were told $$P(B)$$ the probabily you have the disease, that was $$2\%=0.02$$

73. anonymous

okay

74. anonymous

and we were also told $$P(B|A)$$ the probability you have the disease given that you test positive that was the $$98\%=0.98$$

75. anonymous

to find the numerator, multiply those together, i.e. the probability you have the disease AND test positive is the probability you have the disease times the probability you test positive GIVEN that you have the disease, i.e. $.02\times.98=.0196$

76. anonymous

you notice that is the same numerator we had before, just with the decimal moved over three places, because we did not start out with a population of 1,000 we just went straight for the number

77. anonymous

so far so good?

78. anonymous

Wait why did you change the 98% to a decimal. to make it easier to work with?

79. anonymous

when doing any work in math, you use numbers, not percents $$98\%=0.98$$ as a number percents are nice to look at, but think about what you did when you wanted to find 98% of 20 you multiplied 20 by .98 right, not by 98

80. anonymous

81. anonymous

okay

82. anonymous

that is $$P(B)$$ the probability you test positive remember how we found that before? we had to add two numbers, they were $$19.6$$ and $$39.2$$ they will be the same this time, but with the decimal in a different place

83. anonymous

the fist one is the $$.00196$$ we already found, that is the number of people who test positive given that they have the disease

84. anonymous

so you divided it by 1000 right?

85. anonymous

we also need the number of people who test positive who do NOT have the disease

86. anonymous

well, yes, but we just found again computing $$.02\times .98=.00196$$

87. anonymous

to compute the probability that you test positive if you do not have the disease we used $$.04\times .980=.0392$$

88. anonymous

okay

89. anonymous

I'm sorry I really want to learn but I have to go to bed

90. anonymous

now add together to get the probability you test positive, that is $$.00196+.00392=.00588$$

91. anonymous

you did help a lot already though I'll make sure I have a lot of time next time I ask a question though

92. anonymous

yeah it is late you can look at this later and see that we are really using the same numbers as before

93. anonymous

okay

94. anonymous

later

95. anonymous

later!