8 ms·
Probability Can Bite (2010)
- memming 3y agoThis page has now been taken down. Does anyone know why? Fortunately, I have a copy of the page: April 2010 Probability Can Bite Estimating probabilities can be a tricky business. The long running saga of the notorious Monty Hall Problem shows how even mathematically-smart people can easily be misled. (For my forays into that particular example, see my Devlin's Angle columns for July-August 2003, November 2005, and December 2005.) Another probability question that causes many people difficulty is the children's gender puzzle: I tell you I have two children and that (at least) one of them is a boy, and ask you what you think is the probability that I have two boys. Many people, when they hear this puzzle for the first time, give the answer 1/2, reasoning that there is an equal likelihood that my other child is a boy or a girl. But this is not correct. Based on what you know, you should conclude that I am actually twice as likely to have a boy and a girl as I am to have two boys. So your right answer to my question is not 1/2 but 1/3. Before I explain the answer, I should clear up a confusion that many people have about problems such as this, which are about what is known as epistemic probability. The probability being discussed here is not some unchangable feature of the world, like the probability of throwing a double six with a pair of honest dice. After all, I have already had my two children, and their genders have long been determined. At issue is what probabilities you attach to your knowledge of my family. As is the case with most applications of probability theory outside the casinos, the probability here is a measure of an individual's knowledge of the world, and different people can, and often do, attach different probabilities to the same event. Moreover, as you acquire additional information about an event, the probability you attach to it can change. To go back to the original puzzle now, in order of birth, there are four possible gender combinations for my children: BB, GG, BG, GB. Each is equally likely. (To avoid niggling complications, I'm assuming each gender is equally likely at birth, and ignore the possibility of identical twins, etc.) So, if all I told you was that I have two children, you would (if you are acting rationally) say that the probability I have two boys is 1/4. But I tell you something else: that at least one of my children is a boy. That eliminates the GG possibility. So now you know the possible gender combinations are BB, BG, GB. Of these three possibilities, in two of them I have a boy and a girl, and in only one do I have two boys, so you should calculate the probability of my having two boys to be 1 out of 3, namely 1/3. If you haven't come across this before, it might take you some time to convince yourself this reasoning is correct. I long ago got past that stage, and hence felt my intuitions would be pretty reliable when I recently came across the following variant of the puzzle. I tell you I have two children, and (at least) one of them is a boy born on a Tuesday. What probability should you assign to the event that I have two boys? Before you read further, you should perhaps pause and try to figure this out for yourself. My initial reaction was that the information about the Tuesday was irrelevant, since at issue was gender, not day of birth. In which case, this was the same problem as the one I just described, and the answer would be 1/3. But then I began to have second thoughts. I admit my doubts were occasioned by the way I came across the problem: a Twitter feed by the well-known mathematician John Allan Paulos, forwarding a Tweet from the (British) Guardian newspaper science-writer Alex Bellos, who was reporting on the posing of this problem at the recent "Gathering for Gardner" conference in Atlanta by puzzle master Gary Foshee. Suspecting that there was more to this problem than I initially thought, I set about repeating the same form of reasoning as in the original puzzle, but taking account of days of the week when my children could have been born. As soon as you do that, you realize that Foshee's problem really is different. But how different? My intuition said that, since the original puzzle had the answer 1/3, the new variant would have an answer fairly close to 1/3. After all, knowing the birth day is a Tuesday may (and does) make a difference, but it surely cannot make much of a difference, right? Wrong. It makes a surprisingly big difference, The correct answer to the new puzzle is 13/27, just slightly less than 1/2, and not at all close to 1/3. This is what really surprised me. To the extent that I checked my solution with the one Bellos published on his blog a few days later. The crux of the matter is that Foshee's variant seems at first glance to be a minor twist on the original one, but it's actually significantly different. The property it focuses on is not gender, but the combination property gender + day of birth. That makes the mathematics very different, as I'll now show. Instead of just the two genders, B and G, of the original puzzle, there are now 14 possibilities for each child: B-Mo, B-Tu, B-We, B-Th, B-Fr, B-Sa, B-Su G-Mo, G-Tu, G-We, G-Th, G-Fr, G-Sa, G-Su When I tell you that one of my children is a boy born on a Tuesday, I eliminate a number of possible combinations, leaving the following: First child B-Tu, second child: B-Mo, B-Tu, B-We, B-Th, B-Fr, B-Sa, B-Su, G-Mo, G-Tu, G-We, G-Th, G-Fr, G-Sa, G-Su. Second child B-Tu, first child: B-Mo, B-We, B-Th, B-Fr, B-Sa, B-Su, G-Mo, G-Tu, G-We, G-Th, G-Fr, G-Sa, G-Su. Notice that the second row has one fewer members than the first, since the combination B-Tu + B-Tu already appears in the first row. Altogether, there are 14 + 13 = 27 possibilities. Of these, how many give me two boys? Well, just count them. There are 7 in the first row, 6 in the second row, for a total of 13 in all. So 13 of the 27 possibilities give me two boys, giving that answer of 13/27. (As in the original problem, you have to assume all the combinations are equally likely. In the case of birth days, this is actually not the case, since more babies are born on Fridays, and fewer on weekends, due to the desire of hospital doctors to have weekends as free as possible of duties.) What misled my intuition (and likely yours as well) was my unfamiliarity with the property gender + day of birth. Fortunately, the math does not lie. Provided you put your intuitions to one side and set up the problem correctly, the math will give you the right answer. Now that your intuition has been primed, let me leave you with this problem. I tell you I have two children, and (at least) one of them is a boy born on April 1. What probability should you assign to the event that I have two boys? If you think that is going to be too cumbersome, simply tell me whether the probability is close to 1/2 or to 1/3, or to some other simple fraction, and provide an estimate as to how close. (Once more, you should assume all birth possibilities are equally likely, ignoring in particular the well known seasonal variations in actual births.) If you are still having doubts about all of this, take consolation in the fact that you are not alone. Representing real-world problems correctly to calculate probabilities is notoriously difficult. In my recent book The Unfinished Game, cited below, I describe how no less a mathematician than Blaise Pascal had enormous difficulty understanding an analogous argument by Pierre de Fermat. Follow Keith Devlin on Twitter at Devlin's Angle is updated at the beginning of each month. Find more columns here@nprmathguy. Mathematician Keith Devlin (email: devlin@stanford.edu) is the Executive Director of the Human-Sciences and Technologies Advanced Research Institute (H-STAR) at Stanford University and The Math Guy on NPR's Weekend Edition. His most recent book for a general reader is The Unfinished Game: Pascal, Fermat, and the Seventeenth-Century Letter that Made the World Modern, published by Basic Books.
- sagaro 3y ago>I tell you I have two children, and (at least) one of them is a boy born on April 1. What probability should you assign to the event that I have two boys? If you think that is going to be too cumbersome, simply tell me whether the probability is close to 1/2 or to 1/3, or to some other simple fraction, and provide an estimate as to how close. I am going to not heed the author's suggestion of setting up the problem correctly and use intuition: For the week problem it was 14+13 = (7 * 4 -1) in the bottom and 13 (7*2-1) on the top. So for a normal year (365 days), it would be (365*2 - 1)/(365*4 - 1). Close to 1/2.
- ksaho 3y agoI was lazy so I just did: import itertools as itools xs = [f'{i}-{j}' for i in range(30) for j in range(12)] ys = ['b', 'g'] zs = list(itools.product(xs, ys)) boys = [z for z in zs if z[1] == 'b'] len(boys)/len(zs) ---- gives me 0.5, or 1/2. The moral of the article is to set up your universal set correctly and do not throw out any information, now matter how irrelevant.
- p1esk 3y agoBut in this case the moral of the article is exactly the opposite - if you throw out the irrelevant information the answer becomes trivial (no need for your calculations).
- wruza 3y agoNow I tell you I have two children, and (at least) one of them is a boy born on April 1st, has medium-length black hair, is 4'2", interested in 5 out of 12000 available rpg games, has 8 close friends and sword-shaped fingernails. I believe your script may require a datacenter and a scalable architecture now.
- phalf 3y agoAnd what do you do with non-discrete attributes?
- phalf 3y ago
- jldugger 3y ago> many people have about problems such as this, which are about what is known as epistemic probability Funnily enough, I'm currently reading _Against the Gods_ (1996) and the chapter I'm on covers exactly this distinction. What are the odds?!?! (If it helps, today is Sunday)
- WirelessGigabit 3y agoHow many children do you have, their genders and the day of the week they were born?
- stochastimus 3y agoI don’t think it’s necessary to invoke epistemic probability to explain why the original question is tricky. At least for me, it helps to notice that if the question were rephrased “the older child is a boy, what is the probability that the younger child is also?”, then the answer would be the intuitive 1/2. You get into this counter-intuitive situation with the question as asked because of the “at least” phrasing - the remaining possibilities in the contingency table can still apply to one, the other, or both children.
- quickthrower2 3y agoIf someone has at least one boy, it is 1/3 If they then say, I have a secret child-ordering X, such that the first in this ordering is a boy, I guess it is now 1/2 However the receiver of 1/3 case knows there exists a secret child-ordering where this is the case. Weird!
- quickthrower2 3y agoI had a think about this since, and it must have everything to do with experimental setup, and the existence of the observer in the experiment. Let's set it up like this: You have 4 dads. Each dad has 2 kids covering all the combinations of kids: MM, MF, FM, FF. Now if you define the experiment as: you are talking to a dad who has one boy. This was set up by the 4 dads being in the playground, and you walk you to one of them randomly and they tell you this. Now in such an experiment there is a 1 in 4 chance that you lead to a contradiction. Therefore in the 4 alternative universes we disband that option, leading to 3 universes. All equally likely. And in one of them the dad has 2 boys. If the dad tells you the older kid is a boy then you have some info. What info is that? Well it depends on the precondition under which he told you that. At least a couple of options. (a) He was going to always reveal to you a kid that was a boy, then tell you if it was the older or younger kid. It happens to be the older one this time. (b) He was going to tell you the gender of the oldest kid. In version (a) there are no universes discarded, so you are still at 1/3 In version (b) the universe where the older kid is not a boy has been discarded. There are now 2 universes in which you exist so it is 1/2.
- deleted 3y ago[deleted]
- quickthrower2 3y agoMy kids classroom of about 25 kids had their birthdays on the wall. Before I looked I thought "yeah good chance 2 are on the same day". And indeed 2 kids shared the same birthday :-). How much surprise? Not a lot (when measured in bits).
- jldugger 3y agoThis article isn't about the birthday paradox though.
- free_energy_min 3y agoAnyone more if bayes rule can apply? I believe it gives the correct answer P(two boys | atleast one) = P(atleast one boy | two boys) * P(two boys)/P(atleast one boy) = 1*(1/4)/(3/4) = 1/3
- deleted 3y ago[deleted]
- jldugger 3y ago> I tell you I have two children, and (at least) one of them is a boy born on a Tuesday. What probability should you assign to the event that I have two boys? > My initial reaction was that the information about the Tuesday was irrelevant, since at issue was gender, not day of birth. In which case, this was the same problem as the one I just described, and the answer would be 1/3. ... The correct answer to the new puzzle is 13/27, just slightly less than 1/2, and not at all close to 1/3. This does not feel coherent on a gut level, and smart people seem to have worked it that this is true but: the answer to the new problem is the same regardless of the day of week you are told. Can't you make that inference then that the answer to the original question is actually 1/2?
- jspiral 3y agowhat works for me is to think of it like the mob of people is already there in front of you, and you're first grabbing out just a subset of the mob based on some conditions, then checking only those qualified at random which is the same as checking the distributions inside the qualified group. so for problem 1, the mob is all parents with 2 children, each child is either b or g. the underlying distribution is 25%bb, 25%gg, 50%bg. you first cull the set by saying "only parents with at least 1 b, line up to be examined". i think it's clear that the selected population will be 1/3 bb parents, 2/3 bg parents, right? on the other hand the second problem is you saying: "all parents with a b born on tuesday, report to be examined!". note that most of the parents that were in the question 1 selected population are now excluded. try to imagine which parents get selected by this one. you can't make the inference back to the original question because it's a different question about a broader group of people. question 1 population distrubution actually is 1/3 vs 2/3. the key is to think of it as selecting different subsets of the parent mob.
- jldugger 3y ago> on the other hand the second problem is you saying: "all parents with a b born on tuesday, report to be examined!". note that most of the parents that were in the question 1 selected population are now excluded. try to imagine which parents get selected by this one. But we expect about the same number of parents to show up for "all parents with a b born on Tuesday" as "all parents with a b born on Monday." This feels like some kind of Simpson's paradox I've invented where every subgroup has a the same outcome, which is different than the outcome of the group as whole.
- wodenokoto 3y ago> So now you know the possible gender combinations are BB, BG, GB To me, this is where the intuitive answer of 50% diverges from the calculated answer. I think intuitively, many of us break it up into 3 equally likely, unordered groups: 'BB', 'GG' and 'BG'. We are then told to exclude 'GG', which leaves us with two equally likely options: 'BG' or 'BB'. This reminds me of the most recent episode of numberphile deals with the sleeping beauty paradox, where Tom Crawford shows Brady that the chance of flipping heads with a coin is 1/3 to which Brady protests that Tom has changed what he is measuring. With the gender question, we just assume the wrong probability space, which isn't the same, but my mind still wandered to numberphile. https://www.numberphile.com/videos/sleeping-beauty-paradox https://www.numberphile.com/videos/sleeping-beauty-paradox
- Terr_ 3y ago> I think intuitively, many of us break it up into 3 equally likely, unordered groups Right, another way to phrase it: 1. We casually move from permutations to combinations, especially when nothing else in the question is there to keep us focused on ordering. 2. When throwing out ordering, we collapse BG and GB together... but forget that the result needs to have double weight.
- wruza 3y agosleeping beauty I didn’t buy it either. They claimed both methods are valid, but these are valid for different questions. One of the weaker numberphile videos imo, unless there was something after the point I stopped watching at.
- nstbayless 3y agoProbability does not bite; describing partial information in English bites. It's not actually true that the probability is 1/3, nor that the probability is 1/2. (Same with 13/27 vs 1/2). The problem is underspecified. Here's two different more specified versions for which the answer is clear: 1. Sample from all two-child families with at least one boy. What portion of these families have two boys? (answer, rot13: n guveq) 2. Choose a random two-child family, then knock on their door. A boy answers. What are the odds the other child is a boy? (rot13: bar unys) These are both consistent with the description "at least one child is a boy"! The day-of-week versions: 3. Sample from all two-child families with at least one boy born on a Tuesday. The odds both are boys? (nyzbfg unys) 4. Knock on the door of a random two-child family. A boy born on Tuesday answers. Odds both are boys? (n unys)
- kgwgk 3y ago> It's not actually true that the probability is 1/3, nor that the probability is 1/2. You’re right. Those who are satisfied with the 1/3 answer may want to consider the following. > I tell you I have two children and that (at least) one of them is a boy, and ask you what you think is the probability that the pair is single-sex. 1/3 > I tell you I have two children and that (at least) one of them is a girl, and ask you what you think is the probability that the pair is single-sex. Also 1/3 > I tell you I have two children, and ask you what you think is the probability that the pair is single-sex. 1/2 So if I tell you that I have two children you think that the probability that they are of the same sex is 1/2. And when I tell you the gender of one of them, whatever it is, you will think that the probability goes down to 1/3?
- HWR_14 3y agoYour math is accurate. Once you are told the gender of one child with no other information, the odds of being all the same gender go down. Probability is tricky.
- kgwgk 3y ago> I have two children… Oh, you have two children? The probability that they are of the same sex is 1/2. > and the sex of at least one of them is… Say no more! If at least one of them is of some sex the odds that they are both of the same sex go down to 1/3. I said 1/2 before but that was before knowing that at least one of them is either a boy or a girl. That changes everything! (Probability is tricky.)
- Mattasher 3y agoConfusion about the Monte Hall problem isn't an issue with people not understanding probability, it's that the problem is usually presented in a way that's under-explained and with hidden assumptions: https://statisticsblog.com/2011/11/23/monte-hall-revisited/ https://statisticsblog.com/2011/11/23/monte-hall-revisited/
- xboxnolifes 3y agoThe best way I've seen the monty hall problem explanation improved upon was by increasing the number of doors. The difference between a 1/2 and 1/3 chance is so subtle to a human. Change it to 1,000,000 doors and suddenly it becomes very obvious why your odds improve on swapping.
- wruza 3y agoTbh it was never very obvious to me why we reveal N-2 goats instead of just 1. My own explanation is that if you are shown a goat door in advance, there is 50/50 of two remaining doors. But since without that you might have picked the door that was revealed, there’s a symmetry about it in which the swap is more lucky. Which is just a clumsy way of saying your chances were 2/3 lose vs 1/3 win and it doesn’t change after the reveal, so you must swap.
- ycombinete 3y agoThis actually helped. I always assumed that the goats/prize were randomly placed, Monty's Door selection was random, and the contestant chose a random door. In which case I could never fathom why you'd need to switch. Since as the author says, there's no new information about the remaining two doors, and switching or not switching remain random. I still feel like I don't full grasp the actual problem/solution though. Even with this new understanding. I will read the linked article by Jeffrey S. Rosenthal though, and hopefully that will fill in the last of the blanks.
- hgsgm 3y agoTo be fair, someone who understands the full problem would be able to explain both solutions.
- kgwgk 3y ago> I tell you I have two children and that (at least) one of them is a boy, and ask you what you think is the probability that I have two boys. I want to find P(you have two boys|you tell me that you have two children including at least one boy) = P(you have two boys|you tell me that X) where for convenience I use the notation X=“you have two children including at least one boy” I can write P(you have two boys|you tell me X) P(you tell me X) = P(you tell me X|you have two boys) P(you have two boys) Assuming that you don’t lie I know that X is true and I can restrict the analysis accordingly. P(you have two boys|X and you tell me X) P(you tell me X| X) = P(you tell me X|X and you have two boys) P(you have two boys|X) That conditioning information is redundant in some terms but not always. If the probability of a boy is 1/2 and there is no correlation we can find that P(you have two boys|X)=1/3 (Using the notation girl=not-boy we can also write P(you have one boy and one girl|X)=2/3) But we’re after something that could be different: P(you have two boys|you tell me that X) P(you have two boys|you tell me X) = P(you tell me X|you have two boys) P(you have two boys|X) / P(you tell me X| X) = P(you tell me X|you have two boys) P(you have two boys|X) / ( P(you tell me X|you have two boys) P(you have two boys|X) + P(you tell me X|you have one boy and one girl) P(you have one boy and one girl|X) ) Without additional assumptions we can’t go beyond P(you have two boys|you tell me X) being equal to 1/3 P(you tell me X|you have two boys) divided by 1/3 P(you tell me X|you have two boys) + 2/3 P(you tell me X|you have one boy and one girl)
- penteract 3y agoAnother way to phrase of your point: If you consider it possible they might have told you "I have two children and (at least) one of them is a girl" instead of the statement about a boy (were they to have both a boy and a girl), the reasoning given in the article is wrong.
- Xcelerate 3y agoFor problems like these (and the Bertrand paradox), the answer is almost always: please more formally articulate your sample space.
- hgsgm 3y agoIndeed, a lot of "probability" is actually "linguistics". Bertrand Paradox is deeper though -- it's not always obvious when there is more than one plausible sample space; there's good mathematics in studying that.
- rho4 3y agoThe only way i know how to work through these types of problems is: - draw a complete probability tree - sum the prob. of all branches that are possible given the information (having at least 1 boy born on a Tu) - sum the prob. of all possible branches we're interested in (2 boys) - divide interesting sum by possible sum Then assume I made a mistake, invest the same amount of time to program a simple monte carlo simulation to verify the result. Fix code and probability tree until they match. Kind of like double book keeping. Very satisfying because you can switch multiple times between theoretical and empirical approach and thinking.
- rho4 3y agoThe simulation code: public class Test { public static enum Outcome { B_Mo, B_Tu, B_We, B_Th, B_Fr, B_Sa, B_Su, G_Mo, G_Tu, G_We, G_Th, G_Fr, G_Sa, G_Su; boolean isBoy() { return this == B_Mo || this == B_Tu || this == B_We || this == B_Th || this == B_Fr || this == B_Sa || this == B_Su; } } public static void main(String[] args) { Random r = new Random(); int count_experiments = 1_000_000_000; double count_possible_given_info = 0; double count_interesting = 0; System.out.println("theoretical (13/27): " + (13.0 / 27.0)); for(int i = 0; i < count_experiments; i++) { Outcome child_1 = Outcome.values()[r.nextInt(Outcome.values().length)]; Outcome child_2 = Outcome.values()[r.nextInt(Outcome.values().length)]; boolean possible_given_info = child_1 == Outcome.B_Tu || child_2 == Outcome.B_Tu; boolean interesting = possible_given_info && child_1.isBoy() && child_2.isBoy(); count_possible_given_info += possible_given_info ? 1 : 0; count_interesting += interesting ? 1 : 0; } System.out.println("count_experiments: " + count_experiments); System.out.println("count_possible_given_info: " + count_possible_given_info); System.out.println("count_interesting: " + count_interesting); System.out.println("count_interesting / count_possible_given_info: " + (count_interesting / count_possible_given_info)); } } Example output: theoretical (13/27): 0.48148148148148145 count_experiments: 1000000000 count_possible_given_info: 1.3775374E8 count_interesting: 6.632153E7 count_interesting / count_possible_given_info: 0.481449941032454
- dragonwriter 3y ago> I tell you I have two children and that (at least) one of them is a boy, and ask you what you think is the probability that I have two boys. Many people, when they hear this puzzle for the first time, give the answer 1/2, reasoning that there is an equal likelihood that my other child is a boy or a girl. But this is not correct. Based on what you know, you should conclude that I am actually twice as likely to have a boy and a girl as I am to have two boys. So your right answer to my question is not 1/2 but 1/3. Actually, neither is correct – leaving aside whether the math is correct given the unstated assumptions – because the unstated assumptions are wrong: birth probabilities by sex are not equal and, within the same family, are not independent.