Dear Stata users,
I am working on repeated measure data of kidney markers and trying to construct a mixed model.
In order to calculate eGFR decline, I would like to include age both as a linear and quadratic term and center for modeling, using random terms for intercept and age.
I wonder if the model was constructed correctly.
Many thanks,
Oyun
I am working on repeated measure data of kidney markers and trying to construct a mixed model.
In order to calculate eGFR decline, I would like to include age both as a linear and quadratic term and center for modeling, using random terms for intercept and age.
I wonder if the model was constructed correctly.
Code:
sum current_age gen current_age_c=current_age - `r(mean) ' mixed eGFR c.current_age_c i.other_variables || current_age: current_age_c, mixed eGFR c.current_age_c##c.current_age_c i.other_variables || current_age: current_age_c##current_age_c,
Oyun
Comment