TITLE:
Ch 6: 4a: Fixed Slope12, Fixed Slope26, Random Intercept Model
DATA:
FILE = MPLUS_Chapter6.csv;
FORMAT = FREE;
DEFINE:
rt = rt/10;
slope12=0; slope26=0;
IF session GE 2 THEN slope12=1;
IF session GE 2 THEN slope26=session-2;
VARIABLE:
NAMES = PersonID session rt;
USEVARIABLES = rt slope12 slope26;
MISSING = ALL (-9999);
CLUSTER = PersonID;
WITHIN = slope12 slope26;
ANALYSIS:
ESTIMATOR = ML;
PROCESSORS = 4;
TYPE = TWOLEVEL RANDOM;
MODEL:
%WITHIN%
rt;
slope1 | rt ON slope12;
slope2 | rt ON slope26;
%BETWEEN%
[rt slope1 slope2] (int bslope12 bslope26);
rt slope1@0 slope2@0;
MODEL CONSTRAINT:
NEW(est1-est7);
est1 = int*1 + bslope12*0 + bslope26*0;
est2 = int*1 + bslope12*1 + bslope26*0;
est3 = int*1 + bslope12*1 + bslope26*1;
est4 = int*1 + bslope12*1 + bslope26*2;
est5 = int*1 + bslope12*1 + bslope26*3;
est6 = int*1 + bslope12*1 + bslope26*4;
est7 = -1*bslope12 + 1*bslope26;