Quantcast
Channel: Statalist
Viewing all articles
Browse latest Browse all 65136

Investigating associations vs prediction in linear mixed models

$
0
0
Hi!
I have a linear mixed model for longitudinal data that looks like:
Code:
mixed depvar c.cov1##c.age##c.age##c.age cov2 cov3 cov4 || id: age, mle cov(un) res(exp, t(time))
My aim here is to see whether cov1 is associated with how the depvar develops with age. I included age^3 because my dependent variable looks like a cubic (^3) function of age (depvar goes up, then down, then up again). Another reason for including age^3 was that this really improved the residuals vs fitted plot (made the variance look much more homogenous). I showed my model to a college, who critiziced me, saying I was making a prediction model, rather than a model for examining a covariate's interaction with age. So, my question is: when you are not making a model to predict, but rather to examine the effect of a covariate, how important is it that your model produces a plot (i.e., marginsplot) that resembles a plot with the actual data? Or should the age^2 and age^3 terms only be included if they change the estimates for cov1?

Example:
Let us say that the above model is a model that fits the data much better than the model beolw, but that the estimates for cov1 changes very little between the models. Should I still og for the more complex model (above) or settle with the more parsimonious model (below)?

Code:
mixed depvar c.cov1##c.age cov2 cov3 cov4 || id: age, mle cov(un) res(ep, t(time))
Best,
Kjell Weyde

Viewing all articles
Browse latest Browse all 65136

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>