I am trying to graph multiple graphs overlying on top of each other.
Each graph needs to look at the sum of variable "patients" but I limit the number of patients I look at by a different variable.
the x axis is variable "years".
So basically I want to put these three graphs on top of each other where pyp_planar is the botton, pyp_spect is next and pyp_spectct is on top.
graph bar (sum) patients if pyp_planar==1&state=="National", over(year) name (pyp_planar)
graph save Graph "D:\MPOP_geography\mpop_pyp_planar.gph"
graph bar (sum) patients if pyp_spect==1&state=="National", over(year) name (pyp_spect)
graph save Graph "D:\MPOP_geography\mpop_pyp_spect.gph"
graph bar (sum) patients if pyp_spectct==1&state=="National", over(year) name (pyp_spectct)
graph save Graph "D:\MPOP_geography\mpop_pyp_spectct.gph"
when I tried -graph combine- each graph was graphed separately. They were also not labeled so I am not able to tell which graph presents which data.
I would also like to do the same thing as line graphs.
Thanks for the help.
Each graph needs to look at the sum of variable "patients" but I limit the number of patients I look at by a different variable.
the x axis is variable "years".
So basically I want to put these three graphs on top of each other where pyp_planar is the botton, pyp_spect is next and pyp_spectct is on top.
graph bar (sum) patients if pyp_planar==1&state=="National", over(year) name (pyp_planar)
graph save Graph "D:\MPOP_geography\mpop_pyp_planar.gph"
graph bar (sum) patients if pyp_spect==1&state=="National", over(year) name (pyp_spect)
graph save Graph "D:\MPOP_geography\mpop_pyp_spect.gph"
graph bar (sum) patients if pyp_spectct==1&state=="National", over(year) name (pyp_spectct)
graph save Graph "D:\MPOP_geography\mpop_pyp_spectct.gph"
when I tried -graph combine- each graph was graphed separately. They were also not labeled so I am not able to tell which graph presents which data.
I would also like to do the same thing as line graphs.
Thanks for the help.
Comment