We want to check if 100 values come from a uniform distribut
We want to check if 100 values come from a uniform distribution using a GOF test. We got the
following counts in five categories (bins or intervals): 21, 19, 18, 22, 20. What test would you use? Calculate the statistic (should be 0.5). How many degrees of freedom do we have? The p-value for this value of the statistic is 0.973. What is your conclusion? Repeat for counts 30, 25, 20, 15, 10. The statistic should now be 12.5 and p-value = 0.013. What is your conclusion now?
Solution
We want to check if 100 values come from a uniform distribution using a GOF test. We got the
following counts in five categories (bins or intervals): 21, 19, 18, 22, 20. What test would you use? Calculate the statistic (should be 0.5).
Doing an observed/expected value table,
O E (O - E)^2/E
21 20 0.05
19 20 0.05
18 20 0.2
22 20 0.2
20 20 0
Using chi^2 = Sum[(O - E)^2/E],
chi^2 = 0.5 [ANSWER, TEST STATISTIC]
How many degrees of freedom do we have?
As df = a - 1,
a = 5
df = a - 1 = 4
The p-value for this value of the statistic is 0.973. What is your conclusion?
As P > 0.05 (or any reasonable significance level), there is no significant evidence that th distribution of data here is not uniform. [CONCLUSION]
*************************************************************
Repeat for counts 30, 25, 20, 15, 10. The statistic should now be 12.5 and p-value = 0.013.
Doing an observed/expected value table,
O E (O - E)^2/E
30 20 5
25 20 1.25
20 20 0
15 20 1.25
10 20 5
Using chi^2 = Sum[(O - E)^2/E],
chi^2 = 12.5 [ANSWER, TEST STATISTIC]
Also, the p value is, as df = 4,
p = 0.013995792 [ANSWER, P VALUE]
What is your conclusion now?
As P < 0.05, then at 0.05 level, there is significant evidence that the distribution of these data is not uniform. [CONCLUSION]

