Hi,
I am having a few difficulties plotting a graph of my growth curve model. I am using the -xtmixed- command to estimate both age and cohort differences (+ covariates) on a continuous variable. The model is fine, but I am having trouble plotting the graph. Specifically, I'm trying to produce cohort-specific age trajectories I have had a few attempts at plotting, such as the example below, but as you can see this does not look right. I used the following commands:
predict
separate, by(cohort)
twoway line X X X X
It looks better if a replace the dichotomous variables (i.e. replace X = 1) before I use the -predict- and -separate- function, but I worry this produces a graph that is not correct (although looks correct)
Any advice
Best
John
I am having a few difficulties plotting a graph of my growth curve model. I am using the -xtmixed- command to estimate both age and cohort differences (+ covariates) on a continuous variable. The model is fine, but I am having trouble plotting the graph. Specifically, I'm trying to produce cohort-specific age trajectories I have had a few attempts at plotting, such as the example below, but as you can see this does not look right. I used the following commands:
predict
separate, by(cohort)
twoway line X X X X
It looks better if a replace the dichotomous variables (i.e. replace X = 1) before I use the -predict- and -separate- function, but I worry this produces a graph that is not correct (although looks correct)
Any advice
Best
John
Comment