## Rolling the dice II

Continuing from the previous post, for a pair of dice, the sample space becomes a little “bigger.” That is 36 (6X6) possible outcomes. Again, for a third-grader, it is much more easier to display the list visually, like this:

Now, what’s the probability of dots added up to 7? By the assumption of fairness, we know that each one of those 36 outcomes is equally likely. My daughter finally found all the combinations, and figured out the the probability is 1 out of 6 (6/36).

I heard it somewhere that smart men use math formula to solve problems, but ‘lazy’ person (layperson :-)) like me would like to use simulations with R (or other computer languages for the matter), and let the machines do what they are good at – really fast, and intense computation. People issue commands, machines follow them. This time, we let the machine toss two dice 1000 times, and count the numbers of getting each possible outcomes. Notice the shape of the histogram? That’s very close to the probability distribution of the sum of the two dice. This pretty much illustrated the Bernoulli Theorem, which states that relative frequency of an event in a sequence of independent trials converges in probability to the probability of the event.

R has a package “TeachingDemos” that’s really useful if you want to demonstrate elementary statistical concepts. I did all the dice simulation using the dice() function. You can find out more here.

## Leave a Reply