You claim that P(B|A) = 0.21, P(A) = 0.07, and P(B) = 0.01. But that can’t actually be true! Because P(B) = P(B|A)P(A) + P(B|¬A)P(¬A), and if what you say is true, then P(B|A)P(A) = (0.21)(0.07) = 0.0147, which is bigger than 0.01. So because P(B|¬A)P(¬A) can’t be negative, P(B) also has to be bigger than 0.01. But you said it was 0.01! Stop lying!
I’m trying out Bayes Theorem with a simple example and getting really strange results.
p(disease A given that a patient has disease B) = p(b|a)p(a) / p(b)
p(disease B given existing diagnosis of disease A) = 0.21
p(A) = 0.07
p(B) = 0.01
I get 1.47 or 147%. I know that the answer can’t be >=100% because there are patients with A and not B.
Where am I going wrong?
The problem is that you’re lying!
You claim that P(B|A) = 0.21, P(A) = 0.07, and P(B) = 0.01. But that can’t actually be true! Because P(B) = P(B|A)P(A) + P(B|¬A)P(¬A), and if what you say is true, then P(B|A)P(A) = (0.21)(0.07) = 0.0147, which is bigger than 0.01. So because P(B|¬A)P(¬A) can’t be negative, P(B) also has to be bigger than 0.01. But you said it was 0.01! Stop lying!
Wow, that’s a bit strongly worded.
I’m going to have to figure out why the journal article gave those figures. Maybe I should send your comment to the authors...
(I thought the playful intent would be inferred from lying-accusations being incongruous with the genre of math help. Curious what article this was?)
FWIW, I have run into similar problems before, and I still don’t have a good intuition about it.