Hello everyone,
I have panel data for two cities and I would like to present the predicted probabilities of my depend variable (working from home) by observation age. I managed to do it (I think) for each city separately using the following code:
xtset id _t
xtlogit home age_observation if city==1, vce(cluster id)
margins, predict(pr) at(age_observation=(15(1)60))
marginsplot, noci //
xlabel(15(5)60)
I can do the same for the other city but I would like to have the distributions of the predicted probabilities for both cities on the same graph.
Any idea? Thanks.
Anne
I have panel data for two cities and I would like to present the predicted probabilities of my depend variable (working from home) by observation age. I managed to do it (I think) for each city separately using the following code:
xtset id _t
xtlogit home age_observation if city==1, vce(cluster id)
margins, predict(pr) at(age_observation=(15(1)60))
marginsplot, noci //
xlabel(15(5)60)
I can do the same for the other city but I would like to have the distributions of the predicted probabilities for both cities on the same graph.
Any idea? Thanks.
Anne
Comment