Class Notes, Chapter 14
Factorial Experiments: Two or more factors
Reading: 14.1 - 14.4
(7) CRCF two factors
Completely Randomized Complete Factorial Design
- Fixed Effects (Model I)
- 2 factors/manipulations/independent variables (e.g. time, temperature)
- 1 measure/dependent variable (e.g. yield)
- Complete factorial means all levels of factor A crossed with
all levels of factor B: all combinations (no empty cells)
Traditional set of questions (effects):
- Does treatment factor A affect the outcome?
- Does treatment factor B affect the outcome?
- Is there an interaction between factors A and B?
Traditional set of questions (means):
- Is there a difference among the A marginal means?
- Is there a difference among the B marginal means?
- In the joint table, are the differences of cell means different?
The Major Effects:
- The main effect of A
- The main effect of B
- The interaction of A and B (notated A x B)
Model using Effects Coding
- model is: effects
the major effects are encoded in the model, so hypotheses are effects = 0:
Model using Means Coding
- model is: group membership
- questions, effects or other comparisons, are encoded in the
Hypotheses
Here is a useful matrix operator:
- Kronecker product
- Example - suppose there are 2 levels of treatment A
and 2 levels of treatment B
The main effect of A - a test on the A marginals
- the hypothesis for means coding could be:
But using the cells in the two-factor design, we have to combine across
levels of B:
The main effect of B would be:
The interaction would be:
Testing the hypotheses - setting up the F ratios
Calculation formulas:

