Bayes theorem and conditional probability example.

537 views

Greetings to all.
I started an MSc that includes a course in statistics. Full disclosure: my bachelor’s had no courses of statics and it is in biology.

So, the professor was trying to explain the Bayes theorem and conditional probability through the following example.
“A friend of yours invites you over. He says he has 2 children. When you go over, a child opens the door for you and it is a boy. What is the probability that the other child is a boy as well.”

The math say the probability the other child is a boy is increased the moment we learn that one of the kids is a boy. Which i cannot wrap my head around, assuming that each birth is a separate event (the fact that a boy was born does not affect the result of the other birth), and the result of each birth can be a boy or a girl with 50/50 chance.
I get that “math says so” but… Could someone please explain? thank you

In: 77

24 Answers

Anonymous 0 Comments

Your intuition is right and your professor is wrong. As are most of the people commenting here except /u/nmxt . They are making the same mistake.

Their logic goes : “well there are four *equally probable* initial possibilities. BB, BG, GB, and GG. And a boy answers the door, *eliminating* GG from the possibilities *and doing nothing else*. Therefore you’re left with BB, GB, and BG *of equal probability,* so therefore the other child has a 2/3 chance of being a girl.”

No. Wrong. Bullshit.

Your professor’s problem is the *bad assumption* that a boy answering the door *only alters the probability of the GG possibility*. In reality, it *also* alters the probability of the other 3 possibilities. Your professor is not applying the information gained from the sampling appropriately to all four houses.

Lets take our 3 remaining non-zero probable states, BB, BG, and GB. What is the probability of a boy answering the door at each of these houses? 100%, 50%, and 50%. (and 0% for the GG). If you go to one of these three houses and a boy answers, it is *twice* as likely that we are at a boy-only house than not. However, there are twice as many *kinds* of boy-girl houses. So in the end the odds of the other child being a girl is 0.25*0.5 + 0.25 * 0.5 vs 0.25 * 1. Which is just 0.25 vs 0.25, or 1:1, or 50%.

Let’s write this using Bayes’s law so you can show it to your professor:

>P(A given B) = P(B given A) * P(A) / P(B)

First off, is it correct to eliminate the GG house?

>P(GG|Boy) = P(Boy | GG) * P(GG) / P(Boy) = 0.0 x 0.25 / 0.5 = 0

Yes, the GG house is off the table.

But *we can’t stop there* What we want to know is the probability of *each* house we’re at GIVEN that a boy answered the door.

>P(BG|B) = ?, P(GB|B) = ?, P(BB|B) = ?

Starting with the boy-girl houses:

>P(BG|B) = P(B|BG) * P(BG)/P(B) = 0.5 x 0.25 / 0.5 = 0.25

Probability of the boy answering the door given a BG house, times the probability of a BG house, divided by the probability of a boy. That’s 50% times 25% divided by 50% = 25%. And the answer is identical for the GB house.

>P(BB | B) = P(B | BB) * P(BB) / P(B) = 1.0 x 0.25 / 0.5 = 0.5

Probability of the boy answering the door given a BB house, times the probability of a BB house, divided by the probability of a boy. That’s 100% times 25% divided by 50% = 50%.

So all together our four *weighted* possibilities are:

0.5 + 0.25 + 0.25 + 0.0 = 1.0

And of that 1.0, the chance of a BB house is 50%, and the aggregate chance for houses containing a girl are… 50%.

A boy answering the door has given you an altered probability of what type of house you may be at. But it has *not* altered the overall probability of the sex of the other child.

*Edit* – a key giveaway is that your professor’s scenario altered the probabilities from:
>0.25 + 0.25 + 0.25 + 0.25 -> 0.25 + 0.25 + 0.25 + 0.0

And then had to manually re-normalized by dividing by 0.75 to get
>0.33 + 0.33 + 0.33 + 0.0 = 1

Bayes’s theorem *handles* the re-normalization when correctly applied to all scenarios when given a new piece of information. That’s why I ended up with 0.5 + 0.25 + 0.25 + 0 = 1. If you are manually re-normalizing a sum of probabilities that *used* to add up to 1, then you’ve generally made a mistake and misapplied the theorum.

You are viewing 1 out of 24 answers, click here to view all answers.