Professional Documents
Culture Documents
2. > hist(BMI)
3. > sum(BMI>=30)
[1] 24
5. Successes:
np>=10
252*0.095=23.94 is larger than 10
Failure:
n(1-p)>=10
252(1-0.095)=228.06 is larger than 10
so it satisfies the conditions for confidence interval
X-squared = 165.34, df =
1, p-value < 2.2e-16
alternative hypothesis: true p is not equal to 0.5
95 percent confidence interval:
0.0646408 0.1375214
sample estimates:
p
0.095
7. a. H0 : p = 0.284
Ha : p > 0.284
b.
0.284 is not between the confidence interval found in Q6 so we reject the H0
c.
> prop.test(23.94, 252, p = 0.284, alternative = 'greater', correct = FALSE)
without continuity
correction
X-squared = 44.268, df =
1, p-value = 1
0.06877736 1.00000000
sample estimates:
0.095
p-value = 0.0688
d.
yes they do, in both parts we reject the H0