Results of Analysis of Sim.dat by PROC MIXED (2 groups * 10 subjects/grp * 97 obs per subject=1940 observations) ****************************** Step 1 ********************************* INITIAL MODEL Fixed Effects: Rx + first 5 frequencies + interactions + age + sex Random Effects: Intercept Program: Sim1.sas 1) Without AR Covariance Parameter Estimates (REML) Cov Parm Ratio Estimate Std Error Z Pr > |Z| INTERCEPT UN(1,1) 2.75334143 10.46459448 3.71364614 2.82 0.0048 Residual 1.00000000 3.80068900 0.12331063 30.82 0.0001 REML Log Likelihood -4120.57 Schwarz's Bayesian Criterion -4128.13 2) With AR Covariance Parameter Estimates (REML) Cov Parm Ratio Estimate Std Error Z Pr > |Z| INTERCEPT UN(1,1) 2.21115528 9.85296646 3.67042443 2.68 0.0073 ARTIME AR(1) 0.19191450 0.85517608 0.01344112 63.62 0.0001 Residual 1.00000000 4.45602647 0.41501487 10.74 0.0001 REML Log Likelihood -2969.65 Schwarz's Bayesian Criterion -2980.99 Estimate of Bayes Factor in favor of no AR component= exp(-4128.13-(-2980.99))=exp(-1147.14)=extremely small. Note the Bayes Factor could have been calculated as exp(-4120.57-(-2969.65)+ 0.5*(3-2)*ln(1940)) where the first to numbers are log likelihoods rather than Schwarz's Bayesian Information Criterion, (3-2) is the difference in the number of parameters in the 2 models, and 1940 is the sample size. Conclusion: Include AR(1) in the model. ****************************** Step 2a ********************************* Fixed Effects: Rx + first 3 frequencies + interactions + age Program: Sim2a.sas 3) Random effects: AR+intercept Covariance Parameter Estimates (REML) Cov Parm Ratio Estimate Std Error Z Pr > |Z| INTERCEPT UN(1,1) 2.12758810 9.35765788 3.38683307 2.76 0.0057 ARTIME AR(1) 0.19408917 0.85365208 0.01345949 63.42 0.0001 Residual 1.00000000 4.39824695 0.40539056 10.85 0.0001 REML Log Likelihood -2964.76 Schwarz's Bayesian Criterion -2976.11 4) Random effects: AR+rx (type=UN) Covariance Parameter Estimates (REML) Cov Parm Ratio Estimate Std Error Z Pr > |Z| RX UN(1,1) 0.43504999 1.91074358 1.26255050 1.51 0.1302 UN(2,1) 0.00000000 0.00000000 . . . UN(2,2) 4.35220976 19.11494540 9.71416131 1.97 0.0491 ARTIME AR(1) 0.19431436 0.85343044 0.01343505 63.52 0.0001 Residual 1.00000000 4.39200922 0.40352024 10.88 0.0001 REML Log Likelihood -2961.95 Schwarz's Bayesian Criterion -2980.86 Estimate of Bayes Factor in favor of no rx component= exp(-2976.11-(-2980.86)+cf) |Z| RX UN(1,1) 0.43503811 1.91068555 1.26248734 1.51 0.1302 UN(2,1) 0.00000000 0.00000000 . . . UN(2,2) 4.35277928 19.11738846 9.71644496 1.97 0.0491 ARTIME AR(1) 0.19431486 0.85343004 0.01343504 63.52 0.0001 Residual 1.00000000 4.39199583 0.40351775 10.88 0.0001 REML Log Likelihood -2961.95 Schwarz's Bayesian Criterion -2977.07 (Note that the increase in BIC is equal to 0.5*ln(1940)=3.78. This comes from the BIC formula: log likelihood + 0.5*q*ln(N). In this case the number of parameters, q, in the alternate second model is reduced by 1 compared to the original second model. The REML loglikelihood is unchanged due to the fact that it is estimated as 0 in the original second model.) Now, we have exp(-2976.11-(-2977.07))=exp(0.96)=2.612. There is still weak evidence against separate variances for the random intercept of controls vs. treated subjects. Even though we know that we did simulate the data with a difference (4 vs 25), we continue the analysis based on the evidence found here by assuming a single random intercept. ****************************** Step 2b ********************************* Now we consider adding random slopes using program Sim2b.sas. ****************************** Step 3a ********************************* ****************************** Step 3b *********************************