1236: "Seashell"
Moderators: Moderators General, Prelates, Magistrates
1236: "Seashell"
Title Text: This is roughly equivalent to 'number of times I've picked up a seashell at the ocean' / 'number of times I've picked up a seashell', which in my case is pretty close to 1, and gets much closer if we're considering only times I didn't put it to my ear.
Is it just me, or has he got it the other way round?
EDIT: The image only. The title text seems to be correct.
Re: 1236: "Seashell"
Yeah P(I picked up a seashell) and P(I'm near the ocean) need to be swapped
Re: 1236: "Seashell"
I was puzzled by that, too. I think that you just need to swap the P(seashell) and P(ocean), not the conditional probabilities, because you have to calculate the probability of hearing the ocean when picking up seashells
Re: 1236: "Seashell"
You're right. That's Bayes' theorem, and the formula is reversed.
Re: 1236: "Seashell"
Pete Peels P(shells) near the P(shore)
https://app.box.com/witthoftresume
Former OTTer
Vote cellocgw for President 2020. #ScienceintheWhiteHouse http://cellocgw.wordpress.com
"The Planck length is 3.81779e33 picas."  keithl
" Earth weighs almost exactly π milliJupiters"  whatif #146, note 7
Former OTTer
Vote cellocgw for President 2020. #ScienceintheWhiteHouse http://cellocgw.wordpress.com
"The Planck length is 3.81779e33 picas."  keithl
" Earth weighs almost exactly π milliJupiters"  whatif #146, note 7
Re: 1236: "Seashell"
I've picked up seashells, but never at the seashore. Which makes sense, since I've only visited a seashore about twice in my life, and never actually found any shells while there.
Not many seas in Colorado.
Not many seas in Colorado.
 Whizbang
 The Best Reporter
 Posts: 2238
 Joined: Fri Apr 06, 2012 7:50 pm UTC
 Location: New Hampshire, USA
Re: 1236: "Seashell"
I get the humor (in a gisty sort of way. I am not edumacated on statistics and probabilities and whatnot), but the whole point of the seashell is not to listen to the sound of the ocean the moment you pick it up, but to take the shell home with you and listen to the calming white noise when you are nowhere near the ocean.
'Course, cupping your hand does just as well, but the shell, as a physical representation of the sea, makes the experience more real and/or less silly. Though one could argue that putting the exoskeleton of a sea creature to your ear is a bit silly.
'Course, cupping your hand does just as well, but the shell, as a physical representation of the sea, makes the experience more real and/or less silly. Though one could argue that putting the exoskeleton of a sea creature to your ear is a bit silly.
Re: 1236: "Seashell"
I'm confused by the "roughly" in the titletext  P(SO)*P(O) is exactly P(S&O) (and P(S) is obviously the same as P(S)) so there doesn't seem to be much scope for the two to be slightly different...
Re: 1236: "Seashell"
rmsgrey wrote:I'm confused by the "roughly" in the titletext  P(SO)*P(O) is exactly P(S&O) (and P(S) is obviously the same as P(S)) so there doesn't seem to be much scope for the two to be slightly different...
I had the same thought, but then again the ratio of the number of occurrences is only an estimate of the ratios of the statistical probabilities of the events. Maybe that is what he was getting at?
xtifr wrote:... and orthogon merely sounds undecided.
Re: 1236: "Seashell"
Rev. Bayes Says: P(AB) P(B) = P(BA) P(A)
[insert link to xkcd comic 386 here.... can't figure out how...]
Wait a minute.... have we just been trolled?
[insert link to xkcd comic 386 here.... can't figure out how...]
Wait a minute.... have we just been trolled?
Re: 1236: "Seashell"
Bayes' theorem in a nutshell, err... seashell
Re: 1236: "Seashell"
Agreed. He has the prior in the denominator and the evidence in the numerator... should be switched:
$p(\theta  X) = \frac{p(X\theta)p(theta)}{p(X)}$
...does latex work in here?
$p(\theta  X) = \frac{p(X\theta)p(theta)}{p(X)}$
...does latex work in here?
Re: 1236: "Seashell"
He got Bayes' theorem wrong.
P(BA) = P(AB) P(B) /P(A)
P(oceanshell) = P(shellocean) * P(ocean)/P(shell)
P(BA) = P(AB) P(B) /P(A)
P(oceanshell) = P(shellocean) * P(ocean)/P(shell)
Last edited by Viadd on Wed Jul 10, 2013 2:16 pm UTC, edited 1 time in total.

 Posts: 1
 Joined: Wed Jul 10, 2013 1:50 pm UTC
Re: 1236: "Seashell"
Bayes Theorem is that
[math]P(AX) = ( P(XA) * P(A) ) / ( P(XA) * P(A) + P(X~A) * P(~A) )[/math]
Which also equals
[math]P(X&A) / ( P(X&A) + P(X&~A) )[/math]
Since
[math]P(XA) * P(A) = P(X&A)[/math]
By this theorem
[math]P(I'm near the oceanI picked up a seashell)[/math]
Should equal
[math]( P(SO) * P(O) ) / ( P(SO) * P(O) + P(S~O) * P(~O)[/math]
[math]P(AX) = ( P(XA) * P(A) ) / ( P(XA) * P(A) + P(X~A) * P(~A) )[/math]
Which also equals
[math]P(X&A) / ( P(X&A) + P(X&~A) )[/math]
Since
[math]P(XA) * P(A) = P(X&A)[/math]
By this theorem
[math]P(I'm near the oceanI picked up a seashell)[/math]
Should equal
[math]( P(SO) * P(O) ) / ( P(SO) * P(O) + P(S~O) * P(~O)[/math]
Re: 1236: "Seashell"
Dammit, I came here to post that, but got beat to it by everybody ... I still have a lingering suspicion it might be a clever underhanded trick, though a mistake is more likely.
Re: 1236: "Seashell"
I've been to the seashore lots (living in a coastal town helps), but when does one ever just "find" a seashell like that on the beach? Maybe I just live on the wrong part of the ocean or the wrong ocean. On the contrary, my grandparents had one in their house. Hence lots of listening in a seashell while not at the sea and zero times picking up that type of seashell while at the sea.
Re: 1236: "Seashell"
rmsgrey wrote:I'm confused by the "roughly" in the titletext  P(SO)*P(O) is exactly P(S&O) (and P(S) is obviously the same as P(S)) so there doesn't seem to be much scope for the two to be slightly different...
Roughly, because the quantities in the alt text are not propabilities but absolute frequencies resulting in the quotient being a relative frequency. As such it only approximates the probability or (almost surely) converges to it when time or number of experiments aproaches infinity.
orthogon wrote:I had the same thought, but then again the ratio of the number of occurrences is only an estimate of the ratios of the statistical probabilities of the events. Maybe that is what he was getting at?
Exactly.
 WolfieMario
 Posts: 120
 Joined: Fri Jan 28, 2011 10:45 pm UTC
 Contact:
Re: 1236: "Seashell"
It's been corrected; for those who want context, this was the original:
"Sometimes game development isn't about doing what is nice to everyone all the time."  Jens Bergensten
 rhomboidal
 Posts: 797
 Joined: Wed Jun 15, 2011 5:25 pm UTC
 Contact:
Re: 1236: "Seashell"
I've stopped picking up seashells because of the probability there's a cone snail inside them. Thanks, math.

 Posts: 2
 Joined: Wed Jul 10, 2013 4:57 pm UTC
Re: 1236: "Seashell"
As a statistician who uses Bayesian methods, I have to disagree with the caption in the comic:
"Statistically speaking, if you pick up a seashell and don't hold it to your ear, you can probably hear the ocean."
I think this is a misunderstanding of Bayes rule. Let's consider the corrected version of the equation in the comic,
P(near ocean  seashell) ~ p(seashell  near ocean) * P(near ocean),
where "~" means proportional to. (I'm treating "seashell", the known quantity, as constant, and "near ocean", the unknown quantity, as stochastic.) If you're likely to be far away from the ocean to begin with, then P(near ocean  seashell) will be controlled mostly by your low prior probability, P(near ocean). If you're extremely unlikely to be near the ocean to begin with, then it won't make a difference whether you pick up the shell or not. P(near ocean  seashell) will still be low because your prior belief of being far away is so strong.
Doctors have a similar problem testing for rare diseases. Let's say I test positive for the Siberian Swaziflu (a rare condition that I'm making up). My posterior probability of having the disease is
P(sick  +) ~ P(+  sick) P(sick)
Since the disease is so rare, P(sick) is extremely low, and so the chances of my having the disease are still low even though I tested positive. Epidemiologists think about this sort of thing a lot.
"Statistically speaking, if you pick up a seashell and don't hold it to your ear, you can probably hear the ocean."
I think this is a misunderstanding of Bayes rule. Let's consider the corrected version of the equation in the comic,
P(near ocean  seashell) ~ p(seashell  near ocean) * P(near ocean),
where "~" means proportional to. (I'm treating "seashell", the known quantity, as constant, and "near ocean", the unknown quantity, as stochastic.) If you're likely to be far away from the ocean to begin with, then P(near ocean  seashell) will be controlled mostly by your low prior probability, P(near ocean). If you're extremely unlikely to be near the ocean to begin with, then it won't make a difference whether you pick up the shell or not. P(near ocean  seashell) will still be low because your prior belief of being far away is so strong.
Doctors have a similar problem testing for rare diseases. Let's say I test positive for the Siberian Swaziflu (a rare condition that I'm making up). My posterior probability of having the disease is
P(sick  +) ~ P(+  sick) P(sick)
Since the disease is so rare, P(sick) is extremely low, and so the chances of my having the disease are still low even though I tested positive. Epidemiologists think about this sort of thing a lot.
Re: 1236: "Seashell"
keldor wrote:I've picked up seashells, but never at the seashore.... Not many seas in Colorado.
Same for Kansas. I think I'm most likely to find a sea shell at Hobby Lobby, maybe?
Help a paralyzed kitten get surgery! Fundly.com/HelpLinkWalkAgain
Like Link's page for photos and updates on his status: Facebook.com/HelpLinkWalkAgain
Like Link's page for photos and updates on his status: Facebook.com/HelpLinkWalkAgain

 Posts: 2
 Joined: Wed Jul 10, 2013 4:57 pm UTC
Re: 1236: "Seashell"
Sorry about the repeat post. I'm new.
Last edited by statismensch on Thu Jul 11, 2013 4:04 pm UTC, edited 1 time in total.

 Posts: 170
 Joined: Mon Aug 03, 2009 3:07 pm UTC
Re: 1236: "Seashell"
keldor wrote:I've picked up seashells, but never at the seashore. Which makes sense, since I've only visited a seashore about twice in my life, and never actually found any shells while there.
Not many seas in Colorado.
He said oceans. Seas are different. But hey, not many oceans in Arizona either.
Only this morning, I picked up a seashell from the floor of my son's school. We also have a terrarium fitted out for a scraggly and entertaining bunch of decapods. They like to fling rejected shells around, which means I get to pick them up. Also, back when I lived in England, I used to pick up sea shells from the beach. This was on the North Sea. No ocean in sight.
I think to correct the expression, the following need to be integrated: P(domicile is located <60 minutes' journey from an ocean), P(has children), P(has hermit crabs), and perhaps change "ocean" to "saltwater".
Re: 1236: "Seashell"
Hmm.. yeah... I've never been at an ocean, and I don't think I'm alone.
Re: 1236: "Seashell"
Calculations should take under consideration current level of ocean drain

 Posts: 3
 Joined: Thu May 03, 2012 1:53 am UTC
Re: 1236: "Seashell"
Better title for this comic: "Bays" Theorem
 The Moomin
 Posts: 358
 Joined: Wed Oct 13, 2010 6:59 am UTC
 Location: Yorkshire
Re: 1236: "Seashell"
So he moved the P around with the seashell?
I choose the right one.
I choose the right one.
I'm alive because the cats are alive.
The cats are alive because I'm alive.
Specious.
The cats are alive because I'm alive.
Specious.
Re: 1236: "Seashell"
Ann_xkcd wrote:I've been to the seashore lots (living in a coastal town helps), but when does one ever just "find" a seashell like that on the beach? Maybe I just live on the wrong part of the ocean or the wrong ocean. On the contrary, my grandparents had one in their house. Hence lots of listening in a seashell while not at the sea and zero times picking up that type of seashell while at the sea.
Yep. You live by the Wrong part of the water.
Those things need warm water.
Do you want to know why?
I can't remember.
Those large shells are destroyed by the Rough Northern Waters.
It is nice to hear The Sea.
I first heard the Sea in a Sea Shell.
http://www.howstuffworks.com/question556.htm
Life is, just, an exchange of electrons; It is up to us to give it meaning.
We are all in The Gutter.
Some of us see The Gutter.
Some of us see The Stars.
by mr. Oscar Wilde.
Those that want to Know; Know.
Those that do not Know; Don't tell them.
They do terrible things to people that Tell Them.
We are all in The Gutter.
Some of us see The Gutter.
Some of us see The Stars.
by mr. Oscar Wilde.
Those that want to Know; Know.
Those that do not Know; Don't tell them.
They do terrible things to people that Tell Them.
Re: 1236: "Seashell"
I think Randall doesn't know how to use three seashells...
Re: 1236: "Seashell"
Is it just me, or has Randall been invoking the Bayes a lot lately?
Wait, where did P(seashell) go? You can't just drop it, it depends on P(near ocean)! I think we can agree that everyone sees about the same number of nonocean seashells, at children's museums and stuff. However, people who live near (seashellstrewn) beaches see a lot more ocean seashells than people who don't, so their total number of seashells is much higher, and for them any given seashell is very likely to be an ocean seashell. I think this is true of Randall, since he lives in Massachusetts and seems to like beaches.
Your argument does make sense for people who mostly (or always) see nonocean seashells. I personally encounter shells big enough to listen to so rarely that I'm not sure I can weigh in, though I think one of my elementary school teachers had one and my school wasn't on a beach, so I guess I was in the "mostly nonocean seashells" group while I was in her class.
You could apply similar logic here if testing positive is also extremely rare, and P(+  sick) is reasonably sized. You can make up for even a small P(+  sick) if P(+) is small enough, but such a test would not be very useful . Of course, practically speaking I bet it's really hard to develop a good test for diseases that are seen rarely, just because you don't have many opportunities to study it...?
[sniff] God bless you, sir...god bless you.
statismensch wrote:I think this is a misunderstanding of Bayes rule. Let's consider the corrected version of the equation in the comic,
P(near ocean  seashell) ~ p(seashell  near ocean) * P(near ocean),
where "~" means proportional to. (I'm treating "seashell", the known quantity, as constant, and "near ocean", the unknown quantity, as stochastic.) If you're likely to be far away from the ocean to begin with, then P(near ocean  seashell) will be controlled mostly by your low prior probability, P(near ocean). If you're extremely unlikely to be near the ocean to begin with, then it won't make a difference whether you pick up the shell or not. P(near ocean  seashell) will still be low because your prior belief of being far away is so strong.
Wait, where did P(seashell) go? You can't just drop it, it depends on P(near ocean)! I think we can agree that everyone sees about the same number of nonocean seashells, at children's museums and stuff. However, people who live near (seashellstrewn) beaches see a lot more ocean seashells than people who don't, so their total number of seashells is much higher, and for them any given seashell is very likely to be an ocean seashell. I think this is true of Randall, since he lives in Massachusetts and seems to like beaches.
Your argument does make sense for people who mostly (or always) see nonocean seashells. I personally encounter shells big enough to listen to so rarely that I'm not sure I can weigh in, though I think one of my elementary school teachers had one and my school wasn't on a beach, so I guess I was in the "mostly nonocean seashells" group while I was in her class.
statismensch wrote:Doctors have a similar problem testing for rare diseases. Let's say I test positive for the Siberian Swaziflu (a rare condition that I'm making up). My posterior probability of having the disease is
P(sick  +) ~ P(+  sick) P(sick)
Since the disease is so rare, P(sick) is extremely low, and so the chances of my having the disease are still low even though I tested positive. Epidemiologists think about this sort of thing a lot.
You could apply similar logic here if testing positive is also extremely rare, and P(+  sick) is reasonably sized. You can make up for even a small P(+  sick) if P(+) is small enough, but such a test would not be very useful . Of course, practically speaking I bet it's really hard to develop a good test for diseases that are seen rarely, just because you don't have many opportunities to study it...?
greymatters wrote:Better title for this comic: "Bays" Theorem
[sniff] God bless you, sir...god bless you.

 Posts: 3
 Joined: Wed Nov 23, 2011 8:32 am UTC
Re: 1236: "Seashell"
garaden wrote:Wait, where did P(seashell) go? You can't just drop it, it depends on P(near ocean)!
He treated P(seashell) as a constant and changed his equation to "is proportional to". It works mathematically.
Re: 1236: "Seashell"
tyler.daniels wrote:garaden wrote:Wait, where did P(seashell) go? You can't just drop it, it depends on P(near ocean)!
He treated P(seashell) as a constant and changed his equation to "is proportional to". It works mathematically.
Sure, I agree that algebraically it's a perfectly fine thing to do But in terms of probability theory it doesn't make much sense. Now that I think about it, the problem isn't really that he decided P(S) was constant; sometimes you can do that without running into trouble. The trouble is, if the ratio P(SO)/P(S) is at least as big as P(O) is small, then P(O) is no longer dominating and P(OS) can become quite a bit larger than P(O) (up to 1, actually). By dropping P(S) and leaving P(SO) to fend off P(O) all on its lonesome, it certainly looks like P(OS) can be no bigger than P(O), which is not the case.
Thing is, probabilities aren't like physics equations. You don't need to know the exact ratio of force to electric field strength to understand the Lorentz force, because if you pick different units you'll get a different ratio, so it's the proportionality that actually matters (though why coulombs etc. are so friggin' huge is beyond me). But with probabilities, the difference between a ratio being >1 or <1 is the difference between evidence and counterevidence. The information hiding in the proportionality squiggle is REALLY important!
If you like thinking about this stuff (I might. A lot.), I recommend http://yudkowsky.net/rational/bayes.

 Posts: 1
 Joined: Fri Jul 12, 2013 10:59 am UTC
Re: 1236: "Seashell"
The events A: "I am near the ocean" and B: "I picked up a seashell" are likely not independants, so the real formula should be:
In the case of A and B being independant, then:
Of course in practice, all events are considered independants (otherwise it is too complicated to compute). Often it works rather well, but when it does not, this could lead to dire consequences like the subprimes crisis.
P(AB) = P(A and B)/P(B).
In the case of A and B being independant, then:
P(A and B) = P(AB)P(B) = P(BA)P(A).
Of course in practice, all events are considered independants (otherwise it is too complicated to compute). Often it works rather well, but when it does not, this could lead to dire consequences like the subprimes crisis.
Re: 1236: "Seashell"
statistical purist wrote:The events A: "I am near the ocean" and B: "I picked up a seashell" are likely not independants, so the real formula should be:P(AB) = P(A and B)/P(B).
In the case of A and B being independant, then:P(A and B) = P(AB)P(B) = P(BA)P(A).
Of course in practice, all events are considered independants (otherwise it is too complicated to compute). Often it works rather well, but when it does not, this could lead to dire consequences like the subprimes crisis.
Hang on a minute. Your first equation, which you say is generally true, is equivalent to the first equality in your second equation, P(A and B) = P(AB) P(B), which you say is true only for independent events. You can get from one to the other simply by multiplying both sides by P(B). (The case where P(B)=0 is a bit pathological, I admit, but I don't think that concerns us here).
Perhaps what you are getting at is that if A and B are independent, then P(AB) = P(A); in other words whether B occurs or not has no bearing on the probability of A, so the conditional probability equals the marginal probability. From this we get the famous result that P(A and B) = P(AB)P(B) = P(A)P(B) if A and B are independent.
PS Welcome to the forum!
xtifr wrote:... and orthogon merely sounds undecided.
Re: 1236: "Seashell"
statistical purist wrote:Of course in practice, all events are considered independants (otherwise it is too complicated to compute). Often it works rather well, but when it does not, this could lead to dire consequences like the subprimes crisis.
...yeah. "Most major investment banks, strongly correlated to the housing market by accident? Preposterous!" KABOOM. "Whoops."
Statistically speaking, if you accidentally the economy but have a golden parachute, you can probably hear the ocean. :/

 Posts: 98
 Joined: Mon Oct 18, 2010 9:49 am UTC
Re: 1236: "Seashell"
garaden wrote:... why coulombs etc. are so friggin' huge is beyond me...
Because it's set sensibly for current electricity (an amperesecond); and current electricity is very different from static electricity.
Re: 1236: "Seashell"
arthurd006_5 wrote:garaden wrote:... why coulombs etc. are so friggin' huge is beyond me...
Because it's set sensibly for current electricity (an amperesecond); and current electricity is very different from static electricity.
Just to put the things into a "proper" perspective: my mobile phone's battery is rated @1200 mA*h, that's 4320 coulombs.
Re: 1236: "Seashell"
Kit. wrote:arthurd006_5 wrote:garaden wrote:... why coulombs etc. are so friggin' huge is beyond me...
Because it's set sensibly for current electricity (an amperesecond); and current electricity is very different from static electricity.
Just to put the things into a "proper" perspective: my mobile phone's battery is rated @1200 mA*h, that's 4320 coulombs.
Good point; I was definitely thinking about capacitors when I felt like 1 C was ludicrously big. That said, I think I would have preferred it to be an order of magnitude or three lower, and then we wouldn't have to e.g. rate batteries with milliamphours. It'd be nice if household currents could be expressed in the base unit rather than needing fractions of it.
Re: 1236: "Seashell"
Off Topic:
Not anything to do with math here.
The Sea Shell is left behind, also.
http://www.spiritsite.com/writing/annlin/part2.shtml
https://www.google.com/search?q=the+cha ... 80&bih=597
Do you think P(sea shell) are welks?
http://www.sciencenews.org/view/generic ... ll_Spirals
oh. The Golden Ratio is not so gold after all.
http://www.maa.org/features/lifebytv.html
About Math for our Liberal Artists.
Not anything to do with math here.
The Sea Shell is left behind, also.
http://www.spiritsite.com/writing/annlin/part2.shtml
https://www.google.com/search?q=the+cha ... 80&bih=597
Do you think P(sea shell) are welks?
http://www.sciencenews.org/view/generic ... ll_Spirals
oh. The Golden Ratio is not so gold after all.
Spoiler:
http://www.maa.org/features/lifebytv.html
About Math for our Liberal Artists.
Life is, just, an exchange of electrons; It is up to us to give it meaning.
We are all in The Gutter.
Some of us see The Gutter.
Some of us see The Stars.
by mr. Oscar Wilde.
Those that want to Know; Know.
Those that do not Know; Don't tell them.
They do terrible things to people that Tell Them.
We are all in The Gutter.
Some of us see The Gutter.
Some of us see The Stars.
by mr. Oscar Wilde.
Those that want to Know; Know.
Those that do not Know; Don't tell them.
They do terrible things to people that Tell Them.
Re: 1236: "Seashell"
garaden wrote:I was definitely thinking about capacitors when I felt like 1 C was ludicrously big.
I guess it depends on how you define "ludicrously". I remember making a 12 V * 0.4 F capacitance box for some semiconductor lab testing. It was quite heavy, but still portable.
garaden wrote:That said, I think I would have preferred it to be an order of magnitude or three lower, and then we wouldn't have to e.g. rate batteries with milliamphours. It'd be nice if household currents could be expressed in the base unit rather than needing fractions of it.
That could backfire as well. Look what happened to [kilo]calories. The 1200 mA*h can be written as 1.2 A*h anyway.
Besides, the current system is pretty suitable for household currents, if you look at European circuit breakers' standard ratings. "16A" at a circuit breaker doesn't look as scary as "16kA" would.
Return to “Individual XKCD Comic Threads”
Who is online
Users browsing this forum: No registered users and 113 guests