Try it on paper first. A hint, the key idea and the worked solution are here when you need them.
A die was rolled 600 times, and the six came up 117 times. A fair die gives 100 sixes on average. Is 117 unusual? Simulate 20 000 experiments of 600 rolls of a fair die (use rng.binomial(600, 1/6, size=20000), which gives the number of sixes of each experiment), and find the share of the experiments with 117 sixes or more.
Have you tried it?
Work it out on paper first. It is fine to get stuck or make a mistake: that is how we learn. When you are ready, go through the solution one step at a time, and check each step against your own.
Plan. rng.binomial(600, 1/6, size=20000) is the number of sixes in each of 20 000 experiments. The share with 117 or more tells how often a fair die gives such a result.
Check. The spread is about , and 117 is spreads above 100. About 3.6 percent of the experiments with a fair die give 117 or more.
Answer: about 3.6 percent. A result like 117 is a little unusual, but a fair die gives it in about one experiment in 28. It is not strong evidence that the die is unfair. If it were 130 sixes, we would be sure.
Log in to join the discussion.
Loading…