Orthogonal Linear Contrasts - Department of Mathematics

Download Report

Transcript Orthogonal Linear Contrasts - Department of Mathematics

Experimental Designs
The objective of Experimental design
is to reduce the magnitude of random
error resulting in more powerful tests
to detect experimental effects
The Completely Randomizes Design
1
2
Treats
3
…
t
Experimental units randomly assigned to
treatments
Randomized Block Design
Blocks
All treats appear once in each block
Latin Square Designs
The Latin square Design
Rows
Columns
All treats appear once in each row and each
column
Graeco-Latin Square Designs
Mutually orthogonal Squares
Definition
A Greaco-Latin square consists of two latin squares (one
using the letters A, B, C, … the other using greek letters a, b,
c, …) such that when the two latin square are supper imposed
on each other the letters of one square appear once and only
once with the letters of the other square. The two Latin
squares are called mutually orthogonal.
Example: a 7 x 7 Greaco-Latin Square
Aa
Be
Cb
Df
Ec
Fg
Gd
Bb
Cf
Dc
Eg
Fd
Ga
Ae
Cc
Dg
Ed
Fa
Ge
Ab
Bf
Dd
Ea
Fe
Gb
Af
Bc
Cg
Ee
Fb
Gf
Ac
Bg
Cd
Da
Ff
Gc
Ag
Bd
Ca
De
Eb
Gg
Ad
Ba
Ce
Db
Ef
Fc
Incomplete Block Designs
Comments
• The within block variability generally increases
with block size.
• The larger the block size the larger the within
block variability.
• For a larger number of treatments, t, it may not be
appropriate or feasible to require the block size, k,
to be equal to the number of treatments.
• If the block size, k, is less than the number of
treatments (k < t)then all treatments can not appear
in each block. The design is called an Incomplete
Block Design.
Balanced Incomplete Block Design.
1. if all treatments appear in exactly r blocks.
• This ensures that each treatment is estimated with
the same precision
• The value of l is the same for each treatment pair.
2. if all treatment pairs i and i* appear together in exactly
l blocks.
• This ensures that each treatment difference is
estimated with the same precision.
• The value of l is the same for each treatment pair.
Some Identities
Let b = the number of blocks.
t = the number of treatments
k = the block size
r = the number of times a treatment appears in the
experiment.
l = the number of times a pair of treatment appears together
in the same block
1. bk = rt
•
Both sides of this equation are found by counting the
total number of experimental units in the experiment.
2. r(k-1) = l (t – 1)
•
Both sides of this equation are found by counting the
total number of experimental units that appear with a
specific treatment in the experiment.
BIB Design
A Balanced Incomplete Block Design
(b = 15, k = 4, t = 6, r = 10, l = 6)
Block
1
4
Block
6
1
2
3
2
1
4
3
2
4
5
6
Block
11
3
4
5
1
3
5
6
5
6
7
1
2
3
6
12
2
3
4
6
3
4
6
8
1
3
4
5
13
1
2
5
6
1
2
3
5
9
2
4
5
6
14
1
3
4
6
1
2
4
6
10
1
2
4
5
15
2
3
4
5
An Example
A food processing company is interested in comparing the
taste of six new brands (A, B, C, D, E and F) of cereal.
For this purpose:
• subjects will be asked to taste and compare these
cereals scoring them on a scale of 0 - 100.
• For practical reasons it is decided that each subject
should be asked to taste and compare at most four of
the six cereals.
• For this reason it is decided to use b = 15 subjects and
a balanced incomplete block design to assess the
differences in taste of the six brands of cereal.
The design and the data is tabulated below:
Analysis for the Incomplete Block Design
Recall that the parameters of the design where
b = 15, k = 4, t = 6, r = 10, l = 6
Block Totals
j
1
Bj
2
258 213
3
4
258 198
5
6
170 245
7
8
225 311
9
10
168 245
11
12
199 247
13
14
15
G
228 241
316
3522
Treat Totals and Estimates of Treatment Effects
Treat
Treat Total (Ti)
(A)
(B)
(C)
(D)
(E)
(F)
501
600
795
821
571
234
j(i) Bj/k
572
578.25
624.5
603.5
595.25
548.5
Diff = Qi
-71
21.75
170.5
217.5
-24.25
-314.5
Treat Effects (i)
-7.89
2.42
18.94
24.17
-2.69
-34.94
 j (i ) denotes summation over all blocks j containing treatment i.
i 
Qi
t 1
Anova Table for Incomplete Block Designs
Sums of Squares
 yij2 = 234382
 Bj2/k = 213188
 Qi2 = 181388.88
