Mixed Models

advertisement
5.2.5 Repeated Measures in SPSS
We will demonstrate the equivalent procedure (in SPSS) to PROC MIXED in SAS by
analyzing the dental measurements of Pothaff and Roy (1964). The same analysis, using
SAS, is presented in 5.2.3.
The procedure can be obtained by going to Analyze > Mixed Models > Linear.
Step 1. In the first screen that appears, specify the subject factor. The subject factor
identifies the experimental units on which the measurements are taken. In the dental
example, this factor is called person.
1 of 6
Step 2. Specify the factor that is repeated. The repeated factor is the variable that is used
to designate the repeated measurements for each subject. This is the age variable in the
dental example, since measurements are taken at 8, 10, 12, and 14 years of age.
Step 3. Once the repeated factor is specified, the box titled “Repeated Covariance Type” is
available. There are several structures available to model the covariance between repeated
measurements for a subject. As in the analysis of the dental measurements using SAS’s
PROC MIXED, we will choose Compound Symmetry. Click continue.
2 of 6
Step 4. The next window is the same window that is used to select the factors for a mixed
effects model (demonstrated in 2.2.2). Here, we define the dependent variable and factors.
Because both of the factors (gender and age) are fixed, click on the “Fixed” button at the
bottom of the window.
Step 5. Define the fixed factor(s). In our example, both factors are fixed. For a full
factorial design, click on the first variable (gender), hold down the shift button on the
keyboard, and then click on the next variable (age). Both variables should be highlighted.
Then select Factorial from the drop down menu between the two main boxes and click Add.
Click Continue and then OK.
3 of 6
Note: One can request that pairwise comparisons of the means for the fixed factor(s) be
displayed by following the steps on page 6 of this manual.
a
Type I II Te sts of Fixed Effects
Source
Int ercept
gender
age
gender * age
Numerator df
1
1
3
3
Denominat or
df
25.000
25.000
75.000
75.000
F
3910.836
9.292
35.347
2.362
Sig.
.000
.005
.000
.078
a. Dependent Variable: y.
Figure 1. Tests of Fixed Factors
Figure 1 shows that, using   0.05 , there are differences in gender (p=0.005) and age
(p=0.000), but that there is no significant interaction between gender and age (p=0.078).
Estimates of Covariance Parameters a
Parameter
Repeated Meas ures
CS diagonal offs et
CS covariance
Es timate
1.9750379
3.2853883
Std. Error
.3225223
1.0719412
a. Dependent Variable: y.
Figure 2. Estimated covariance parameters
Figure 2 presents the estimated covariance parameters. Compound symmetry was used to
model the covariance between measurements at different ages. From the table, the
variance of the measurements for a subject at a particular age is ˆ 2  1.975  3.285  5.26
and the covariance between measurements taken at two different ages is ˆ 2a  3.285 .
Because we specified compound symmetry as the covariance structure for the repeated
measurements, the covariance estimate of 3.285 is the same regardless of the two ages.
From these estimates, we can estimate the correlation between measurements taken at
different ages. From 5.1.3, the estimate (sometimes known as the intra-class correlation
ˆ 2
ˆ 2 3.285
 0.625 .
coefficient) is ˆ  2 a 2  a2 
ˆ a  ˆ e ˆ
5.26
4 of 6
First Order Autoregressive. To model the covariance between measurements at any two
ages, one may decide that a first order autoregressive structure is more appropriate than
compound symmetry. As mentioned in 5.1, the first order autoregressive structure,
abbreviated as AR(1), has the following form for each subject:
 1  2 3 


1  2
2  
, where  is the correlation between measurements taken at

 2 
1 
 3

2
 1
 
successive age levels.
As before, to begin the analysis, go to Analyze > Mixed Models > Linear.
Steps 1 and 2 are the same as before.
Step 3. In the box titled “Repeated Covariance Type”, choose AR(1). Click continue.
Steps 4 and 5 are the same as before. The following output is obtained.
5 of 6
a
Inform ation Crite ria
-2 Res trict ed Log
Lik elihood
Ak aike's Information
Criterion (A IC)
Hurvich and Ts ai's
Criterion (A ICC)
Bozdogan's Criterion
(CAIC)
Sc hwarz's Bay esian
Criterion (B IC)
434.547
438.547
438.671
445.758
443.758
The information criteria are
dis play ed in smaller-is-bett er forms .
a. Dependent Variable: y.
Figure 3. Model fit information
Figure 3 gives several measures of the model fit.
a
Type I II Te sts of Fixed Effects
Source
Int ercept
gender
age
gender * age
Numerator df
1
1
3
3
Denominat or
df
28.092
28.092
58.983
58.983
F
4660.340
11.073
15.475
1.125
Sig.
.000
.002
.000
.346
a. Dependent Variable: y.
Figure 4. Tests of Fixed Factors
As before, the tests of the fixed effects shows that there are differences in gender (p=0.002)
and age (p=0.000). Pairwise comparisons of the levels of these factors should be
performed.
Estimates of Covariance Parameters a
Parameter
Repeated Meas ures
AR1 diagonal
AR1 rho
Es timate
5.2464580
.6152662
Std. Error
.9660890
.0794112
a. Dependent Variable: y.
Figure 5. Estimated Covariance Parameters
The estimated variance of the measurements for a subject at a particular age is ˆ 2  5.246 .
This is given in the row titled “AR1 diagonal”, because it is the entry located on the
diagonal of the covariance matrix for a subject (as previously shown). The estimated
correlation between successive measurements is ˆ  0.615 . This is given by the entry in
the row titled “AR1 rho”. Due to the structure of an AR(1) model, we can estimate the
correlation between measurements taken further apart in time, as well. For instance, the
estimated correlation between measurements taken on a subject at ages 8 and 12 is
ˆ 2  (0.615)2  0.378 , and for measurements taken at ages 8 and 14 is
ˆ 3  (0.615)3  0.233 .
6 of 6
Download