OPTIONS nocenter; DATA ONE; INFILE 'C:\mixdemo\riesby.dat'; INPUT ID HamD Intcpt Week Endog EndWeek ; /* SET UP ORTHOGONAL POLYNOMIALS */ IF WEEK = 0 THEN DO; CONS = 1 / SQRT(6); LIN = -5 / SQRT(70); QUAD = 5 / SQRT(84); CUBIC = -5 / SQRT(180); END; IF WEEK = 1 THEN DO; CONS = 1 / SQRT(6); LIN = -3 / SQRT(70); QUAD = -1 / SQRT(84); CUBIC = 7 / SQRT(180); END; IF WEEK = 2 THEN DO; CONS = 1 / SQRT(6); LIN = -1 / SQRT(70); QUAD = -4 / SQRT(84); CUBIC = 4 / SQRT(180); END; IF WEEK = 3 THEN DO; CONS = 1 / SQRT(6); LIN = 1 / SQRT(70); QUAD = -4 / SQRT(84); CUBIC = -4 / SQRT(180); END; IF WEEK = 4 THEN DO; CONS = 1 / SQRT(6); LIN = 3 / SQRT(70); QUAD = -1 / SQRT(84); CUBIC = -7 / SQRT(180); END; IF WEEK = 5 THEN DO; CONS = 1 / SQRT(6); LIN = 5 / SQRT(70); QUAD = 5 / SQRT(84); CUBIC = 5 / SQRT(180); END; PROC MIXED METHOD=ML COVTEST; CLASS ID; MODEL HAMD = WEEK WEEK*WEEK /SOLUTION; RANDOM INTERCEPT WEEK WEEK*WEEK /SUB=ID TYPE=UN G GCORR; PROC MIXED METHOD=ML COVTEST; CLASS ID; MODEL HAMD = CONS LIN QUAD /NOINT SOLUTION; RANDOM CONS LIN QUAD /SUB=ID TYPE=UN G GCORR; RUN; ------------- OUTPUT ------------- The SAS System The Mixed Procedure Model Information Data Set WORK.ONE Dependent Variable HamD Covariance Structure Unstructured Subject Effect ID Estimation Method ML Residual Variance Method Profile Fixed Effects SE Method Model-Based Degrees of Freedom Method Containment Class Level Information Class Levels Values ID 66 101 103 104 105 106 107 108 113 114 115 117 118 120 121 123 302 303 304 305 308 309 310 311 312 313 315 316 318 319 322 327 328 331 333 334 335 337 338 339 344 345 346 347 348 349 350 351 352 353 354 355 357 360 361 501 502 504 505 507 603 604 606 607 608 609 610 Dimensions Covariance Parameters 7 Columns in X 3 Columns in Z Per Subject 3 Subjects 66 Max Obs Per Subject 6 Observations Used 375 Observations Not Used 21 Total Observations 396 Iteration History Iteration Evaluations -2 Log Like Criterion 0 1 2399.57194989 1 3 2207.80524380 0.00019159 2 1 2207.64984879 0.00000256 3 1 2207.64788628 0.00000000 Convergence criteria met. Estimated G Matrix Row Effect ID Col1 Col2 Col3 1 Intercept 101 10.4400 -0.9151 -0.1122 2 Week 101 -0.9151 6.6379 -0.9365 3 Week*Week 101 -0.1122 -0.9365 0.1937 Estimated G Correlation Matrix Row Effect ID Col1 Col2 Col3 1 Intercept 101 1.0000 -0.1099 -0.07888 2 Week 101 -0.1099 1.0000 -0.8258 3 Week*Week 101 -0.07888 -0.8258 1.0000 Covariance Parameter Estimates Standard Z Cov Parm Subject Estimate Error Value Pr Z UN(1,1) ID 10.4400 3.5862 2.91 0.0018 UN(2,1) ID -0.9151 2.4076 -0.38 0.7039 UN(2,2) ID 6.6379 2.7613 2.40 0.0081 UN(3,1) ID -0.1122 0.4209 -0.27 0.7898 UN(3,2) ID -0.9365 0.4881 -1.92 0.0550 UN(3,3) ID 0.1937 0.09364 2.07 0.0193 Residual 10.5163 1.1061 9.51 <.0001 Fit Statistics -2 Log Likelihood 2207.6 AIC (smaller is better) 2227.6 AICC (smaller is better) 2228.3 BIC (smaller is better) 2249.5 Null Model Likelihood Ratio Test DF Chi-Square Pr > ChiSq 6 191.92 <.0001 Solution for Fixed Effects Standard Effect Estimate Error DF t Value Pr > |t| Intercept 23.7602 0.5521 65 43.04 <.0001 Week -2.6326 0.4790 65 -5.50 <.0001 Week*Week 0.05148 0.08835 65 0.58 0.5621 Type 3 Tests of Fixed Effects Num Den Effect DF DF F Value Pr > F Week 1 65 30.21 <.0001 Week*Week 1 65 0.34 0.5621 The SAS System The Mixed Procedure Model Information Data Set WORK.ONE Dependent Variable HamD Covariance Structure Unstructured Subject Effect ID Estimation Method ML Residual Variance Method Profile Fixed Effects SE Method Model-Based Degrees of Freedom Method Containment Class Level Information Class Levels Values ID 66 101 103 104 105 106 107 108 113 114 115 117 118 120 121 123 302 303 304 305 308 309 310 311 312 313 315 316 318 319 322 327 328 331 333 334 335 337 338 339 344 345 346 347 348 349 350 351 352 353 354 355 357 360 361 501 502 504 505 507 603 604 606 607 608 609 610 Dimensions Covariance Parameters 7 Columns in X 3 Columns in Z Per Subject 3 Subjects 66 Max Obs Per Subject 6 Observations Used 375 Observations Not Used 21 Total Observations 396 Iteration History Iteration Evaluations -2 Log Like Criterion 0 1 2399.57194989 1 3 2207.80524380 0.00019159 2 1 2207.64984879 0.00000256 3 1 2207.64788628 0.00000000 Convergence criteria met. Estimated G Matrix Row Effect ID Col1 Col2 Col3 1 CONS 101 111.91 37.9921 -10.1400 2 LIN 101 37.9921 37.0368 0.8224 3 QUAD 101 -10.1400 0.8224 7.2326 Estimated G Correlation Matrix Row Effect ID Col1 Col2 Col3 1 CONS 101 1.0000 0.5901 -0.3564 2 LIN 101 0.5901 1.0000 0.05025 3 QUAD 101 -0.3564 0.05025 1.0000 Covariance Parameter Estimates Standard Z Cov Parm Subject Estimate Error Value Pr Z UN(1,1) ID 111.91 21.6006 5.18 <.0001 UN(2,1) ID 37.9921 10.9202 3.48 0.0005 UN(2,2) ID 37.0368 8.9013 4.16 <.0001 UN(3,1) ID -10.1400 6.1888 -1.64 0.1013 UN(3,2) ID 0.8224 3.8025 0.22 0.8288 UN(3,3) ID 7.2326 3.4957 2.07 0.0193 Residual 10.5163 1.1061 9.51 <.0001 Fit Statistics -2 Log Likelihood 2207.6 AIC (smaller is better) 2227.6 AICC (smaller is better) 2228.3 BIC (smaller is better) 2249.5 Null Model Likelihood Ratio Test DF Chi-Square Pr > ChiSq 6 191.92 <.0001 Solution for Fixed Effects Standard Effect Estimate Error DF t Value Pr > |t| CONS 43.2353 1.3678 65 31.61 <.0001 LIN -9.9361 0.8643 65 -11.50 <.0001 QUAD 0.3145 0.5398 65 0.58 0.5621 Type 3 Tests of Fixed Effects Num Den Effect DF DF F Value Pr > F CONS 1 65 999.18 <.0001 LIN 1 65 132.17 <.0001 QUAD 1 65 0.34 0.5621