Anova Table
| Source |
SS |
df |
MS |
F |
| Treatment, A |
SSA |
dfA |
MSA |
F = MSA/MSE |
| Treatment, B |
SSB |
dfB |
MSB |
F = MSB/MSE |
| Interaction, A x B |
SSAB |
dfAB |
MSAB |
F = MSAB/MSE |
| Error, E |
SSE |
dfE |
MSE |
|
Interpretation:
- If the interaction is significant, then (properly) the A and B
conditionals should be tested, instead of the main effects. This
is done by restricting tests to single levels of one factor.
- Can do contrasts, as with the single-factor design
Graphs of means for the 2-way design:
- Parallel lines means no interaction
(8) CRCF three factors
Completely Randomized Complete Factorial Design
- Fixed Effects (Model I)
- 3 factors/manipulations/independent variables (e.g. time,
temperature, amount of catalyst)
- 1 measure/dependent variable (e.g. yield)
- Complete factorial means all levels of factor A crossed with
all levels of factor B crossed with all levels of factor C: all combinations
Traditional set of questions (effects):
- Does treatment factor A affect the outcome?
- Does treatment factor B affect the outcome?
- Does treatment factor C affect the outcome?
- Is there an interaction between factors A and B?
- Is there an interaction between factors A and C?
- Is there an interaction between factors B and C?
- Is there an interaction between factors A, B and C?
Translate to means:
- Is there a difference among the A marginal means?
- Is there a difference among the B marginal means?
- Is there a difference among the C marginal means?
- In the joint AB table, are the differences of cell means different?
- In the joint AC table, are the differences of cell means different?
- In the joint ABC table, are the differences of differences of cell means different?
The Major Effects:
- The main effect of A
- The main effect of B
- The main effect of C
- The A x B interaction
- The A x C interaction
- The B x A interaction
- The A x B x C interaction
Model using Effects Coding
- yijkl = mu + alphai + betaj +
gammak +
alpha-betaij + alpha-gammaik + beta-gammajk
+ alpha-beta-gammaijk + epsilonijkl
- model is: effects
the major effects are encoded in the model, so hypotheses are effects = 0:
- H0: alphai = 0
- H0: betaj = 0
- H0: gammak = 0
- H0: alpha-betaij = 0
- H0: alpha-gammaik = 0
- H0: beta-gammajk = 0
- H0: alpha-beta-gammaijk = 0
Model using Means Coding
- yijkl = muijk + epsilonijkl
- model is: group membership
- questions, effects or other comparisons, are encoded in the
Hypotheses
Example of testing the major effects: suppose there are 2 levels of each
treatment, A, B, and C
Test the main effect of A (test of the A marginals)
- the hypothesis for means coding could be:
But using the cells in the three-factor design, we have to combine across
levels of B and C:
Hypotheses of the major effects for a 3-way CRCF design:
Setting up the F-tests: Each E(MS) = sigma-squared + a term specific to that effect
- Under H0 for that effect, the term = zero
- So under H0, E(MS) = sigma-squared
- and as before, you build an F-test of the effect.
Calculation formulas:
Anova table for 3-way design:
| Source |
SS |
df |
MS |
F |
| Treatment, A |
|
|
|
|
| Treatment, B |
|
|
|
|
| Treatment, C |
|
|
|
|
| Interaction, A x B |
|
|
|
|
| Interaction, A x C |
|
|
|
|
| Interaction, B x C |
|
|
|
|
| Interaction, A x B x C |
|
|
|
|
| Error, E |
|
|
|
|
Can we use the plot of an ABC design to judge the presence of an interaction: Does there
seem to be one in this plot?
The AxB interaction pattern is certainly different from level C1 to
level C2; maybe there is one. Let's do the tests and find out:
Formulas for the SS of the major effects:
Anova Table
| Source |
SS |
df |
MS |
F |
| Treatment, A |
1600 |
1 |
1600 |
72.7 |
| Treatment, B |
2500 |
1 |
2500 |
114 |
| Treatment, C |
100 |
1 |
100 |
4.55 |
| Interaction, A x B |
6400 |
1 |
6400 |
291 |
| Interaction, A x C |
1600 |
1 |
1600 |
72.7 |
| Interaction, B x C |
2500 |
1 |
2500 |
114 |
| Interaction, A x B x C |
0 |
1 |
0 |
0 |
| Error, E |
176 |
8 |
22 |
|
The three-way interaction is zero! So the point is made: visually
examining the plot of a 3-way interaction will not necessarily give you a
good idea about the magnitude of the effect. Non-parallel lines are important
for the 2-way in predicting an effect, but the 3-way is more abstract:
differences of differences of differences.
Further::
- Can do contrasts, as with the single-factor design
- Can do certain random effects designs (Model II or Mixed Model),
but not others
- Can have blocking factor(s) as before - see below
Two treatment factors and one blocking factor
- Suppose A is the blocking factor and B and C are treatment factors
- Model is: yijk = alphai + betaj +
gammak + beta-gammajk + epsiloniijk
- Added assumption: No alpha-beta, no alpha-gamma, and no
alpha-beta-gamma interactions.
- Calculate SSA, SSB, SSC, dfA, dfB, dfC as in three-way
- Calculate SS(BC) and df(BC) as in three-way
- Calculate SST and dfT as in three-way
- Calculate SSE = SST - SSA - SSB - SSC - SS(BC)
- Calculate dfE = dfT - dfA - dfB - dfC - df(BC)
- Calculate MSB, MSC, MS(BC), MSE
- Calculate f for B, C, and BC
Purpose of this design: It's really a 2-way design, but with increased
statistical precision, because the variability due to the blocks is
"removed" from the error variation, making MSE smaller.
Example 14.5 in your text (p 584) is 3 treatment factors and 1 blocking
factor - we'll discuss briefly in class.
One treatment factor and two blocking factors - often an incomplete
design
- A common example of this type of design is a Latin Square design
as in the class notes (#20), where in the example fertilizers and years were
the blocking factors, and the varieties of wheat were the treatment
factor. The design was incomplete, i.e. not fully crossed.
Note about y-hats and residuals: if there is more than one
observation per cell, the y-hat is the y-bar is the group mean, and the
residual is the observation minus the group mean. If there is only one
observation per cell, there is no y-bar, so the y-hat has to be calculated
in a different way.
Class Home