Dear Stata users,
I am trying to find a way to inetgrate a vertical line in a hbar graph. This graph represents the growth of variable 1, 2 and 3 for four different groups, by year, and I would like to add a vertical line, for each year, at the level of the growth of variable 4 (which takes the same value for each group since it's the growth rate of the population). Here is the code I use, without the vertical line:
Could someone help with adding the line?
Thanks a lot in advance!
Best regards,
Quentin
I am trying to find a way to inetgrate a vertical line in a hbar graph. This graph represents the growth of variable 1, 2 and 3 for four different groups, by year, and I would like to add a vertical line, for each year, at the level of the growth of variable 4 (which takes the same value for each group since it's the growth rate of the population). Here is the code I use, without the vertical line:
Code:
graph hbar (asis) var1_growth var2_growth var3_growth, over(groups) /// by(year, title("XXX") /// graphregion(color(white)) note("") ylabel(,angle(0) axis(1)) /// stack legend(order(1 "var1" 2 "var2" 3 "var3") pos(6) col(3))
Thanks a lot in advance!
Best regards,
Quentin
Comment