I'm running two linear spline mixed-effects models (growth curve analysis) looking at mental health and BMI development over time (models include 4 splines for 4 time periods):
for mental health:
Code:
eststo: mi estimate, post: mixed mh age10_16 age16_23 age23_33 age33_42 || id: agec, cov(unstr) mle stddev
Code:
eststo: mi estimate, post: mixed bmi age10_16 age16_23 age23_33 age33_42 || id: agec, cov(unstr) mle stddev
I would now like to predict the individual-level intercepts and slopes for mental health & BMI generated by the above two models as I plan to run further linear regressions between them.
So, I would have mental heath slope and intercepts variables and BMI slope and intercepts variables (generated from the spline models above) to run a regular linear regression like:
regress bmislope mentalhealthslope bmi-intercept mh-intercept
Running, for mental health:
Code:
predict mh
Thanks!
/Amal
0 Response to Predicting individual-level slopes and intercepts after running mixed-effects models
Post a Comment