Chapter 24: Multi-Factor Studies

Chapter 24: Multi-Factor Studies
Lecture 15
April 19, 2007
Psychology 791
Slide 1 of 20
Today’s Lecture
■
Overview
ANOVA with more than two factors.
◆
Not much different from a general models perspective.
◆
More interactions to test and interpret.
● Today’s Lecture
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
Slide 2 of 20
Adding Additional Categorical IVs
Overview
■
A Two-Way ANOVA is an ANOVA model with two factors.
■
Let us now look at higher order models, those models with
additional factors.
■
These models are different from the last few models that we
looked at in that everything in the model is a FACTOR, as
opposed to a covariate or blocking variable.
Multi-Factor Studies
● The Model
● Three-Factor Model
● Defining Each Parameter
● Design Matrix?
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
Slide 3 of 20
The Model
■
When we look at this model on the next slide, it will look
familiar.
■
Each of the greek letters is the same as the ANCOVA model
we learned last Tuesday.
■
The difference is that our γ is going to represent a factor
instead of a covariate.
■
As you can see with model building, there is a sort of
progression with the greek letters when you add them.
Overview
Multi-Factor Studies
● The Model
● Three-Factor Model
● Defining Each Parameter
● Design Matrix?
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
Slide 4 of 20
Three-Factor Model
■
Here is the Model:
Overview
Yijk = µ··· + αi + βj + γk + (αβ)ij + (αγ)ik + (βγ)jk + (αβγ)ijk
Multi-Factor Studies
● The Model
● Three-Factor Model
● Defining Each Parameter
● Design Matrix?
■
Where:
■
■
µ··· is overall mean
P
αi constant with
αi = 0
P
βj constant with βj = 0
P
γk constant with γk = 0
■
sum of all interaction terms is 0 also across all levels
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
■
Conclusion
■
Slide 5 of 20
Defining Each Parameter
■
Overview
Multi-Factor Studies
● The Model
● Three-Factor Model
How each parameter is defined is the same as before
(except there is more of them)
PPP
µijk
µ··· =
abc
● Defining Each Parameter
● Design Matrix?
αi = µi·· − µ···
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
βj = µ·j· − µ···
γk = µ··k − µ···
(αβ)ij = µij· − µi·· − µ·j· + µ···
(αγ)ik = µi·k − µi·· − µ··k + µ···
(βγ)jk = µ·jk − µ·j· − µ··k + µ···
(αβγ)ijk = µijk − µij· − µi·k − µ·jk + µi·· + µ·j· + µ··k − µ···
Slide 6 of 20
Design Matrix?
■
What would the Design Matrix look like for a 2X3X2 Full
Factorial Model
Overview
Multi-Factor Studies
● The Model
● Three-Factor Model
● Defining Each Parameter
● Design Matrix?
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
Slide 7 of 20
Three-Way Interaction
■
The hardest part about this model is interpreting a three way
interaction.
■
When interpreting this interaction, think of it as interpreting a
number of two-way interactions at the same time.
■
You need pick one variable of the three variables, then
interpret each of the two way interactions at each level of this
variable.
Overview
Multi-Factor Studies
Three-Way Interaction
● Three-Way Interaction
● Three Factor Example
● Analysis
● Plots
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
Slide 8 of 20
Three Factor Example
■
Overview
Multi-Factor Studies
Three-Way Interaction
● Three-Way Interaction
● Three Factor Example
● Analysis
● Plots
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
From Kutner et al. (p. 1025):
”Assemblers in an electronics firm will attach 12
components to a newly developed ‘board’ that will be
used in automatic-control equipment in manufacturing
plants. An operations analyst conducted an experiment
to study the effects of three factors on the mean time to
assemble a board. Factor A was the gender of the
assembler (male=1, female=2), factor B was the
sequence of assembling the components (1, 2, or 3),
and factor C was the amount of experience by the
assembler (under 18 months = 1, over 18 months = 2).
Randomization was used to assign 15 assemblers of
each gender with a given amount of experience to each
of the three assembly sequences, with each sequence
assigned to five assemblers. After a learning period,
the total time (in minutes) to assemble 50 boards was
observed.”
Slide 9 of 20
*all main effects, two-factor interactions, and three factor int
proc glm data=multifactor;
class gender sequence experience;
model time=gender|sequence|experience/solution;
lsmeans gender|sequence|experience / adjust=tukey;
run;
9-1
Analysis
The GLM Procedure
Dependent Variable: time
Source
Model
Error
Corrected Total
DF
11
48
59
R-Square
0.959416
Source
gender
sequence
gender*sequence
experience
gender*experience
sequence*experience
gender*sequen*experi
Sum of
Squares
973645.933
41186.000
1014831.933
Coeff Var
2.760738
DF
1
2
2
1
1
2
2
Mean Square
88513.267
858.042
Root MSE
29.29235
Type III SS
540360.6000
49319.6333
542.5000
382401.6667
91.2667
911.2333
19.0333
F Value
103.16
Pr > F
<.0001
time Mean
1061.033
Mean Square
540360.6000
24659.8167
271.2500
382401.6667
91.2667
455.6167
9.5167
F Value
629.76
28.74
0.32
445.67
0.11
0.53
0.01
Pr > F
<.0001
<.0001
0.7305
<.0001
0.7457
0.5914
0.9890
Slide 10 of 20
3-Way Interactions
Slide 11 of 20
2-Way Interactions
Slide 12 of 20
Main Effects
Slide 13 of 20
Fitting Your Model
■
The idea of model fitting is fairly important once you start
using multiple factors.
■
The more parameters you fit, the more degrees of freedom
you lose.
■
When you think about these multiple factor studies, you want
to include in the model all the higher level interactions terms
that are significant and each main effect.
■
A note: There is a hierarchy to these models.
Overview
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
● Fitting Your Model
● Four Factor Study
● Four Factor Study Example
Testing Effects
Testing Contrasts
Conclusion
◆
If you include the three-way interaction, you must include
all two-way interaction terms.
Slide 14 of 20
Four Factor Study
Overview
■
Once you get to a four factor study, it gets a little trickier.
■
While you may want to fit a 4-way interaction, a major
problems comes in when you try to interpret it.
■
It becomes really difficult to understand variable interactions
in four-way and higher ANOVA models.
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
● Fitting Your Model
● Four Factor Study
● Four Factor Study Example
Testing Effects
Testing Contrasts
Conclusion
Slide 15 of 20
Four Factor Study Example
■
When fitting this model, you then should start with all main
effects, two-way interactions, and three-way interactions
■
Then, reduce the model until all interactions included are
significant (and keep in all lower order terms)
■
Remember the Heirarchy!
■
If you include a three way interaction, you must include all
two-way interactions below it...
Overview
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
● Fitting Your Model
● Four Factor Study
● Four Factor Study Example
Testing Effects
Testing Contrasts
Conclusion
Slide 16 of 20
Testing Effects
■
By now, you guys should be pros at testing each of the
model effects.
■
Nothing changes here in terms of model testing, the
difference is in the NUMBER of tests that you need to
perform
■
Each effect (whether it is main effect or interaction) is tested
by an F-test
■
Look at what is printed out (in Type III SS), if it is significant,
then there is a significant effect
■
Look at Table 24.6 on page 1010
Overview
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
Testing Effects
● Testing Effects
● Partitioning Table
Testing Contrasts
Conclusion
Slide 17 of 20
Partitioning Table
■
Look at Table 24.5 on page 1006.....
Overview
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
Testing Effects
● Testing Effects
● Partitioning Table
Testing Contrasts
Conclusion
Slide 18 of 20
Contrasts
■
Looking at Contrasts becomes the same process as in a
two-factor study.
■
Just do what you did before.
Overview
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
● Contrasts
Conclusion
Slide 19 of 20
Ending Thoughts
■
When you start to get into models that have more factors,
you are just adding more things to you model.
■
We are just building upon all of our knowledge from before.
■
This baby step adding another factor, but our though process
remains the same.
Overview
Multi-Factor Studies
Three-Way Interaction
Model "fitting"
Testing Effects
Testing Contrasts
Conclusion
● Ending Thoughts
Slide 20 of 20