I have a twoway plot that I draw for several years. I am trying to draw an xline at the median value for each year. How can I do that.
As an example
I want each of the 5 years to have an xline at the median income level for THAT year. So this is xline at a different value for each year- one xline per graph.
I know I could save the median value in a local and call that but that seems to draw multiple lines in every graph.
I appreciate the help!
As an example
Code:
twoway scatter income yrs_education, by (year)
I know I could save the median value in a local and call that but that seems to draw multiple lines in every graph.
I appreciate the help!
Comment