Department of Statstcs Unversty of Toronto STA35HS / HS Desgn and Analyss of Experments Term Test - Wnter - Soluton February, Last Name: Frst Name: Student Number: Instructons: Tme: hours. Ads: a non-programmable calculator and a two-sded 8.5'' '' ad sheet. If you do not understand a queston, or are havng some other dffculty, do not hestate to ask your nstructor or T.A for clarfcaton. There are 3 pages ncludng ths page. The last pages are statstcal tables. Please check that you are not mssng any page. Show all your work and answer n the space provded, n nk. Pencl may be used, but then remarks wll not be allowed. Use back of pages for rough work. Total pont: Good luck!!! Queston 3 Total Max 6 3 Score
Queston A study was conducted to test the mpact of 3 fertlzers on crop yeld. The 3 fertlzers were appled to 7 plots of land n a random fashon such that each fertlzer was appled to 9 plots. a) ( mark) Name the expermental desgn that was used n plannng ths study. Ths s a completely randomzed desgn. b) ( marks) Were randomzaton and replcaton used n ths experment? If yes, explan how? Randomzaton was used snce the fertlzers (treatments) were randomly assgned to each plot of land (expermental unt). Replcaton was used snce each fertlzer (treatment) was appled to 9 plots of land (expermental unts). c) ( marks) What statstcal model would you use for ths study desgn? The model s one-factor fxed effect model descrbed by the followng equaton: Y = + τ + ε, =,,3, j =,...,9 Where s the overall mean yeld τ s the effect of the th fertlzer ε s the random or expermental error d) (3 marks) What assumptons dd you make n part (c)? We assume that ε are..d. wth dstrbuton that s N(, σ ). e) (5 marks) Set up one set of orthogonal contrasts that mght be used n ths study. Snce there are three treatments a set of orthogonal contrast wll contan two orthogonal contrasts. An example of such a set s:
+ 3 Ψ = and Ψ = 3 Checkng for orthogonalty 3 Sum c -.5 -.5 d - c -.5.5 d f) (3 marks) For each contrast n (d), state the null and alternatve hypotheses to whch the contrast corresponds. The frst contrast test whether the mean crop yeld wth the frst fertlzer s the same as the average mean crop yeld wth the other two fertlzers. The hypotheses are: H H a + 3 : + 3 : = The second contrast test whether the mean crop yeld wth the second fertlzer s the same as the mean crop yeld wth the thrd fertlzers. The hypotheses are: H H a : 3 = : 3 g) ( marks) Suppose that the 7 plots were selected at random from a bg feld contanng many more plots of land. How would your answers to parts (a), (c) and (d) change? Explan! If the plots of land were selected at random the desgn wll stll be a completely randomzed desgn and the model wll stll be one-factor fxed effect model. So the answers to parts (a), (c) and (d) wll not change. However, f the fertlzers were selected at random from say all avalable fertlzers n the market. Then the model wll be one-factor random effect model. The equaton of the model wll be the same; but, there wll be two addtonal assumptons: () τ are statstcally ndependent of the ε N, σ τ () the τ are..d ( ) 3
Queston Four dfferent desgns for a dgtal computer crcut are beng studed to compare the amount of nose present. The results are shown n the table bellow: Crcut Desgn Nose Observed Mean Std Dev 9 9 3 8 9. 7.79 8 6 73 56 8 7.. 3 7 6 5 35 5 36.6.59 95 6 83 78 97 79.8.5 SS Total = 99, SS Treat = a) (5 marks) Explan what knd of expermental desgn was used n ths experment. Are the effects of the factor random or fxed? What s the statstcal model you would use to analyze ths data? Ths s a completely randomzed desgn. The effects of the factor (crcut desgn) are fxed snce they were specfed by the expermenter rather than beng selected at random. The statstcal model we would use to analyze ths data s a one-factor fxed effect model descrbed by the equaton: Y = + τ + ε, =,,3,, j =,...,5 Where s the overall mean yeld τ s the effect of the th crcut desgn ε s the random or expermental error b) (9 marks) Construct the ANOVA table for ths experment. Fnd the P-values. The ANOVA table produced by SAS s gven below: Source DF SS MS F-rato P-value Treatment 3.78 <. Error 6 99 8.35 Total 9 99
c) (3 marks) Do the three crcut desgns have the same mean nose observed? Use α = %. The hypotheses of nterests here are: H H a : τ = τ = τ 3 = τ = : at least oneτ The test statstc obtaned from the ANOVA table produced n part (b)s: F obs =. 78 whch has an F(3,6) dstrbuton. Snce the P-value <. < α =. we reject the null hypothess and conclude that we have sgnfcant evdence that the three crcut desgns do not have the same mean nose observed. d) (5 marks) It was suspected before the experment that crcut desgns and are smlar n the nose present. Test ths hypothess usng a t-test and α = 5%. The hypotheses to test here are: H H a : τ = τ : τ τ or H H a : τ τ = : τ τ Further, we know that an unbased estmate of the dfference between two treatment effects s Y Y j and that Y + Y j ~ N τ τ j, σ. r rj Therefore, the test statstcs s: t = Y MS Y j E + r rj whch has a t(n-a) dstrbuton. 7 79.8 Substtutng all the values we get t obs = =. wth df = 6. 8.35 + 5 5 The P-value can be estmated as follows: ( t( 6) > t ) = P( t( 6) >.). P value = > P obs Snce P-value s very large we cannot reject H and we able to conclude that that crcut desgns and are not dfferent n the nose present. 5
e) (5 marks) How many dfferent orthogonal contrasts you can create smultaneously n ths experment? Create two contrasts, one to test the queston n part (d), the other to test whether the mean response for crcut desgn 3 s the same as for the average for crcut desgn and. Are these contrasts orthogonal? Snce the factor (crcut desgn) has a = levels, a - = 3 dfferent orthogonal contrasts can be created smultaneously. The contrast to test the queston n part (d) s: Ψ =. The contrast to test whether the mean response for crcut desgn 3 s the same as for + the average for crcut desgn and s: Ψ = 3. Checkng for orthogonalty 3 Sum c - d -.5 -.5 c -.5.5 d So yes, these contrasts are orthogonal. f) (8 marks) Calculate SS for both contrasts n part (e). Test the hypothess regardng these two contrasts usng F-test. How do they compare wth part (c)? Contrast : the hypotheses are H = vs H :. The sum of square of the contrast s: : a SS contrast a ( cy ) ( 7 79.8) = = a c / = r = ( / 5) + ( / 5) SSContrast /. The test statstcs s: F obs = = =. 37 wth df = (, 6) MS 8.35 The P-value can then be estmated as follow: E ( F(,6) > F ) = P( F(,6) >.37). P value = P obs >. So cannot reject H. =. Note, the F statstcs n ths case s smply the square of the t statstcs from part (d). Contrast : the hypotheses are: ( + )/ = vs H : ( + )/ The sum of square of the contrast s: SS = 889. 63 H. : 3 a 3 contrast 889.63 The test statstcs s: F obs = = 6. 53 wth df = (, 6) 8.35 P value = P F,6 > 6.53 <.. The P-value can then be estmated as follow: ( ( ) ) So we reject H. Combnaton of these two results s n agreement wth (c), meanng that not all means are equal (two may be). 6
g) (3 marks) How can you calculate the SS for the contrast comparng crcut desgn wth the average of the other three wthout usng the formula for SS contrast? Do t! The contrast comparng crcut desgn wth the average of the other three s orthogonal to the two contrasts n part (e), therefore formng a set of orthogonal contrasts. For any set of orthogonal contrasts we have that SS. Treat = SScontrast + SScontrast + + SScontrast a- Therefore, the SS of ths contrast s SS 3 SS SS =. 889.63 = 69.7 contrast = Treat contrast SScontrast Below are plot of the resduals versus the ftted values and a normal quantle plot of the resduals for the model used to analyze the data above. z - - -3 3 5 6 7 8 ftted z - - -3 5 5 5 75 9 95 99 Normal Percent l es 7
h) (5 marks) What are the assumptons of the model used to construct the ANOVA table n part (c)? Comment on the valdty of these assumptons. The assumptons are: The model form s as specfed n part (a), that s E(Y ) = + τ. The resduals, ε, are..d. N(, σ ). Based on the resdual plots above, t looks lke all of these assumptons are vald for ths data. ) (3 marks) Based on the plots above are there any outlers n ths data? Explan. Yes, t looks lke there s one outler n ths data. It appears n the plot of the resduals versus ftted value as the rght-most and lowest pont (.e., large negatve resdual). In addton, t appears on the normal quantle plot as the lowst pont on the left. Lookng at the data we see that the value of 5 th observaton taken on crcut desgn s 8 whch s much smaller than the rest of the observatons, suggestng agan that ths may be an outler. Queston 3 An experment was conducted to study the lfe (n hours) of two dfferent brands of batteres (brand A and B) n three dfferent devces (rado, camera and portable DVD player). A completely randomzed two-factor factoral experment was conducted. Some SAS outputs used to analyze the data from ths experment are gven below: 8
a) (5 marks) What statstcal model was used to analyze ths data? Wrte the model and descrbe each term n the model n the context of ths study. Lst all assumptons requred for the model. Ths s a two-factor fxed-effect model. Its equaton s: Y k = + α + β j + γ + ε k where: Overall mean α Battery effect (factor A) of level =, β j Devce effect (factor B) of level j =,, 3 γ Interacton effect of batter (factor A) level and devce (factor B) level j Expermental error ε The assumptons of the model are: ε k are..d. N(, σ ) In order to obtan unbased estmators, we requre that: a = b j= a = α = β = j b γ = γ j= = 9
b) ( marks) Create the ANOVA table that was used n the analyss of ths data usng the results from the SAS output above, ncludng P-values. The ANOVA table s: Source DF SS MS F-rato P-value Factor A Factor B Interacton A B.883.5.867.883.5.83 9.33 3.75.8. <..63 Error 6.55.8583 Total 3.85 c) (5 marks) Plot an nteracton plot usng the cell means as gven n the output above. Use dfferent symbols/colors for the dfferent battery brand. What do you learn from ths plot? Here s an nteracton plot produced by MINITAB. 9.5 9. 8.5 Interacton Plot (data means) Battery A B 8. Mean 7.5 7. 6.5 6. 5.5 Camera DVD Devce Rado From the plots, t appears that there s no nteracton between battery type and devce. Further, for every devce the mean lfetme for battery B appears to be larger than that of batter A suggestng that there mght be a battery effect. Fnally, t looks lke batteres used n DVDs have the smallest lfetme whle batteres used n Rados last the longest. Ths, n turn, suggests that there mght be a devce effect.
d) (9 marks) Do battery brand and devce type nteract? Is there any dfference n lfe tme of the two battery brands? Does devce type have any effect on battery lfe tme? Answer these three questons, f approprate, usng sgnfcant level 5%. State each queston n terms of the model and state your conclusons n plan language n the context of ths experment. Frst we need to test for nteracton. The hypotheses of nterest are: H : γ =, for all, j vs H a : at least one γ. From the ANOVA table we get the test statstcs F obs =.8, wth P-value =.63, therefore we cannot reject the null hypothess and we conclude that there s no sgnfcant nteracton between battery type and devce type. Snce there s no nteracton we can proceed to test for man effects of battery and devce. Man effect of battery: The hypotheses f nterest are: H : α =, for =, vs H a : at least one α. From the ANOVA table we get the test statstcs F obs = 9.33, wth P-value =.. Hence, we can reject the null hypothess at α = 5% and we conclude that there s a sgnfcant effect of battery type on lfetme. Note, that ths s moderate evdence of sgnfcance as we would not be able to reject the null hypothess at α = %. Man effect of devce: The hypotheses f nterest are: H : β =, for =,, 3 vs H a : at least one β. From the ANOVA table we get the test statstcs F obs = 3.75, wth P-value<.. Hence, we have strong evdence to reject the null hypothess and we conclude that there s a sgnfcant effect of devce type on lfetme. e) ( marks) If the researchers assumed (from experence) before the experment that battery brand and devce type don t nteract, how would ths affect the model used to analyze ths data? Wrte the model and descrbe each term n the context of ths study. In ths case the model wll not nclude an nteracton effect term, that s, the model equaton wll be: Y k = + α + β j + ε k (addtve model) where: s the overall mean, α are effects of battery, β j are effects of devce and ε are expermental errors.
f) (5 marks) Create the ANOVA table that would be used n part (e), ncludng P-value, and test the man effects. Are the results consstent wth the orgnal model used n the study? Snce we omt the nteracton term from the model, both the degrees of freedom and sums of squares of the nteracton term n the ANOVA table go to the error. The ANOVA table s then: Source DF SS MS F-rato P-value Factor A Factor B.883.5.883.5.7 5.5. < P <.5 <. Error 8.59667.758 Total 3.85 END!