Imagine you work at a chocolate factory and are responsible for ensuring chocolate bars’ quality. The factory claims that their chocolate bars have an average weight of 100 grams. However, you suspect that some of the machines might be overfilling the bars.
Your null hypothesis () is that the chocolate bars indeed weigh 100 grams on average, and your alternative hypothesis (
) is that they weigh more than 100 grams.
To test this, you randomly sample 30 chocolate bars and find that they have an average weight of
and the sample standard deviation is
So to write everything in math terms, the null hypothesis is
because I want to reject the fact that on average each chocolate bar weighs 100 grams. I think each bar weighs more than 100 grams on average. Therefore, my alternative hypothesis is
Now let us pick our significance level to be . We should pick this in advance to further calculation to avoid bias in the conclusion because, as shown in the previous example, the conclusion can be different at different levels of
.
The test statistic is

In Figure 3 above, the orange dot region is the critical region (rejection region), which contains the values that should not happen if the null hypothesis is true. The critical value is the value that separates the normal region and the rejection region. Here by the normal region I mean the region where should fall into if
is true. The area of the orange dot region is the significant value
(Note that the area under the curve is 1, just as the probabilities of all events should sum to 1. The right tail part (the orange dot region) represents the observations that are bigger than expected, i.e., the abnormal region). Here we choose
which leads to the critical value
. So we consider all values that are bigger than
to be abnormal. Note that
Therefore we reject the null hypothesis and conclude that on average each bar weighs more than 100 grams. Okay! That’s good for … the customers – the ones who don’t even know that they are lucky!
Discover more from Science Comics
Subscribe to get the latest posts sent to your email.