Anova Sums of Squares
SStotal =  yij2 –G2/bk = 27640.6
SSBlocks =  Bj2/k – G2/bk = 6446.6
SSTr
= ( Qi2 )/(r – 1) = 20154.319
SSError = SStotal - SSBlocks - SSTr = 1039.6806
Anova Table for Incomplete Block Designs
Designs for Estimating
Carry-over (or Residual) Effects of
Treatments
The Cross-over or Simple Reversal Design
An Example
• A clinical psychologist wanted to test two drugs, A
and B, which are intended to increase reaction
time to a certain stimulus.
• He has decided to use n = 8 subjects selected at
random and randomly divided into two groups of
four.
– The first group will receive drug A first then B, while
– the second group will receive drug B first then A.
To conduct the trial he administered a drug to the individual,
waited 15 minutes for absorption, applied the stimulus and
then measured reaction time.
The data and the design is tabulated below:
Period
1
2
Period
1
2
Drug
A
B
Drug
B
A
1
30
28
Group 1 (Subjects)
2
3
54
42
50
38
4
56
49
1
22
21
Group 2 (Subjects)
2
3
44
18
41
17
4
28
26
The Switch-back or Double Reversal Design
An Example
• A following study was interested in the
effect of concentrate type on the daily
production of fat-corrected milk (FCM) .
• Two concentrates were used:
– A - high fat; and
– B - low fat.
• Five test animals were then selected for
each of the two sequence groups
– ( A-B-A and B-A-B) in a switch-back design.
The data and the design is tabulated below:
One animal in the first group developed mastitis and was
removed from the study.
Period
1
2
3
Period
1
2
3
Treatment
A
B
A
Group 1 (Test animal)
1
2
3
40.8
21.5
48.4
35.2
18.4
44.4
30.8
17.8
42.7
4
50.3
45.7
43.8
Treatment
B
A
B
Group 2 (Test animal)
1
2
3
4
43.3
27.6
57.8
49.4
40.9
30.2
53.2
48.5
37.6
27.4
45.5
45.5
5
36.6
35.9
35.3
The Incomplete Block Switch-back Design
An Example
• An insurance company was interested in buying a
quantity of word processing machines for use by
secretaries in the stenographic pool.
• The selection was narrowed down to three models
(A, B, and C).
• A study was to be carried out , where the time to
process a test document would be determined for a
group of secretaries on each of the word
processing models.
• For various reasons the company decided to use an
incomplete block switch back design using n = 6
secretaries from the secretarial pool.
The data and the design is tabulated below:
Table: Time required to process the test document
together with word processing model (in brackets)
Secretary
Period
1
2
3
4
5
1
38.7(A) 21.8(B) 48.9(A) 29.9(C) 25.7(B)
2
37.4(B) 23.9(A) 43.9(C) 35.1(A) 23.1(C)
3
34.4(A) 21.7(B) 42.0(A) 24.5(C) 23.4(B)
6
22.4(C)
26.0(B)
20.9(C)
BIB incomplete block design with t = 3 treatments – A, B and
block size k = 2.
A
A
B
B
C
C
The Latin Square Change-Over
(or Round Robin) Design
Selected Latin Squares Change-Over Designs
(Balanced for Residual Effects)
Period = Rows
Columns = Subjects
Three Treatments
ABC
BCA
CAB
ABC
CAB
BCA
Four Treatments
An Orthogonal Set (use the complete Set)
ABCD
ABCD
ABCD
BADC
CDAB
DCBA
CDAB
DCBA
BADC
DCBA
BADC
CDAB
A Balanced Single Latin Square
ABCD
BDAC
CADB
DCBA
An Example
• An experimental psychologist wanted to
determine the effect of three new drugs (A,
B and C) on the time for laboratory rats to
work their way through a maze.
• A sample of n= 12 test animals were used in
the experiment.
• It was decided to use a Latin square
Change-Over experimental design.
The data and the design is tabulated below:
Table: Time required to process the test document
together with word processing model (in brackets)
Latin Square 1
Latin Square 2
Period\Rat
1
2
3
4
5
1
138 A
209 B
224 C
186 A
175 B
2
125 B
186 C
172 A
176 C
135 A
3
115 C
139 A
127 B
146 B
134 C
Latin Square 3
Latin Square 4
Period\Rat
7
8
9
10
11
1
166 A
194 B
186 C
138 A
164 B
2
152 B
180 C
130 A
154 C
128 A
3
137 C
97 A
123 B
129 B
137 C
6
201 C
163 B
101 A
12
168 C
150 B
106 A
Orthogonal Linear Contrasts
This is a technique for partitioning
ANOVA sum of squares into
individual degrees of freedom
Definition
Let x1, x2, ... , xp denote p numerical quantities
computed from the data.
These could be statistics or the raw observations.
A linear combination of x1, x2, ... , xp is defined to be
a quantity ,L ,computed in the following manner:
L = c1x1+ c2x2+ ... + cpxp
where the coefficients c1, c2, ... , cp are predetermined
numerical values:
Definition
If the coefficients c1, c2, ... , cp satisfy:
c1+ c2 + ... + cp = 0,
Then the linear combination
L = c1x1+ c2x2+ ... + cpxp
is called a linear contrast.
Examples
1. L  x 
2.
x1  x2    x p
A linear
p
1
1
1
   x1    x2      x p combination
 p
 p
 p
