Fundamentals of Statistics: Binomial Distribution
Thursday, May 27th, 2010Remember those circular metal pieces you used to do your laundry back in college or graduate school? They had easily distinguished sides so that you could toss them in the air and let them land in one of two configurations, known for reasons now increasingly obscure due to a face lift on the American penny as “heads” or “tails”. Naturally, there is a
chance of either outcome–or as I mentioned earlier, over the course of an infinite number of measurements you’ll get an even 50/50 split.
What I want to do next, is add another coin. Each coin can be heads or tails so we have a total of four possible configurations, HH, TT, HT, or TH, with
probability of each. You can continue to add more coins, resulting in an ever increasing number of unique outcomes, increasing like
for
coins tossed. Let’s say, though, that you don’t really care in which order the events occur, only how many coins land heads up. In this case, you’re concerned with the number of possible combinations, as opposed to the number of permutations. We can find the number of combinations by first finding the number of permutations and dividing this by the degeneracy.
So if we’re interested in tossing
coins and getting
heads, we start with a choice of
coins for our first flip, then
for our second and so on until we have
coins for the final of our
heads. While there might be some initial despair, this can be easily summed up with the factorial as
. As I mentioned, if we don’t care in what order the coins were flipped, we need to divide by the degeneracy. For
heads, there are
possible orderings, so the number of combinations of
items sampled
ax a time is given by
, which is frequently called “n choose x”.
Probability: We can get probability from this quite simply. We know the probability of an individual event occurring, 1/2 in this case, and we know how many ways in which it can happen, so we combine these to get
, where
. The name “binomial distribution” arises from the binomial theorem, which tells us that the sum over all possible values of
for
must be one.
Mean: I’ll spare the mathematical justification for the mean and standard deviation, as these are not straightforward. We can, however, get these correctly with a bit of intuition. In the case of the coin tossing experiment in which
, we expect to get half heads and half tails. So for
trials, we expect
of our outcome of interest leading to
.
Standard Deviation: The intuitive tack to this one is a little less, well, intuitive. We can exploit a trick called “expectation of the square minus square of the expectation” to get the variance,
. For a single coin flip, the mean of the square is just just
. Conveniently, the square of the mean is
. So we can calculate
. For
trials, it’s a simple sum so we can get the standard deviation for the binomial distribution
.
Naturally, we don’t need a
coin flip. It could work just as well for rolling dice where the probability of a particular outcome on one die is 1/6. If you’re sufficiently nerdy to have ever played the game Settlers of Catan, you might recall the dots under each number on the game board. These represent combinations on two dice that will yield that result. So really, any game in which you roll dice can be partially characterized by the binomial distribution. Next, we can take the limit as the probability becomes very small and arrive at the Poisson distribution, which is extremely useful for understanding the results of surveys and polls, so stay tuned for that.