L91
Lecture 9 - Subject factors in Longitudinal Models
Model 2, p. 178
Level 1 Model (from Lecture 8 and Text, p. 162)
Yti = p0i + p1i*timeti + p2i*time2ti + etiThis is the model for a single person, person i at time t.
Level 2 model for Level 1 intercept
p0i = B00 + B01*sesi + B02*effectivei + g0i(1st B subscript is 0 cause a model of p0.)
This is the model for the initial level of a person, based on person characteristics sesi and effectivei
The level at which a student begins depends on the student’s ses and on the effectiveness of the student’s teacher. Hmm – I can understand ses, but I’m not sure I understand how teacher effectiveness could affect beginning performance, i.e., the intercept.
It could be that effective refers to perceived effectiveness, in which case, its relationship to the intercept may be because students who expect more give more from the beginning.
Level 2 model for Level 1 slope with respect to time
p1i = B10 + B11*sesi + B12*effectivei + g1iThe text’s Eq. 5.14 should not include time.
The rate at which a student increases depends on the student’s ses and on the effectiveness of the student’s teacher (or perceived effectiveness). For what it’s worth, I understand both of these.
Possible Level 2 model for Level 1 slope with respect to time2
p2i = B20 + B21*sesi + B22*effectivei + g2iThe text’s Eq. 5.15 should not include quadtime.
The text mentioned the possibility that the slope w.r. to time2could depend on ses and effective but the authors decided not to include Eq. 5.15 in the model.
So,the actual Level 2 model for p2i the slope for time2 is simply
p2i = B20
The full model for a given individual, i, is
Yti = B00 + B01*sesi + B02*effectivei + g0i + (B10 + B11*sesi + B12*effectivei + g1i)*timeti + B20*time2ti + eti
Yti = B0 +B01*sesi +B02*effectivei + g0i +B10*timeti +B11*sesi*timeti +B12*effectivei*timeti +g1i*timeti +B20*time2ti +eti
The text chose to assume a diagonal variance/covariance matrix of repeated measures across time. (p. 179)
Note that the level 2 slope factors (ses and effective) interact with time. time2 is called quadtime.
Yti = B0 +B01*sesi +B02*effectivei + g0i +B10*timeti +B11*sesi*timeti +B12*effectivei*timeti +g1i*timeti
+B20*quadtimeti +eti (Rep=Diag; Cov=UN).
The SPSS dialogues (See text, p. 179)
Yti = B0 +B01*sesi +B02*effectivei + g0i +B10*timeti +B11*sesi*timeti +B12*effectivei*timeti +g1i*timeti
+B20*quadtimeti +eti (Rep=Diag; Ran=UN).)
Yti = B0 +B01*sesi +B02*effectivei + g0i +B10*timeti +B11*sesi*timeti +B12*effectivei*timeti +g1i*timeti
+B20*time2ti +eti (Rep=Diag; Ran=UN).)
GET FILE='G:\MdbO\html\myweb\PSY5950C\ch5vertest.sav'.
DATASET NAME DataSet1 WINDOW=FRONT.
MIXED test WITH time quadtime effective ses
/CRITERIA=CIN(95) MXITER(100) MXSTEP(10) SCORING(1) SINGULAR(0.000000000001)
HCONVERGE(0, ABSOLUTE) LCONVERGE(0, ABSOLUTE) PCONVERGE(0.000001, ABSOLUTE)
/FIXED=ses effective time time*ses time*effective quadtime | SSTYPE(3)
/METHOD=REML
/PRINT=G SOLUTION TESTCOV
/RANDOM=INTERCEPT time | SUBJECT(id) COVTYPE(UN)
/REPEATED=time | SUBJECT(id) COVTYPE(DIAG).
Mixed Model Analysis
[DataSet1] G:\MdbO\html\myweb\PSY5950C\ch5vertest.sav
Model DimensionbNumber of Levels / Covariance Structure / Number of Parameters / Subject Variables / Number of Subjects
Fixed Effects / Intercept / 1 / 1
ses / 1 / 1
effective / 1 / 1
time / 1 / 1
time * ses / 1 / 1
time * effective / 1 / 1
quadtime / 1 / 1
Random Effects / Intercept + timea / 2 / Unstructured / 3 / id
Repeated Effects / time / 3 / Diagonal / 3 / id / 8670
Total / 12 / 13
a. As of version 11.5, the syntax rules for the RANDOM subcommand have changed. Your command syntax may yield results that differ from those produced by prior versions. If you are using version 11 syntax, please consult the current syntax reference guide for more information.
b. Dependent Variable: test.
Information Criteriaa
-2 Restricted Log Likelihood / 186820.703
Akaike's Information Criterion (AIC) / 186832.703
Hurvich and Tsai's Criterion (AICC) / 186832.706
Bozdogan's Criterion (CAIC) / 186887.698
Schwarz's Bayesian Criterion (BIC) / 186881.698
The information criteria are displayed in smaller-is-better forms.
a. Dependent Variable: test.
Yti = B0 +B01*sesi +B02*effectivei + g0i +B10*timeti +B11*sesi*timeti +B12*effectivei*timeti +g1i*timeti
+B20*time2ti +eti (Rep=Diag; Ran=UN).
Fixed Effects
Type III Tests of Fixed EffectsaSource / Numerator df / Denominator df / F / Sig.
Intercept / 1 / 9227.021 / 101499.534 / .000
ses / 1 / 8667.000 / 3.420 / .064
effective / 1 / 8667.000 / 157.671 / .000
time / 1 / 10048.373 / 156.301 / .000
time * ses / 1 / 8667.000 / 4.370 / .037
time * effective / 1 / 8667.000 / 919.544 / .000
quadtime / 1 / 8669.000 / 6.176 / .013
a. Dependent Variable: test.
Estimates of Fixed Effectsa
Parameter / Estimate / Std. Error / df / t / Sig. / 95% Confidence Interval
Lower Bound / Upper Bound
Intercept / 47.283765 / .148416 / 9227.021 / 318.590 / .000 / 46.992838 / 47.574693
ses / .228228 / .123403 / 8667.000 / 1.849 / .064 / -.013670 / .470127
effective / 2.436212 / .194017 / 8667.000 / 12.557 / .000 / 2.055893 / 2.816532
time / 2.795098 / .223571 / 10048.373 / 12.502 / .000 / 2.356853 / 3.233342
time * ses / -.153810 / .073581 / 8667.000 / -2.090 / .037 / -.298047 / -.009574
time * effective / 3.508072 / .115686 / 8667.000 / 30.324 / .000 / 3.281299 / 3.734844
quadtime / -.243999 / .098184 / 8669.000 / -2.485 / .013 / -.436463 / -.051535
a. Dependent Variable: test.
B01: Initial test scores are not officially related to ses.
B02: Initial test scores are related to teacher effectiveness. Well what do you know?
B10: On the average test scores increase over time.
B11: The rate of linear increase over time decreases with increasing ses.vs
The rate of linear increase was shallower for kids with high ses than it was for kids with low ses.
Test= 47.28 + .23*ses + 2.80*time - .15*ses*time
= 47.28 + .23*ses + (2.80 -.15*ses)*time
B12: The rate of increase over time increases with teacher effectiveness.vs
The rate of linear increase was steeper for kids with effective teachers than for kids with ineffective.
Test = 47.28 + 2.44*effective + 2.80*time + 3.51*effective*time
= 47.28 +2.44*effective + (2.80 + 3.51*effective)*time
B20: There is a slight downward bend in the overall curve relating test scores to time.
Yti = B0 +B01*sesi +B02*effectivei + g0i +B10*timeti +B11*sesi*timeti +B12*effectivei*timeti +g1i*timeti
+B20*time2ti +eti (Rep=Diag; Ran=UN).
Covariance Parameters
Estimates of Covariance ParametersaParameter / Estimate / Std. Error / Wald Z / Sig. / 95% Confidence Interval
Lower Bound / Upper Bound
Repeated Measures / Var: [time=0] / 61.399873 / 2.003852 / 30.641 / .000 / 57.595371 / 65.455684
Var: [time=1] / 61.448416 / 1.155968 / 53.158 / .000 / 59.224020 / 63.756358
Var: [time=2] / 27.124323 / 1.726829 / 15.708 / .000 / 23.942443 / 30.729067
Intercept + time [subject = id] / UN (1,1) / 30.649177 / 1.828750 / 16.760 / .000 / 27.266539 / 34.451459
UN (2,1) / -3.305822 / 1.012774 / -3.264 / .001 / -5.290823 / -1.320821
UN (2,2) / 7.465096 / .873415 / 8.547 / .000 / 5.935331 / 9.389141
a. Dependent Variable: test.
Note that there is not one Var(eij) but three Vars – one for each time period. This is what was specified on the first dialogue box by putting time in the repeated field and then choosing diagonal. Note also that the variance of the residuals about the Level 1 line was smaller at Time=2 than at Time=0 or Time=1. Test scores were more predictable in the last time period.
There is still significant random variation in the intercepts across persons.
There is still significant random variation in the slopes – rates of increase – across persons.
There is a significant, negative correlation between intercepts and slopes. This is a common result.
Random Effect Covariance Structure (G)a
Intercept | id / time | idIntercept | id / 30.649177 / -3.305822
time | id / -3.305822 / 7.465096
Unstructured
a. Dependent Variable: test.
Comparison of Traditional Repeated Measures analyses and the Multilevel Analyses
The p-values associated with differences in results are marked in red.
Traditional RM using the Ch5hortest.sav data file.
All interactions will be tested by default.
The default contrast for time is a polynomial contrast – they’re not reported below.
The usual Options are requested, including Parameter Estimates
Here’s all the traditional analysis resultsDifferences in results from MIXED are in red.
Multivariate TestsaEffect / Value / F / Hypothesis df / Error df / Sig. / Partial Eta Squared / Noncent. Parameter / Observed Powerc
time / Pillai's Trace / .082 / 389.605b / 2.000 / 8666.000 / .000 / .082 / 779.210 / 1.000
Wilks' Lambda / .918 / 389.605b / 2.000 / 8666.000 / .000 / .082 / 779.210 / 1.000
Hotelling's Trace / .090 / 389.605b / 2.000 / 8666.000 / .000 / .082 / 779.210 / 1.000
Roy's Largest Root / .090 / 389.605b / 2.000 / 8666.000 / .000 / .082 / 779.210 / 1.000
time * ses / Pillai's Trace / .001 / 2.196b / 2.000 / 8666.000 / .111 / .001 / 4.392 / .451
Wilks' Lambda / .999 / 2.196b / 2.000 / 8666.000 / .111 / .001 / 4.392 / .451
Hotelling's Trace / .001 / 2.196b / 2.000 / 8666.000 / .111 / .001 / 4.392 / .451
Roy's Largest Root / .001 / 2.196b / 2.000 / 8666.000 / .111 / .001 / 4.392 / .451
time * effective / Pillai's Trace / .104 / 502.407b / 2.000 / 8666.000 / .000 / .104 / 1004.814 / 1.000
Wilks' Lambda / .896 / 502.407b / 2.000 / 8666.000 / .000 / .104 / 1004.814 / 1.000
Hotelling's Trace / .116 / 502.407b / 2.000 / 8666.000 / .000 / .104 / 1004.814 / 1.000
Roy's Largest Root / .116 / 502.407b / 2.000 / 8666.000 / .000 / .104 / 1004.814 / 1.000
a. Design: Intercept + ses + effective
Within Subjects Design: time
b. Exact statistic
c. Computed using alpha = .05
Tests of Between-Subjects Effects
Measure: MEASURE_1
Transformed Variable: Average
Source / Type III Sum of Squares / df / Mean Square / F / Sig. / Partial Eta Squared / Noncent. Parameter / Observed Powera
Intercept / 28925340.913 / 1 / 28925340.913 / 200192.641 / .000 / .959 / 200192.641 / 1.000
ses / 91.225 / 1 / 91.225 / .631 / .427 / .000 / .631 / .125
effective / 218038.615 / 1 / 218038.615 / 1509.048 / .000 / .148 / 1509.048 / 1.000
Error / 1252273.450 / 8667 / 144.488
a. Computed using alpha = .05
Note that the traditional repeated measures analysis did not include quadtime in the default analyses while the multilevel analysis DID include quadtime. This means that the traditional analysis and the multilevel analyses are not strictly comparable.
Multilevel
Estimates of Fixed EffectsaParameter / Estimate / Std. Error / df / t / Sig. / 95% Confidence Interval
Lower Bound / Upper Bound
Intercept / 47.283765 / .148416 / 9227.021 / 318.590 / .000 / 46.992838 / 47.574693
ses / .228228 / .123403 / 8667.000 / 1.849 / .064 / -.013670 / .470127
effective / 2.436212 / .194017 / 8667.000 / 12.557 / .000 / 2.055893 / 2.816532
time / 2.795098 / .223571 / 10048.373 / 12.502 / .000 / 2.356853 / 3.233342
time * ses / -.153810 / .073581 / 8667.000 / -2.090 / .037 / -.298047 / -.009574
time * effective / 3.508072 / .115686 / 8667.000 / 30.324 / .000 / 3.281299 / 3.734844
quadtime / -.243999 / .098184 / 8669.000 / -2.485 / .013 / -.436463 / -.051535
a. Dependent Variable: test.
Estimates of Covariance Parameters
Parameter / Estimate / Std. Error / Wald Z / Sig. / 95% Confidence Interval
Lower Bound / Upper Bound
Repeated Measures / Var: [time=0] / 61.399873 / 2.003852 / 30.641 / .000 / 57.595371 / 65.455684
Var: [time=1] / 61.448416 / 1.155968 / 53.158 / .000 / 59.224020 / 63.756358
Var: [time=2] / 27.124323 / 1.726829 / 15.708 / .000 / 23.942443 / 30.729067
Intercept + time [subject = id] / UN (1,1) / 30.649177 / 1.828750 / 16.760 / .000 / 27.266539 / 34.451459
UN (2,1) / -3.305822 / 1.012774 / -3.264 / .001 / -5.290823 / -1.320821
UN (2,2) / 7.465096 / .873415 / 8.547 / .000 / 5.935331 / 9.389141
a. Dependent Variable: test.
The traditional analysis did not include any tests of significance of the variances or covariances.
Graphical representations of the significant results
The time effect – Test scores increased over time
The effective effect – Kids with effective teachers performed better from the get-go???
The time*effective effect – Kids with effective teachers increase more over time.
The time*ses effect – Kids with high ses didn’t increase as much over time as kids with low ses.