A linear
x1  x2  x3 x4  x5
L

contrast
3
2
1
1
1
 1
 1
   x1    x2    x3     x4     x5
 3
 3
 3
 2
 2
3. L = x1 - 4 x2+ 6x3 - 4 x4 + x5
A linear
contrast
= (1)x1+ (-4)x2+ (6)x3 + (-4)x4 + (1)x5
Definition
Let A = a1x1+ a2x2+ ... + apxp and B= b1x1+ b2x2+ ...
+ bpxp be two linear contrasts of the quantities x1, x2,
... , xp. Then A and B are c called Orthogonal Linear
Contrasts if in addition to:
a1+ a2+ ... + ap = 0 and
b1+ b2+ ... + bp = 0,
it is also true that:
a1b1+ a2b2+ ... + apbp = 0.
.
Example
Let
x1  x2  x3 x4  x5
A

3
2
1
1
1
 1
 1
   x1    x2    x3     x4     x5
 3
 3
 3
 2
 2
 x1  x2

B
 x3   x4  x5 
 2

1
1
   x1    x2   1x3  1x4   1x5
2
2
Note:
11 11 1
1
1
            - 1    1    - 1  0
 3  2  3  2  3
2
2
Definition
Let
A = a1x1+ a2x2+ ... + apxp,
B= b1x1+ b2x2+ ... + bpxp ,
..., and
L= l1x1+ l2x2+ ... + lpxp
be a set linear contrasts of the quantities x1, x2, ... , xp.
Then the set is called a set of Mutually Orthogonal
Linear Contrasts if each linear contrast in the set is
orthogonal to any other linear contrast..
Theorem:
The maximum number of linear contrasts in a
set of Mutually Orthogonal Linear Contrasts
of the quantities x1, x2, ... , xp is p - 1.
p - 1 is called the degrees of freedom (d.f.)
for comparing quantities x1, x2, ... , xp .
Comments
1. Linear contrasts are making comparisons
amongst the p values x1, x2, ... , xp
2. Orthogonal Linear Contrasts are making
independent comparisons amongst the p
values x1, x2, ... , xp .
3. The number of independent comparisons
amongst the p values x1, x2, ... , xp is p – 1.
Definition
L  a1x1  a2 x2    ap xp
denotes a linear contrast of the p means
x1 , x2 ,  , x p
If each mean, xi , is calculated from n
observations then:
The Sum of Squares for testing the Linear
Contrast L, is defined to be:
2
nL
SS L = 2 2
2
a1 +a2+...+ap
the degrees of freedom (df) for testing the
Linear Contrast L, is defined to be
dfL  1
the F-ratio for testing the Linear Contrast
L, is defined to be:
SSL
F
1
MSError
Theorem:
Let L1, L2, ... , Lp-1 denote p-1 mutually
orthogonal Linear contrasts for comparing the
p means . Then the Sum of Squares for
comparing the p means based on p – 1 degrees
of freedom , SSBetween, satisfies:
SSBetween = SSL1 + SSL2 + ... + SSLp -1
Comment
Defining a set of Orthogonal Linear Contrasts for
comparing the p means
x1 , x2 ,  , x p
allows the researcher to "break apart" the Sum of
Squares for comparing the p means, SSBetween, and
make individual tests of each the Linear Contrast.
The Diet-Weight Gain example
x1  100.0, x2  85.9, x3  99.5,
x4  79.2, x5  83.9, x6  78.7
The sum of Squares for comparing the 6
means is given in the Anova Table:
Five mutually orthogonal contrasts are given below
(together with a description of the purpose of these
contrasts) :
1
1
L1  x1  x2  x3   x4  x5  x6 
3
3
(A comparison of the High protein diets with Low
protein diets)
1
1
L2  x1  x 4   x3  x6 
2
2
(A comparison of the Beef source of protein with the
Pork source of protein)
1
1
L3  x1  x3  x 4  x6   x 2  x5 
4
2
(A comparison of the Meat (Beef - Pork) source of
protein with the Cereal source of protein)
1
1
L4  x1  x6   x3  x 4 
2
2
(A comparison representing interaction between
Level of protein and Source of protein for the Meat
source of Protein)
1
1
L5  x1  x3  2 x5   x 4  x6  2 x 2 
4
4
(A comparison representing interaction between
Level of protein with the Cereal source of Protein)
The Anova Table for Testing these contrasts is given
below:
Source:
DF:
Sum Squares:
Mean Square:
F-test:
Contrast L1
Contrast L2
Contrast L3
Contrast L4
Contrast L5
Error
1
1
1
1
1
54
3168.267
2.500
264.033
0.000
1178.133
11586.000
3168.267
2.500
264.033
0.000
1178.133
214.556
14.767
0.012
1.231
0.000
5.491
The Mutually Orthogonal contrasts that are
eventually selected should be determine prior to
observing the data and should be determined by the
objectives of the experiment
Another Five mutually orthogonal contrasts are
given below (together with a description of the
purpose of these contrasts) :
1
1
L1  x1  x2  x3   x4  x5  x6 
3
3
(A comparison of the High protein diets with Low
protein diets)
1
1
L2  x1  x 4   x3  x6 
2
2
(A comparison of the Beef source of protein with the
Pork source of protein)
L3  x1  x4
(A comparison of the high and low protein diets for
the Beef source of protein)
L4  x2  x5
(A comparison of the high and low protein diets for
the Cereal source of protein)
L5  x3  x6
(A comparison of the high and low protein diets for
the Pork source of protein)
The Anova Table for Testing these contrasts is given
below:
Source:
DF:
Sum Squares:
Mean Square:
F-test:
Beef vs Pork ( L1)
Meat vs Cereal ( L2)
High vs Low for Beef ( L3)
High vs Low for Cereal ( L4)
High vs Low for Pork ( L5)
Error
1
1
1
1
1
54
2.500
264.033
2163.200
20.000
2163.200
11586.000
2.500
264.033
2163.200
20.000
2163.200
214.556
0.012
1.231
10.082
0.093
10.082
Orthogonal Linear Contrasts
Polynomial Regression
Orthogonal Linear Contrasts for Polynomial Regression
Orthogonal Linear Contrasts for Polynomial Regression
Example
In this example we are measuring the “Life”
of an electronic component and how it
depends on the temperature on activation
Table
Activation
Temperature
0
53
50
47
Ti.
150
Mean
50
yij2 = 56545
25
50
75
100
60
67
65
58
62
70
68
62
58
73
62
60
T..
180
210
195
180
915
60
70
65
60
Ti.2/n = 56475
T..2/nt = 55815
The Anova Table
L = 25.00 Q2 = -45.00 C = 0.00 Q4 = 30.00
Source
Treat
Linear
Quadratic
Cubic
Quartic
Error
Total
SS
df
660
4
187.50
1
433.93
1
0.00
1
38.57
1
70
10
730
14
MS
165.0
187.50
433.93
0.00
38.57
7.00
F
23.57
26.79
61.99
0.00
5.51
The Anova Tables
for Determining degree of polynomial
Testing for effect of the factor
Source
Treat
Error
Total
SS
660
70
730
df
4
10
14
MS
165
7
F
23.57
Testing for departure from Linear
Testing for departure from Quadratic
y = 49.751 + 0.61429 x -0.0051429 x^2
70
65
Life
60
55
50
45
40
0
20
40
60
Act. Temp
80
100
120
Post-hoc Tests
Multiple Comparison Tests
Suppose we have p means
x1 , x2 ,  , x p
An F-test has revealed that there are significant
differences amongst the p means
We want to perform an analysis to determine
precisely where the differences exist.
Tukey’s Multiple Comparison
Test
Let
MSError
s

