Professional Documents
Culture Documents
M
F
it (Mixed)
(Mi d) Models:
M d l
An Overview
Rod Sturdivant
Center for Data Analysis and Statistics (CDAS)
Feb 2007
AGENDA
The Problem
The Traditional Approach
The Mixed Model
An Example
l
References
The Problem
returni = 0 + 1 usei + i
Where:
i is the subject index (I = 1,,40)
ij is an error term (assumed independent with
y
mean 0 and constant variance usually
assume a normal distribution)
A Good Model?
BUT WHAT IF
BUT,
IF
A NEW PICTURE
The data came from 4 treatment centers:
Traditional Solution
Center
1
2
3
4
D1
0
1
0
0
D2
0
0
1
0
D3
0
0
0
1
8
return
t i = 80.8
80 8 2 usei 22.9
9 D1i 88.8
8 D 2i 15
15.8
8 D3i
Design Variables
Estimated Line
0, 0, 0
1, 0, 0
0, 1, 0
returni = 72.0
2 0 2 usei
0, 0, 1
10
Model Results
11
12
13
Model Results
14
16
Introduction
IIncreasing
i use
Estimation algorithms and software
available
17
Emphasis on fixed/random
yij = 0 j + 1 xij + ij
0 j = 0 + 0 j
where
h
We assume:
ij
y ij = ( 00 + 1 xij ) + ( 0 j + ij )
j = 1,..., J
i = 1,..., n j
N ((0, 2 )
Independent
p
of
0 j
N ((0, 02 )
18
yij = 0 j + 1 j xij + ij
where
Emphasis on fixed/random
y ij = ( 0 + 1 xij ) + ( 0 j + 1 j xij + ij )
0 j = 0 + 0 j
1 j = 1 + 1 j
Additional assumptions:
1 j
N (0,
(0 12 )
cov( 0 j , 1 j ) = 01
Center for Data Analysis and Statistics (CDAS)
19
M
yn 1
1
y12
M
y =
yn2 2
M
y
1J
M
yn J
J
1 x11
M M
1 xn 1
1
1 x12
M M
X=
1 x n2 2
M M
1 x
1J
M M
1 x
nJ J
= 0
1
M
1
Z=
x11
M
xn11
1
M
x12
M
x n2 2
O
1
M
1
x1 J
M
xnJ J
01
11
M
=
0 J
1J
11
M
n 1
1
12
M
=
n2 2
M
1J
M
nJ J
20
= var()
and
W = Var ( )
2
01 0
=
O
0
01
01 02
W = diag( 2 )
21
Model Estimation
Iterative algorithms
Bayesian MCMC methods
22
Parameter Estimates
Parameter
Fixed
Intercept
66.9
10.2
Slope
-1.0
0.96
40
4.0
0 97
0.97
412.8
293.6
3.6
2.6
-38.1
27.3
Level 1
Random
Intercept
Slope
Covariance
23
Predictions
rh = R h V 1 (y X)
where
R h = Z h h
cov(rh ) = R h V 1R h
n j 02
( y. j y.. )
0 j =
2
2
n j 0 +
Center for Data Analysis and Statistics (CDAS)
24
Model Results
Center (j)
Intercept
Slope
66.9+12.9
= 79.8
-1 - 0.86
= -1.86
80.7
-2
66.9+11.7
= 78.6
78 6
-1 - 1.03
= -2.03
2 03
77.8
-2
2
66.9+ 5.7
= 72.6
-1 - 0.98
= -1.98
71.8
-2
66.9 30.2
66.9-30.2
= 36.7
-1
1 + 2.87
= 1.87
36.6
1.8
Estimate
intercept and
slope from:
Center for Data Analysis and Statistics (CDAS)
Std.
Model
0 j = 00 + 0 j
1 j = 10 + 1 j
25
Model Extensions
There are numerous possible extensions at this
point. In addition to additional predictors (with
either fixed or random coefficients) at level 1
returnij = 0 j + 1 j useij + ij
Additional
l
level
l
0 j = 00 k + 01 z0j + 0 j
00 k = 000 + 00 k
1 j = 10 + 11z1j + 1 j
Center specific
predictor variable
26
Example
Batting Average in
DAY/NIGHT games
t Value
54.77
-4
4.38
38
Pr > |t|
<.0001
<.0001
< 0001
Error
0.00174983
0.00247463
t Value
162.87
-1.82
Pr > |t|
<.0001
0.0696
28
Random effects
Covariance Parameter Estimates
Cov Parm
Subject
Estimate
Intercept
PLAYER
0.000531
0 000531
Residual
0.000105
Player
Day
Night
Model Day
Model Night
0.24943
0.24545
0.25004
0.24554
0 26905
0.26905
0 26712
0.26712
0 27048
0.27048
0 26598
0.26598
0.29949
0.29169
0.29772
0.29321
0.26852
0.26626
0.26979
0.26529
29
30
Study Findings
31
References
BOOKS
33
PAPERS
34
Marginal Models
35
Di = 2 log(
l ( Li )
D1 D2 ~ 2 ( p2 p1 )
p1 < p2
H0 : h = 0
T (h ) =
SE( h )
36
37