Best fit line on predicted repeated measures lines in graphs
Posted: Sun May 11, 2014 8:44 am
Hi all
So I have connected prediction lines for repeated measures (longitudinal) data (persons) and managed to graph these nicely. However, I was looking for a best fit line option for all these lines. This exists in Stata's xtline function, which I could use; however, Stata insists on colouring each of my panels in separate colours which make my head explode. (I've tried all options in Stata, only way is to create a for loop which I don't have time to experiment with now).
My best attempt was:
Request (additional) fixed effects-only predictions
Unreplicate these by the x variable (age) *However, age is continuous in my data set so does not result in fewer rows
I overlayed another plot of these merged fixed effects on age grouped by a constant, on top of my existing level-2 random-effects predicted lines
Needless to say if you think about it; didn't work...
Stephan
So I have connected prediction lines for repeated measures (longitudinal) data (persons) and managed to graph these nicely. However, I was looking for a best fit line option for all these lines. This exists in Stata's xtline function, which I could use; however, Stata insists on colouring each of my panels in separate colours which make my head explode. (I've tried all options in Stata, only way is to create a for loop which I don't have time to experiment with now).
My best attempt was:
Request (additional) fixed effects-only predictions
Unreplicate these by the x variable (age) *However, age is continuous in my data set so does not result in fewer rows
I overlayed another plot of these merged fixed effects on age grouped by a constant, on top of my existing level-2 random-effects predicted lines
Needless to say if you think about it; didn't work...
Stephan