Document 10639610

advertisement
Repeated Measures
c
Copyright 2016
(Iowa State University)
Statistics 510
1 / 23
Repeated Measures Example
In an exercise therapy study, subjects were assigned
to one of three weightlifting programs
i=1: The number of repetitions of weightlifting was
increased as subjects became stronger (RI).
i=2: The amount of weight was increased as subjects
became stronger (WI).
i=3: Subjects did not participate in weightlifting
(XCont).
c
Copyright 2016
(Iowa State University)
Statistics 510
2 / 23
Measurements of strength (y) were taken on days
2, 4, 6, 8, 10, 12, and 14 for each subject.
Source: Littel, Freund, and Spector (1991), SAS
System for Linear Models.
R code: RepeatedMeasures.R
SAS code: RepeatedMeasures.sas
c
Copyright 2016
(Iowa State University)
Statistics 510
3 / 23
A Linear Mixed-Effects Model
yijk = µ + αi + sij + τk + γik + eijk
yijk strength measurement for program i, subject j,
time point k
αi fixed program effect
sij random subject effect
τk fixed time effect
γik fixed program×time interaction parameter
eijk random error
c
Copyright 2016
(Iowa State University)
Statistics 510
4 / 23
To simplify notation, we will sometimes use µik to
represent
µ + αi + τk + γik ,
the mean response for program i at the kth time point.
c
Copyright 2016
(Iowa State University)
Statistics 510
5 / 23
Initially, we will assume
i.i.d.
i.i.d.
sij ∼ N(0, σs2 ) independent of eijk ∼ N(0, σe2 ).
c
Copyright 2016
(Iowa State University)
Statistics 510
6 / 23
Note that our model is the same model we would use
for a split-plot experiment in which the whole-plot part
of the experiment has a completely randomized
design.
Subjects are the whole-plot experimental units, and
measurement occasions within subject are treated
like split-plot experimental units.
c
Copyright 2016
(Iowa State University)
Statistics 510
7 / 23
The measurement occasions are not really
experimental units because levels of the factor time
(2, 4, . . ., 14) were not randomly assigned to
measurement occasions.
Nonetheless, this split-plot model might be
reasonable for some experiments where experimental
units are measured repeatedly over time.
c
Copyright 2016
(Iowa State University)
Statistics 510
8 / 23
Average strength after 2k days on the ith program is
µik = E(yijk )
= E(µ + αi + sij + τk + γik + eijk )
= µ + αi + E(sij ) + τk + γik + E(eijk )
= µ + αi + τk + γik
for i = 1, 2, 3 and k = 1, 2, . . . , 7.
c
Copyright 2016
(Iowa State University)
Statistics 510
9 / 23
The variance of any single observation is
Var(yijk ) = Var(µ + αi + sij + τk + γik + eijk )
= Var(sij + eijk )
= Var(sij ) + Var(eijk )
= σs2 + σe2 .
c
Copyright 2016
(Iowa State University)
Statistics 510
10 / 23
The covariance between any two different
observations from the same subject is
Cov(yijk , yij` ) = Cov(µ + αi + sij + τk + γik + eijk ,
µ + αi + sij + τ` + γi` + eij` )
= Cov(sij + eijk , sij + eij` )
= Cov(sij , sij ) + Cov(sij , eij` )
+Cov(eijk , sij ) + Cov(eijk , eij` )
= Var(sij ) = σs2 .
c
Copyright 2016
(Iowa State University)
Statistics 510
11 / 23
The correlation between yijk and yij` is
σs2
≡ ρ.
σs2 + σe2
Observations taken on different subjects are
uncorrelated.
c
Copyright 2016
(Iowa State University)
Statistics 510
12 / 23
For the set of observations taken on a single subject,
we have




yij1
σe2 + σs2
σs2
···
σs2
 y 
 σ2
σe2 + σs2 · · ·
σs2 
 ij3 


s
Var  ..  = 

..
..
.
2
..
 . 


.
.
σs
2
2
2
2
2
yij7
σs
σs
σs σe + σ s
= σe2 I7×7 + σs2 1107×7 .
This is known as a compound symmetric covariance
structure.
c
Copyright 2016
(Iowa State University)
Statistics 510
13 / 23
Using ni to denote the number of subjects in the ith
program, we can write this model in the form
y = Xβ + Zu + e.
To make things slightly easier to write, let
yij = [yij1 , yij2 , yij3 , yij4 , yij5 , yij6 , yij7 ]0
and
eij = [eij1 , eij2 , eij3 , eij4 , eij5 , eij6 , eij7 ]0
for all i = 1, 2, 3 and all j = 1, . . . , ni .
c
Copyright 2016
(Iowa State University)
Statistics 510
14 / 23
























y11
y12
..
.
y1n1
y21
y22
..
.
y2n2
y31
y32
..
.
y3n3


 
 
 
 
 
 
 
 
 
 
 
=
 
 
 
 
 
 
 
 
 
 
17×1
17×1
..
.
17×1
17×1
..
.
07×1
07×1
..
.
07×1
07×1
..
.
I7×7
I7×7
..
.
I7×7
I7×7
..
.
07×7
07×7
..
.
07×7
07×7
..
.
17×1
17×1
17×1
..
.
17×1
07×1
07×1
..
.
07×1
17×1
17×1
..
.
07×1
07×1
07×1
..
.
I7×7
I7×7
I7×7
..
.
I7×7
07×7
07×7
..
.
07×7
I7×7
I7×7
..
.
07×7
07×7
07×7
..
.
17×1
17×1
17×1
..
.
07×1
07×1
07×1
..
.
17×1
07×1
07×1
..
.
07×1
17×1
17×1
..
.
I7×7
I7×7
I7×7
..
.
07×7
07×7
07×7
..
.
I7×7
07×7
07×7
..
.
07×7
I7×7
I7×7
..
.
17×1
07×1
07×1
17×1
I7×7
07×7
07×7
I7×7
c
Copyright 2016
(Iowa State University)



























µ
α1
α2
α3
τ1
τ2
τ3
τ4
τ5
τ6
τ7
γ11
γ12
..
.














+












γ37
Statistics 510
15 / 23












I(n1 +n2 +n3 )×(n1 +n2 +n3 ) ⊗ 17×1 










s11
s12
..
.
s1n1
s21
s22
..
.
s2n2
s31
s32
..
.
s3n3
c
Copyright 2016
(Iowa State University)


 
 
 
 
 
 
 
 
 
 
 
+
 
 
 
 
 
 
 
 
 
 
e11
e12
..
.
e1n1
e21
e22
..
.
e2n2
e31
e32
..
.























e3n3
Statistics 510
16 / 23
In this case,
G = Var(u) = σs2 In· ×n· and
R = Var(e) = σe2 I(7n· )×(7n· ) ,
where n· = n1 + n2 + n3 is the total number of subjects.
Σ = Var(y) = ZGZ0 + R
is a block diagonal matrix with one block of the form
σs2 1107×7 + σe2 I7×7
for each subject.
c
Copyright 2016
(Iowa State University)
Statistics 510
17 / 23
G = Var(u) = σs2 I, R = Var(e) = σe2 I, and
Σ = Var(y) = ZGZ0 + R


110


110

2
= σs 
 + σe2 I
.
.
.


0
11


2
2 0
σe I + σs 11


...
= 
.
2
2 0
σe I + σs 11
c
Copyright 2016
(Iowa State University)
Statistics 510
18 / 23
If predicting subject effects is not of interest and
random subject effects are included only to introduce
correlation among repeated measures on the same
subject, we can work with an alternative expression of
the same model by using the general linear model
y = Xβ + , where


σe2 I + σs2 110


...
Var(y) = Var() = 
.
2
2 0
σe I + σs 11
c
Copyright 2016
(Iowa State University)
Statistics 510
19 / 23
More generally, we can replace the mixed model
y = Xβ + Zu + e
with the model
y = Xβ + where



Var(y) = Var() = 

c
Copyright 2016
(Iowa State University)
W 0 ··· 0
0 W ··· 0
.. .. . . . ..
. .
.
0 0 ··· W



.

Statistics 510
20 / 23
We can choose a structure for W that seems
appropriate based on the design and the data.
One choice for W is a compound symmetric matrix
like we have considered previously.
Another choice for W is an unstructured positive
definite matrix.
A common choice for W when repeated measures
are equally spaced in time is the first order
autoregressive structure known as AR(1).
c
Copyright 2016
(Iowa State University)
Statistics 510
21 / 23
AR(1): First Order Autoregressive Covariance
Structure





2
W=σ 




1
ρ
ρ2
ρ3
ρ4
ρ5
ρ6
ρ
1
ρ
ρ2
ρ3
ρ4
ρ5
ρ2
ρ
1
ρ
ρ2
ρ3
ρ4
ρ3
ρ2
ρ
1
ρ
ρ2
ρ3
ρ4
ρ3
ρ2
ρ
1
ρ
ρ2
ρ5
ρ4
ρ3
ρ2
ρ
1
ρ
ρ6
ρ5
ρ4
ρ3
ρ2
ρ
1











where σ 2 ∈ (0, ∞) and ρ ∈ (−1, 1) are unknown
parameters.
c
Copyright 2016
(Iowa State University)
Statistics 510
22 / 23
In the next set of slides, we will see how to fit a variety
of general linear models that might be appropriate for
repeated measures experiments.
c
Copyright 2016
(Iowa State University)
Statistics 510
23 / 23
Download