Comparing the Linear Mixed Effects object to SAS PROC MIXED

The following outlines differences between LinMix and PROC MIXED in SAS.

Degrees of freedom 

LinMix: Uses Satterthwaite approximation for all degrees of freedom, by default. However, Residual is another option.

PROC MIXED: Chooses different defaults based on the model, random, and repeated statements. To match LinMix, set the SAS ‘ddfm=satterth’ option.

Multiple factors on the same random command 

LinMix: Effects associated with the matrix columns from a single random statement are assumed to be correlated per the variance specified. Regardless of variance structure, if random effects are correlated, put them on the same random tab; if independent, put them on separate tabs.

PROC MIXED: Similar to LinMix, except it does not follow this rule in the case of Variance Components, so LinMix and SAS will differ for models with multiple terms on a random statement using the VC structure.

REML 

LinMix: Uses REML (Restricted Maximum Likelihood) estimation, as defined in Corbeil and Searle (1976), does maximum likelihood estimation on the residual vector.

PROC MIXED: Modifies the REML by ‘profiling out’ residual variance. To match LinMix, set the ‘noprofile’ option on the PROC MIXED statement. In particular, LinMix –log(likelihood) may not equal twice SAS ‘–2 Res Log Like’ if noprofile is not set.

Akaike and Schwarz’s criteria 

LinMix: Uses the smaller-is-better form of AIC and SBC in order to match Phoenix.

PROC MIXED: Uses the bigger-is-better form. In addition, AIC and SBC are functions of the likelihood, and the likelihood calculation method in LinMix also differs from SAS.

Saturated variance structure 

LinMix: If the random statement saturates the variance, the residual is not estimable. Sets the residual variance to zero. A user-specified variance structure takes priority over that supplied by LinMix.

PROC MIXED: Sets the residual to some other number. To match LinMix, add the SAS residual to the other SAS variance parameter estimates.

Convergence criteria 

LinMix: The convergence criterion is gT H–1g < tolerance with H positive definite, where g is the gradient and H is the Hessian of the negative log-likelihood.

PROC MIXED: The default convergence criterion options are ‘convh’ and ‘relative’. The LinMix criterion is equivalent to SAS with the ‘convh’ and ‘absolute’ options set.

Modified likelihood 

LinMix: Tries to keep the final Hessian (and hence the variance matrix) positive definite. Determines when the variance is over-specified and sets some parameters to zero.

PROC MIXED: Allows the final Hessian to be nonpositive definite, and hence will produce different final parameter estimates. This often occurs when the variance is over-specified (i.e., too many parameters in the model).

Keeping VC positive 

LinMix: For VC structure, LinMix keeps the final variance matrix positive definite but will not force individual variances > 0.

PROC MIXED: If a negative variance component is estimated, 0 is reported in the output.

Partial tests of model effects 

LinMix: The partial tests in LinMix are not equivalent to the Type III method in SAS though they coincide in most situations. See the “Partial Tests worksheet” section.

PROC MIXED: The Type III results can change depending on how one specifies the model. For details, consult the SAS manual.

Not estimable parameters 

LinMix: If a variable is not estimable, ‘Not estimable’ is reported in the output. LinMix provides the option to write out 0 instead.

PROC MIXED: SAS writes the value of 0.

ARH, CSH variance structures 

LinMix: Uses the standard deviations for the parameters, and prints the standard deviations in the output.

PROC MIXED: Prints the variances in the output for final parameters, though the model is expressed in terms of standard deviations.

CS variance structure 

LinMix: Does not estimate a Residual parameter but includes it in the csDiag parameter.

PROC MIXED: Estimates Residual separately. csDiag = Variance + Residual in SAS.

UN variance structure 

LinMix: Does not estimate a Residual parameter but includes it in the diagonal term of the UN matrix.

PROC MIXED: Estimates Residual separately. UN (1,1) = UN(1,1) + Residual in SAS, etc. (If a weighting variable is used, the Residual is multiplied by 1/weight.)

Repeated without any time variable 

LinMix: Requires an explicit repeated model. To run some SAS examples, a time variable needs to be added.

PROC MIXED: Does not require an explicit repeated model. It instead creates an implicit time field and assumes data are sorted appropriately.

Group as classification variable 

LinMix: Requires variables used for the subject and group options to be declared as classification variables.

PROC MIXED: Allows regressors but requires data to be sorted and considers each new regressor value to indicate a new subject or group. Classification variables are treated similarly.

Singularity tolerance 

LinMix: Define dii as the i-th diagonal element of the QR factorization of X, and Dii the sum of squares of the i-th column of the QR factorization. The i-th column of X is deemed linearly dependent on the proceeding columns if dii2 < (singularity tolerance)´Dii. If intercept is present, the first row of Dii is omitted.

PROC MIXED: Define dii as the diagonal element of the XTX matrix during the sweeping process.
If the absolute diagonal element |dii| < (singularity tolerance)´Dii, where Dii is the original diagonal of XTX, then the parameter associated with the column is set to zero, and the parameter estimates are flagged as biased.


Legal Notice | Contact Certara
© Certara USA, Inc. All rights reserved.