In: Statistics and Probability
0 times a week - 32 students
1 time a week- 18 students
2 times a week - 29 students
3 times a week - 26 students
4 times a week - 33 students
5 times a week - 31 students
6 times a week - 27 students
7 times a week - 54 students
The data given shows how many times a week students drink caffeine. With this data, state the null and alternative hypothesis, calculate the test statistic and p-value, and calculate the confidence interval.
The Chi-Square test of independence is used to determine if there is a significant relationship between two factors.
For variables how many times a week and number of students ,
The Chi-Square test of independence is performed in following steps,
Step 1: The hypothesis is defined as,
Null hypothesis, Ho:There is no association between two variables.
Alternative hypothesis, Ha There is an association present between the two variables.
Step 2: The significance level for the test is,
Step 3: The Chi-Square test statistic is obtained as follow,
The observed values are,
Drink Caffeine | Doesn't Drink 'k' times a week | Total | |
0 times a week | 32 | 218 | 250 |
1 times a week | 18 | 232 | 250 |
2 times a week | 29 | 221 | 250 |
3 times a week | 26 | 224 | 250 |
4 times a week | 33 | 217 | 250 |
5 times a week | 31 | 219 | 250 |
6 times a week | 27 | 223 | 250 |
7 times a week | 54 | 196 | 250 |
Total | 250 | 1750 |
Step 4: The expected values are obtained using the formula,
The expected values are,
Drink Caffeine | Doesn't Drink Caffeine | Total | |
0 times a week | 31.25 | 218.75 | 250 |
1 times a week | 31.25 | 218.75 | 250 |
2 times a week | 31.25 | 218.75 | 250 |
3 times a week | 31.25 | 218.75 | 250 |
4 times a week | 31.25 | 218.75 | 250 |
5 times a week | 31.25 | 218.75 | 250 |
6 times a week | 31.25 | 218.75 | 250 |
7 times a week | 31.25 | 218.75 | 250 |
Total | 250 | 1750 | 2000 |
Step 5: Now the Chi-Square Value is obtained using the formula,
Step 4: The P-value for Chi-Square statistic is obtained using the chi square distribution table,
Step 5:
The null hypothesis is rejected. It can be stated now, the two variables are dependent. There is a statistically significant difference between how many times a week students drink caffeine.