So to rephrases the question:

P(question right | you know Bayes’ rule) = … by Bayes’ Rule

P ( you know Bayes’ rule | question right ) P ( question right ) / P ( you know Bayes’ rule)

That’s kind of confusing.

What struck me was how interesting it is how our intuitions about probability can be so wrong. For example, take this question, or riddle:

If you a have a test that is 99% accurate for detecting swine flu (if you have swine, it will return positive 99% of the time) and only 1% of the population has swine flu, what is the probability that you actually have swine flu given that you test positive? (Stop to think for a second before you answer.)

Most people will probably say 99%, because the test was 99% accurate. But what that really means is that the test will return a positive result 99% of the time if you have swine flu P ( + | swine ) = .99 — but this is not the same as the question we are asking; namely what is the probability that you have swine flu given that you test positive, or P ( swine | + ).

This confusion is a result of many types of confusion with probability that are all related, the conditional probability fallacy, the confusion of the inverse, the base rate fallacy, and a related riddle, the Monty Hall Problem. See Bayes theorem for a more technical analysis.

But the answer is not 99%. It is 50%. Bizarre. So why is this?

Take this numerical example to help illustrate. Say you have a town of 101 people, where 100 of them are perfectly healthy and 1 of them has the swine. Ok.

The question still remains: What is the probability that you have the swine given you test positive? Or what is P ( swine | + ) ?

According to Bayes’ rule that is P (+| swine)P(swine) / P (+).

What that is really saying is that the probability you have swine given you test positive is the ratio of all the people who actually have the swine and tested positive over all the people who tested positive.

So lets go back to the numerical example.

1 person had swine and they tested positive.

1 person had a false positive–out of the 100 healthy people there was a 1% error rate.

So we had 1 TRUE positive / 2 TOTAL positives or 50%!

The confusion here is several-fold. It is very hard to keep conditional probabilities separate from their inverse. It is even more confusing when you think about the difference in probabilities of the events. One error is that we forget to take into account how rare the swine was in the first place (in the example, only 1% had it). So even if we tested positive, since there were so many more people who didn’t have it, there will be a rather large number of false positives because the test is only 99% accurate.

It’s very interesting, and very non-intuitive. Many doctors presented with this problem get it very wrong!

Let me know if this is interesting to you, clarifies the topic, or confuses it.

I just read this post really slowly and its making more sense now.

Haha this is great; Mehran totally talked about this in lecture yesterday. Great foresight.