Example 1: Suppose you have a die and you suspect that it is biased towards the number 3, and so run an experiment in which you throw the die 10 times and count that the number 3 comes up 4 times. Determine whether the die is biased.
The population random variable x = the number of times 3 occurs in 10 trials has a binomial distribution B(10, π) where π is the population parameter corresponding to the probability of success on any trial. We define the following null hypothesis.
H0: π ≤ 1/6; i.e. the die is not biased towards the number 3
H1: π > 1/6
Now setting α = .05, we have
P(x ≤ 4) = BINOMDIST(4, 10, 1/6, TRUE) = 0.984538 > 0.95 = 1 – α.
And so we reject the null hypothesis with 95% level of confidence.
Example 2: We suspect that a coin is biased towards heads. When we toss the coin 9 times, how many heads need to come up before we are confident that the coin is biased towards heads?
We use the following null hypothesis:
H0: π ≤ .5
H1: π > .5
Using a confidence level of 95% (i.e. α = .05), we calculate
CRITBINOM(n, p, 1–α) = CRITBINOM(9, .5, .95) = 7
And so 7 is the critical value. If 7 or more heads come up then we are 95% confident that the coin is biased towards heads, and so can reject the null hypothesis.
Note that BINOMDIST(6, 9, .5, TRUE) = .9102 < .95, while BINOMDIST(7, 9, .5, TRUE) = .9804 ≥ .95.
Example 3: Historically a factory has been able to produce a very specialized nano-technology component with 35% reliability, i.e. 35% of the components passed its quality assurance requirements. They have now changed their manufacturing process and hope that this has improved the reliability. To test this, they took a sample of 24 components produced using the new process and found that 13 components passed the quality assurance test. Does this show a significant improvement over the old process?
We use a one-tailed test with null and alternative hypotheses:
H0: p ≤ .35
H1: p > .35
We use the binomial distribution to perform this test as follows:
p-value = 1 – BINOMDIST(13, 24, .35, TRUE) = 1 – .983581 = .016419 < .05 = α
and so we conclude there is a significant improvement (with 95% confidence).