Analysis of Variance

advertisement
Analysis of Variance
Standard methods for comparing
treatments in designed experiments
Form of analysis depends on type of
experiment:
– completely randomised design
– Randomised block design
Most general methods of analysis in
MINITAB use the GLM (General
Linear Model) Procedure
1
Completely Randomised Design
One-Way Analysis of Variance
(can also be used to compare samples from
K different populations)
Here, we will focus on comparing K
treatments in a properly conducted
experiment
– randomisation + replication
As well as overall test of significance
may be interested in specific
comparisons, eg with a control
2
Sugar weight experiment
Boxplot of weight vs treat
100
90
80
weight
3 treatments to reduce
sugar content
Control group
Some evidence of
different variabilities in
each group – maybe
analyse log(weight)?
70
60
50
40
A
B
C
control
treat
3
One-Way Anova Results
One-way ANOVA: weight versus treat
Source DF
treat
3
Error
8
Total
11
S = 7.747
SS
MS
1822.2 607.4
480.1
60.0
2302.3
R-Sq = 79.15%
F
10.12
P
0.004
Overall test of treatment differences with
p-value
4
Individual 95% CIs For Mean Based on
Pooled StDev
Level
N
Mean
StDev
A
3
61.833
5.278
B
3
67.500
3.637
C
3
48.900
1.800
control
3
83.233
13.991
----+---------+---------+---------+----(------*------)
(------*------)
(------*-----)
(-----*------)
----+---------+---------+---------+----45
60
75
90
5
Multiple Comparison methods
• Modification to allow for multiple testing
– Many different procedures and approaches
6
Dunnet’s for control group
Family error rate = 0.05
Individual error rate = 0.0205
Critical value = 2.88
Control = level (control) of treat
Intervals for treatment mean minus control mean
Level
A
B
C
Lower
-39.616
-33.949
-52.549
Center
-21.400
-15.733
-34.333
Upper
-3.184
2.482
-16.118
-----+---------+---------+---------+---(-----------*-----------)
(------------*-----------)
(-----------*-----------)
-----+---------+---------+---------+----45
-30
-15
0
7
Tukey Simultaneous Intervals
Tukey 95% Simultaneous Confidence Intervals
All Pairwise Comparisons among Levels of treat
Individual confidence level = 98.74%
treat = A subtracted from:
treat
B
C
control
Lower
-14.595
-33.195
1.138
Center
5.667
-12.933
21.400
Upper
25.928
7.328
41.662
--------+---------+---------+---------+(------*------)
(------*-----)
(------*------)
--------+---------+---------+---------+-30
0
30
60
8
Using GLM procedure
9
Randomised Block Experiment
Potato sprout suppressant residues
• 5 different batches of potatoes – blocks
• 4 different airing methods – treatments
• Residue of suppressent – response
A
B
C
D
1
1.6
0.9
1.2
1.5
Batch
2
2.3
1.4
1.6
1.9
Number
3
2.2
1.8
1.7
2.4
4
1.6
1.2
1.0
1.5
5
1.7
1.3
1.4
1.7
10
Two-way ANOVA
Can only fit
additive model
here as no
replication
within batches
11
Simple additive model
Two-way ANOVA: residue versus batch, method
Source
batch
method
Error
Total
DF
4
3
12
19
S = 0.1345
SS
1.5670
1.2255
0.2170
3.0095
MS
0.391750
0.408500
0.018083
F
21.66
22.59
P
0.000
0.000
R-Sq = 92.79%
Large batch effects – blocking worthwhile
12
Model & Assumptions
RESPONSE =
Overall Mean
+
Treatment Effect
+ Block Effect
+
Random Variability
• Additivity of effects
• Errors normally distributed
• Same error variance for all treatment/block
combinations
13
Two-Way Anova with Interaction
• 40 sheep – given additives for magnesium
deficiency
• 2 countries of origin (Spanish/Greek)
• 2 grades (coarse/powder)
Boxplot of bioavailability vs nationality, Grade
35.0
bioavailability
32.5
30.0
27.5
25.0
Grade
nationality
Coarse
Powder
Greek
Coarse
Powder
Spanish
14
GLM – Interaction Model
Analysis of Variance for bioavailability, using Sequential SS
for Tests
Source
nationality
Grade
nationality*Grade
Error
Total
S = 2.11404
DF
1
1
1
36
39
Seq SS
24.025
139.876
19.600
160.890
344.391
Adj SS
24.025
139.876
19.600
160.890
Seq MS
24.025
139.876
19.600
4.469
F
5.38
31.30
4.39
P
0.026
0.000
0.043
R-Sq = 53.28%
15
Interaction Plot (fitted means) for bioavailability
Main Effects Plot (fitted means) for bioavailability
nationality
32
Grade
nationality
Greek
Spanish
31.5
31
30
30.5
30.0
Mean
Mean of bioavailability
31.0
29.5
29
28
29.0
28.5
27
28.0
26
27.5
Coarse
Greek
Spanish
Coarse
Powder
Grade
Powder
Normal Probability Plot of the Residuals
Residuals Versus the Fitted Values
(response is bioavailability)
(response is bioavailability)
99
5.0
95
90
2.5
70
Residual
Percent
80
60
50
40
30
0.0
20
-2.5
10
5
1
-5.0
-2.5
0.0
Residual
2.5
5.0
-5.0
27
28
29
30
Fitted Value
31
32
16
Download