0
$\begingroup$

Is it appropriate to create a mixed-effects model (for example, using SAS Proc Mixed) that specifies a random effect but does not include the random effect in the model itself?

I ask because it seems that doing that (excluding the random effect from the design) isn't easy (or perhaps even possible?) in SAS JMP or Statistica but can be done in SAS Studio - for example:

proc mixed ...;
   class re;
   model y = x1 x2 x3;
   random re;
run;

If so, how is it different (conceptually) from including the random effect in the model as well? (as is the case for Proc GLM which doesn't allow random effects that aren't in the model).

$\endgroup$

1 Answer 1

0
$\begingroup$

Conceptually, a random effect is either being fitted (coefficients being estimated, variance being accounted for, etc) or its not. Some software might compensate for a random effect omitted from the model statement and run the implied glm, other might throw an error.

You could run the model explicitly with and w/o the random effect and compare the results, and compare prox mixed to proc glm. The proc mixed code that runs successfully in SAS studio probably gives you identical results as what proc glm will give you.

R uses a syntax more akin to an algebraic expression, and you either write the random effect into the expression or you don't. R happens to throw an error if you don't include the random effect but use a modelling function (lme, lmer, glmer) that is for mixed effects. If you are comparing models via AIC or likelihood ratio tests and want to compare a model with a random effect to one that has none, you have to use a separate function, gls, to fit the model without the random effect.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.