In: Statistics and Probability
The National Sleep Foundation used a survey to determine whether
hours of sleeping per night are independent of age
(Newsweek, January 19, 2004). The following show the hours
of sleep on weeknights for a sample of individuals age 49 and
younger and for a sample of individuals age 50 and older.
Hours of Sleep | |||||||
Age | Fewer than 6 | 6 to 6.9 | 7 to 7.9 | 8 or more | Total | ||
49 or younger | 35 | 65 | 71 | 69 | 240 | ||
50 or older | 37 | 63 | 80 | 80 | 260 |
Less than 6 hours | % |
6 to 6.9 hours | % |
7 to 7.9 hours | % |
8 or more hours | % |
a;
Hypotheses are:
H0; The hours of sleep on weeknights are independent of age.
Ha; The hours of sleep on weeknights are not independent of age.
Following table shows the row total and column total:
Hours of Sleep | |||||||
Age | Fewer than 6 | 6 to 6.9 | 7 to 7.9 | 8 or more | Total | ||
49 or younger | 35 | 65 | 71 | 69 | 240 | ||
50 or older | 37 | 63 | 80 | 80 | 260 | ||
Total | 72 | 128 | 151 | 149 | 500 |
Expected frequencies will be calculated as follows:
Following table shows the expected frequency:
Hours of Sleep | |||||
Age | Fewer than 6 | 6 to 6.9 | 7 to 7.9 | 8 or more | Total |
49 or younger | 34.56 | 61.44 | 72.48 | 71.52 | 240 |
50 or older | 37.44 | 66.56 | 78.52 | 77.48 | 260 |
Total | 72 | 128 | 151 | 149 | 500 |
Following table shows the calculations for chi square test statistics:
O | E | (O-E)^2/E |
35 | 34.56 | 0.005601852 |
37 | 37.44 | 0.00517094 |
65 | 61.44 | 0.206276042 |
63 | 66.56 | 0.190408654 |
71 | 72.48 | 0.030220751 |
80 | 78.52 | 0.027896077 |
69 | 71.52 | 0.088791946 |
80 | 77.48 | 0.081961797 |
Total | 0.636328058 |
The test statistics is:
Degree of freedom: df =( number of rows -1)*(number of columns-1) = (2-1)*(4-1)=4
The p-value is: 0.8881
Since p-value is greater than 0.05 so we fail to reject the null hypothesis.
b)
Following table shows the required percentage:
Frequency, f | (f*100)/500% | |
Fewer than 6 | 72 | 14.4 |
6 to 6.9 | 128 | 25.6 |
7 to 7.9 | 151 | 30.2 |
8 or more | 149 | 29.8 |