( (
( )
= 125
11.18034 Df = 18 H0: there is no difference between the averages Ha: the averages are different ( t-statistic = (14 0)/5 =2.8 p-value < 0.01 Therefore we reject the null hypothesis and accept the alternate hypothesis Conclusion: there is a difference in average ball flight between these two types of golf tees )
b) S1 = 13 and s2 = 9 since S1/s2 = 1.444 < 1.5 therefore we can do the pooled t-test
c) t* = 2.101 confidence interval is (14 2.101*5, 14 + 2.101*5) (3.495, 24.505) d) Since 0 does not lie in the confidence interval therefore hypothesis result is consistent with the confidence interval.
Q2: a) Ho: people like both instant and fresh brewed coffee equally Ha: majority of people like fresh brewed coffee
If p is the proportion of people who like fresh brewed coffee then we can restate as follows Ho: p = 0.5 Ha: p > 0.5
( )
Z=
= 2.529822
p-value= P(Z > 2.529822) = 1 - 0.994294 = 0.005706 since p-value < 0.5 therefore we can reject the null hypothesis and accept the alternate hypothesis. Conclusion: majority like fresh brewed coffee b)
c) since p-value < 0.5 therefore we can reject the null hypothesis and accept the alternate hypothesis. Conclusion: majority like fresh brewed coffee d) Confidence interval is given by
( )
Q3: a) live with smokers Control cancer patient Total dont live with smokers total 90 285 375 83 173 116 401 199 574
b)
Ho: p1 p2 = 0 Ha: p1 - p2 0 Z=
( ( )( ) )
= 4.472757
since the p-value < 0.05 we reject the null hypothesis and accept the alternate hypothesis c) Ho: non-smoking lung cancer have same second hand smoke exposure as non-smoking controls Ha: non-smoking lung cancer have different second hand exposure than the non-smoking controls The pooled estimate of p is = 173/574 = 0.301394 dont live live with with smokers smokers total 113.0228 261.9773 375 59.97741 139.0226 173.0002 400.9998 199 574
= 19.36293 Df = 1 x 1 = 1 P-value < 0.005 Therefore we can reject the null hypothesis and accept alternate hypothesis The conclusion is same as the conclusion arrived in part (b) d)
. tabi 90 285 \ 83 116, chi2 col row 1 2 Total 1 90 83 173 Pearson chi2(1) = 2 285 116 401 19.3629 Total 375 199 574 Pr = 0.000
Q4: Ho: Hair color is not associated with sex Ha: Hair color is associated with sex
. tabulate female hair, chi2 female 0 1 Total black 46 24 70 Pearson chi2(2) = hair blonde 8 19 27 13.7370 brown 39 54 93 Pr = 0.001 Total 93 97 190
Since the p-value = 0.001 < 0.05 therefore we reject the null hypothesis and accept alternate hypothesis. Conclusion: hair color is associate with sex
Q5:
.05 0
0
.1
.15
.2
6 95% CI
10
. regress bac beers Source Model Residual Total bac beers _cons SS .023375345 .005849655 .029225 Coef. .0179638 -.0127006 df 1 14 15 MS .023375345 .000417832 .001948333 t 7.48 -1.00 P>|t| 0.000 0.332 Number of obs F( 1, 14) Prob > F R-squared Adj R-squared Root MSE = = = = = = 16 55.94 0.0000 0.7998 0.7855 .02044
There is a strong positive correlation between blood alcohol and amount of beer
since the p-value is less than 0.05 we reject the null hypothesis and accept alternate hypothesis Conclusion: There is significance evidence that drinking more beers increases blood alcohol
c) from Stata we get the confidence interval for the slope is (0.0128,0.0231)
d)
. summarize bac beers, detail BAC 1% 5% 10% 25% 50% 75% 90% 95% 99% Percentiles .01 .01 .02 .045 .07 .0975 .12 .19 .19 Largest .1 .1 .12 .19 Beers 1% 5% 10% 25% 50% 75% 90% 95% 99% Percentiles 1 1 2 3 5 6.5 8 9 9 Largest 7 7 8 9 Smallest 1 2 3 3 Smallest .01 .02 .03 .04