Solutions XP83 2012 Final #-------------------- Question 1 (1) mean is 1, stan dev is 1 (2) mean is 2, stan dev is 1 (3) mean is 1, stan dev is 2 (4) 1 (5) 1 +/- 2 #-------------------- Question 2 (1) .6*.002 + .4*.01346 = 0.006584 (2) .4*.0333 = 0.01332 #-------------------- Question 3 (1) .25 (2) .75 (3) 2 (4) .5 (5) .7071 #-------------------- Question 4 (1) .24 (2) .6 (3) .6 (4) yes (5) yes (6) .4 (7) .24 (8) yes (9) 0 #-------------------- Question 5 (1) .007 (2) .4*.2 + .6*.1 = 0.14 (3) (.4^2)*.01 + (.6^2)*.01 + 2*.4*.6*.007 = 0.00856 #-------------------- Question 6 (1) .1 (2) .01 (3) .1 (4) .84 (5) 1000 (6) 1000 (7) 0 (8) 2*var(B) = 2*1000^2 = 2*1,000,000 = 2,000,000. (9) +\- 2*sqrt(2)*1000 = +/- 2828. #-------------------- Question 7 (1) .095 (2) > se = sqrt(.095*(1-.095)/1000) > se [1] 0.00927227 > ci = .095 + 2*.00927*c(-1,1) > ci [1] 0.07646 0.11354 (3) > phat = 95/1000 > z = (phat-.15)/sqrt(.15*(1-.15)/1000) > z [1] -4.870882 reject. (4) yes, it is a clear reject. #-------------------- Question 8 (1) I did not tell you if they took the course but it does not make much difference. Without course: 18.47174 + 95*0.81866 +2*7.311*c(-1,1) [1] 81.62244 110.86644 With course subtract .85 18.47174 + 95*0.81866 +2*7.311*c(-1,1)-.84577 [1] 80.77667 110.02067 (2) .81866 +2*.07*c(-1,1) [1] 0.67866 0.95866 (3) t is 11.79, p-value is 0, reject (4) -.84577 + 2*1.478*c(-1,1) [1] -3.80177 2.11023 (5) fail to reject. (6) No. The sign is negative but the magnitude is insignificant both in that you cannot reject 0 and the confidence interval only includes values of little practical importance. (7) > t= (.81866-1)/.06943 > t [1] -2.611839 reject. #-------------------- Question 9 (1) d (2) c (3) a (4) b (5) d (6) b (7) a (8) d #-------------------- Question 10 (1) T (2) F (3) T (4) F (5) F (6) F (7) T (8) T (9) F (10) T (11) T (12) T (13) T (14) T (15) T (16) T (17) T (18) F (19) F (20) F #-------------------- Question 11 with p1=.1 we have R 0 1 0 .25 .25 Q 1 .45 .05 (1) p(Q=1,R=1)= p(Q=1)p(R=1 | Q=1) = .5*.1 = .05. (2) p(R=1)= p(Q=0,R=1)+p(Q=1,R=1) = .5*.5+.5*.1 = .3. (3) p(Q=1|R=1) = p(Q=1,R=1)/p(R=1) = .05/.3 = .167. (4) p(Q=1 | R=0)=p(Q=1,R=0)/p(R=0) = .45/.7 = .643. (5) If he says yes, the investigator would guess he answered the digit question. If he said no, it is still not too different from 50-50 on the question. So, the respondent does seem pretty safe answering yes to the drug question of that is the truth. (6) p = p(Q=0,R=1) + p(Q=1,R=1) = .25 + .5p1. Also useful to note that p1 = 2p-.5. (7) 450/1000 = .45 (8) 2*.45-.5 = 0.4 (9) yes, the estimator for p1 is a linear function of the estimator for p. (10) se = sqrt(phat*(1-phat)/1000) > se [1] 0.01573213 phat + 2*se*c(-1,1) [1] 0.4185357 0.4814643 (11) > cip [1] 0.4185357 0.4814643 > 2*cip-.5 [1] 0.3370715 0.4629285 (12) > p1hat = 200/500 > p1hat [1] 0.4 > se1 = sqrt(p1hat*(1-p1hat)/500) > cip1 = p1hat + 2*se1*c(-1,1) > cip1 [1] 0.3561822 0.4438178 (13) The one where you know the questions (0.3561822 0.4438178) is smaller. It makes sense that with more information your ci should be smaller! #-------------------- Question 12 12.1 20 12.2 59 12.3 25 12.4 34 12.5 22 12.6 25