In: Statistics and Probability
Thomas’ manager has a deal with his employees that he will buy lunch on Friday for the highest weekly performer on his team if that employee wins at least two out of three coin flips. If the highest performer loses at least two out of three coin flips, then that employee has to buy lunch for the manager. To perform the three flips, three quarters are flipped simultaneously, so everyone gets to see three outcomes (heads or tails) each time. In 40 weeks, the manager has won the flips 27 times and Thomas suspects that the quarters being used are unfair as a result. He never trusted his manager, so he’s been keeping track since the first contest, and he has tracked the following results over the 40 weeks:
Number of heads out of three quarters flipped (n heads) |
Weeks where this number of heads occurred |
0 | 2 |
1 | 11 |
2 | 20 |
3 | 7 |
If the quarters were fair, then that would mean that n_heads comes from a binomial distribution with p = 0.5 (and number of trials = 3 – note that number of trials is a fixed parameter for the binomial, not an estimated parameter, so it doesn’t affect the degrees of freedom for the chi-squared test).
Using a chi-squared test for goodness of fit, can we say with 95% confidence that the quarters are unfair (i.e., that these results do not come from a binomial distribution with p=0.5)?
Can we say with 90% confidence that the quarters are unfair?
Solution:
Null Hypothesis (Ho): The data come from a binomial distribution with p =0.5
OR The quarters are fair.
Alternative Hypothesis (Ha): The data do not come from a binomial distribution with p = 0.5
Or The quarters are unfair
We use the binomial distribution to find the probabilities
P (X = 0) = 3C0 (0.5)^0 (0.5)^3 = 0.125
P (X = 1) = 3C1 (0.5)^1 (0.5)^2 = 0.375
P (X = 2) = 3C2 (0.5)^2 (0.5)^1 = 0.375
P (X = 3) = 3C3 (0.5)^3 (0.5)^0 = 0.125
Then these probabilitiess are multipled 40 weeks that result in expected frequency.
Expected frequency at x = 0, 0.125*40 = 5
Expected frequency at x = 1, 0.375*40 = 15
Expected frequency at x = 2, 0.375*40 = 15
Expected frequency at x = 3, 0.125*40 = 5
observed | expected | O - E | (O - E)² / E |
2 | 5.000 | -3.000 | 1.800 |
11 | 15.000 | -4.000 | 1.067 |
20 | 15.000 | 5.000 | 1.667 |
7 | 5.000 | 2.000 | 0.800 |
40 | 40.000 | 0.000 | 5.333 |
Test Statistics
= 5.333
Degrees of freedom, df = n - 1 = 4 - 1 = 3
Using chi-square tables, the p-value is
P [ (3) > 5.333] = 0.1490
Level of significance, a = 1 - 0.95 = 0.05
Since p-value is greater than 0.05 level of significance, we fail to reject the null hypothesis.
Hence, we cannot conclude that the quarters are unfair.
Level of significance, a = 1 - 0.90 = 0.10
Since p-value is greater than 0.10 level of significance, we fail to reject the null hypothesis.
Hence, we cannot conclude that the quarters are unfair at 90%.