Conditional probability

Written by Eliezer Yudkowsky, Nate Soares last updated
Requires: Math 1

The conditional probability means "The probability of given ." That is, means "The probability that is true, assuming that is true."

is the probability that a banana is yellow - if we know something to be a banana, what is the probability that it is yellow?

is the probability that a yellow thing is a banana - if the right side is known to be , then we ask the question on the left, what is the probability that this is a ?

Definition

To obtain the probability we constrain our attention to only cases where is true, and ask about cases within where is also true.

Let denote " and " or " and are both true". Then:

We can see this as a kind of "zooming in" on only the cases where is true, and asking, within this universe, for the cases where and are true.

Example 1

Suppose you have a bag containing objects that are either red or blue, and either square or round, where the number of each is given by the following table:

If you reach in and feel a round object, the conditional probability that it is red is given in by zooming in on only the round objects, and asking about the frequency of objects that are round and red inside this zoomed-in view:

If you look at the object nearest the top, and can see that it's blue, but not see the shape, then the conditional probability that it's a square is:

conditional probabilities bag

Example 2

Suppose you're Sherlock Holmes investigating a case in which a red hair was left at the scene of the crime.

The Scotland Yard detective says, "Aha! Then it's Miss Scarlet. She has red hair, so if she was the murderer she almost certainly would have left a red hair there. let's say, which is a near-certain conviction, so we're done."

"But no," replies Sherlock Holmes. "You see, but you do not correctly track the meaning of the conditional probabilities, detective. The knowledge we require for a conviction is not the chance that Miss Scarlet would leave a red hair, but rather the chance that this red hair was left by Scarlet. There are other people in this city who have red hair."

"So you're saying..." the detective said slowly, "that is actually much lower than ?"

"No, detective. I am saying that just because is high does not imply that is high. It is the latter probability in which we are interested - the degree to which, knowing that a red hair was left at the scene, we infer that Miss Scarlet was the murderer. This is not the same quantity as the degree to which, assuming Miss Scarlet was the murderer, we would guess that she might leave a red hair."

"But surely," said the detective, "these two probabilities cannot be entirely unrelated?"

"Ah, well, for that, you must read up on Bayes' rule."

Example 3

"Even if most Dark Wizards are from Slytherin, very few Slytherins are Dark Wizards. There aren't all that many Dark Wizards, so not all Slytherins can be one."

"So yeh're saying, that most Dark Wizards are Slytherins... but..."

"But most Slytherins are not Dark Wizards."

Harry Potter and the Methods of Rationality, Ch. 100