xkcd: Seashell

A recent xkcd cartoon combines statistics (Bayes’ theorem) with an ocean theme, which makes me happy. Bayes’ theorem enables you to calculate conditional probabilities, which is the probabilty of something happening (or being true) given that something else has happened. You can also rearrange the formula to calculate straight probabilities if you know the conditional probabilities. It’s useful.

Conditional probability isn’t a difficult idea. For example, the probability that the next person you see will be female is different (probably higher) to the conditional probability that the next person you see will be female, given that you are standing at a urinal. The condition is that you’re in a men’s restroom.


P denotes probability, and the vertical lines denote conditional probability – read “given that”. The way to read the text in this cartoon is as follows: the probability that you are near the ocean, given that you’ve just picked up a seashell, is equal to the probability that you’ve just picked up a seashell given that you’re near the ocean, multiplied by the probability of being near the ocean, divided by the probability of picking up a seashell.

The author (Randall Munroe) of xkcd notes that the equation is roughly equal to number of times I’ve picked up a seashell at the ocean / number of times I’ve picked up a seashell, which is roughly 1, because one almost always picks up seashells at the beach and not elsewhere.

What the caption means is that if you picked up a seashell, you’re probably at the ocean (so you don’t need to hold it to your ear). The explain xkcd wiki may help. Anyway. Methinks I explain too much.

The comic can also be viewed on the xkcd website.

Published by


Lapsed mathematician, creator of order, formulator of hypotheses. Lover of the ocean, being outdoors, the bush, reading, photography, travelling (especially in Africa) and road trips.

Leave a Reply

Your email address will not be published. Required fields are marked *