Download presentation
Presentation is loading. Please wait.
Published byEleanore Hill Modified over 8 years ago
1
1 Topic 14 – Experimental Design Crossover Nested Factors Repeated Measures
2
2 Overview We will conclude the course by considering some different topics that can arise in a multi-way ANOVA, as well as some other miscellaneous topics. Some of these are discussed a little bit in Chapters 21, 23, and 24. As there will be no HW covering this topic, the coverage on the final exam will be limited to identification and/or discussion of concepts.
3
3 Types of Designs Crossed Factors Nested Factors Repeated Measures
4
4 Crossover Design Factors A and B are considered crossed if every level of B occurs with every level of A. Note: The two-way and three-way ANOVA that we have discussed to this point has generally had crossed factors (obs. in every cell). Can investigate interactions assuming that we have replication (multiple obs. per cell). Basically, we have only been doing crossover designs so far!
5
5 Diagrams of Crossover Design
6
6 Example We want to examine three different drugs to determine their effects on blood pressure. We will have 12 men and 12 women on each drug, and also have a control group as well. Drug and Gender are crossed factors (and are both fixed effects as well).
7
7 ANOVA Table SourceDF DRUG___(fixed, 4 levels) GENDER___ (fixed, 2 levels) DRG*GNDR___ (fixed) Error___ Total95
8
8 Nested Design Factor B is considered to be nested within Factor A if each level of B occurs with only one level of Factor A. Can arbitrarily number the levels of B Cannot investigate interactions. Denoted B(A) instead of B in ANOVA table.
9
9 Example (Nested) We want to compare two fertilizers. We have a field that is divided into 4 sections and each section is randomly assigned one of the two fertilizers (each is assigned twice). After two weeks, three plants from each section are dug up and the number of root tips for each plant is obtained.
10
10 Example (Nested) Factors include Fertilizer Section (nested within Fertilizer) – also this is the Experimental Unit! Plant (nested within Section, Fertilizer) – note that this effect will actually be the error term since there is nothing “below” it. Fertilizer12 Section1324 Plant123456789101112 Response182217222825171514121516
11
11 Example (Nested) Are the observations (plants) within a section independent? This is an example of subsampling (a form of “repeated measures” that results in a nested design). By subsampling, we reduce the variance associated with our experimental units (the sections). But as we will see, it does not gain DF for testing the fertilizer effect.
12
12 Degrees of Freedom 12 observations 11 total DF. Have variability between sections and variability within sections: Only three DF for between sections variability (since we have four sections) This leaves eight DF for variability within sections (Error term in our model) The “between section” variation can be divided up into two parts 1 DF for Treatment 2 DF for Section(Treatment)
13
13 Statistical Model
14
14 Nested Effects Key Point: Nested effects are generally considered RANDOM. In our example, want results to apply to all sections and all plants. So we need to look at EMS to determine tests: Source Type III Expected Mean Square fert Var(Error) + 3 Var(sect(fert)) + Q(fert) sect(fert) Var(Error) + 3 Var(sect(fert))
15
15 Expected Mean Squares As you can see from the EMS, the Fertilizer effect will be tested over Sect(Fert). Thus while sampling more plants in each section is good in the sense that we get a “better” estimate for each section, it does not improve the degrees of freedom for testing whether there is a fertilizer effect. One would need to add sections to do that. Section effect will be tested over error. Sampling more plants does give a more precise estimate for the sections and more DF for this test.
16
16 SAS Coding Nested effects use parentheses in the coding as described and are included in the random statement.
17
17 Output
18
18 Correct Tests
19
19 Conclusion NO significant differences are shown between the fertilizers. Two notes: Failing to recognize that this is a nested design will result in an incorrect conclusion that there is a fertilizer effect. We certainly can’t say from this that there is NOT a fertilizer effect – the power for detecting differences in fertilizer will be very low (2 DF error for that test).
20
20 A More Complex Example Eight subjects are used to try to determine the effectiveness of two different drugs. Four subjects receive Drug #1 first; the other four receive Drug #2 first. There is a washout period, and then they receive the other drug during the second period of the study.
21
21 Design Chart & Factors Factors include Order of Drugs Subject (nested within order) Period (crossed with both subject and order) Note: Drug effect is ______________
22
22 Degrees of Freedom 16 observations 15 total DF. BETWEEN: 8 subjects 7 DF associated to variability between subjects. 1 DF associated to Order 6 DF associated to Subjects(Order) WITHIN: 8 DF remaining to assess variability within subjects. 1 DF associated to Period 1 DF associated to Order*Period 6 DF associated to Period*Subject(Order) Order*Period is the DRUG effect. Period*Subject(Order) must be considered as our ERROR term (not enough DF to look at that interaction).
23
23 Statistical Model
24
24 SAS Coding
25
25 Output
26
26 Conclusions There seems to be some kind of DRUG effect (represented by the order/period interaction). The actual effect is not yet clear – we must set up a contrast on the order*period interaction to examine the drug effect. We may also be able to consider LSMeans We may not have been able to see this effect as well without appropriately accounting for the other variables.
27
27 LSMeans
28
28 LSMeans / Contrast We see some groupings that we might expect: (1,4) = DRUG #1 (2,3) = DRUG #2 A contrast to consider the difference in drugs would be:
29
29 Repeated Measures Design Measurements taken on the same experimental units are by definition not independent.
30
30 Repeated Measures Design Repeated Measures – Experimental unit is measured more than once. Response variable measured on same subject over time. Several observations taken from same experimental unit at the same time (subsampling). If have repeated measures, then the experimental unit is generally considered a random factor. Sometimes we are able to keep things simple by applying a nested design. In all case EMS are used to determine correct tests.
31
31 Previous Examples Both of the previous examples involved repeated measures in the sense that: Example 1 – There were repeated measures for the sections in the sense that we measured multiple plants. Example 2 – There were repeated measures on the subjects in the sense that each subject was observed on each drug. In both cases, we used a nested design to accomplish the analysis.
32
32 One More Example Problem 21.4 from the textbook. 24 “thirsty” rats trained to press a lever to obtain water. Rats categorized into three groups of eight (slow, medium, fast) based on their initial press rate. Each rat received three different doses of a drug, along with a placebo, on separate occasions, and in a random order. One hour later after the dose, drugs received water after pressing a lever a pre-specified number of times (2 or 5) – half the rats on each #.
33
33 Example Primary Research Question: Does the drug affect the LPR (lever press rate)? Response variable is the lever press rate (total number of presses divided by time in seconds). Crossed factors include DRUG, # of presses (PRS), and initial press rate (IPR). RAT is a random effect and we have repeated measures on the rats. RAT is nested – within the IPR*PRS effect. (See table page 623).
34
34 ANOVA Table / DF SourceDF IPR 2(Fixed) PRS 1(Fixed) IPR*PRS 2(Fixed) Rat(IPR*PRS) 18(Random) Drug 3(Fixed) Drug*IPR 6(Fixed) Drug*PRS 3(Fixed) Drug*IPR*PRS 6(Fixed) Drug*IPR*PRS*RAT54(Error)
35
35 SAS Code
36
36 ANOVA Table Are any of the F tests correct?
37
37 Expected MS F Tests from Drug on down will be correct. Others should be tested over MS(Rat)
38
38 Further Analysis With respect to “drug”, everything is fairly straight forward. Appears to be an important interaction with the number of presses. So examine from the interaction perspective. Start with “sliced” LSMeans:
39
39 Further Analysis Though both are significant, there appears to be a much bigger drug effect when 5 presses are required. We can see this by examining the LSMeans themselves: The highest level of drug decreases the lever press rate (rats need water more?).
40
40 Other questions Is the # of presses required important? Yes, particularly in its interaction with the Drug. Definitely an observable main effect as well (test over Rat, F = 634) Is the IPR important? Correct to test over Rat, but F = 42.7 is still quite large. Conclusion: Yes. Could use LSMeans, make sure to use correct term as error (MSRat).
41
41 Questions?
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.