n
n
denote the standard error of each xi
Tukey's Critical Differences
Da  qa
s
n
 qa
MS Error
n
Two means are declared significant if they
differ by more than this amount.
qa = the tabled value for Tukey’s studentized
range p = no. of means, n = df for Error
Scheffe’s Multiple Comparison
Test
Scheffe's Critical Differences (for Linear
contrasts)
s
2
2
2
Sa   p  1Fa  p  1,n 
a1  a 2    a p
n

 p  1Fa  p  1,n 
MS Error
n
a12  a22    a 2p
A linear contrast is declared significant if it
exceeds this amount.
Fa  p 1,n  = the tabled value for F distribution
(p -1 = df for comparing p means,
n = df for Error)
Scheffe's Critical Differences
(for comparing two means)
L  xi  x j
Sa 
 p 1Fa  p 1,n 
MSError
n
2
Two means are declared significant if they
differ by more than this amount.
Table 5: Critical Values for
the multiple range Test , and the F-distribution
Length
Temp,Thickness,Dry
q.05
q.01
F.05
F.01
3.84
4.60
4.80
5.54
2.92
2.33
4.51
3.30
Table 6: Tukey's and Scheffe's Critical Differences
Tukeys
Scheffés
a = .05
a = .01
a = .05
a = .01
Length
1.59
1.99
2.05
2.16
Temp, Thickness, Dry 3.81
4.59
4.74
5.64