Hi,
I have a time-series dataset with some variables and where time is in years (1870-2017). To be precise, I use the Schularick 2017 macro dataset.
The problem I am facing is that line graphs I produce with the standard syntax (line y-var year) come with an x-axis starting in 1850 and ending in 2050. This makes the graphs too wide and more difficult to read.
I tried the xscale command as well as the tscale options, for line, toway, and tsline commands. none worked, with different errors.
I could not find yet an easy, intuitive solution for that problem, although my understanding is that it is a rather trivial problem?
Thus, my question is, can someone suggest a simple code-line for a line-graph where I can set the x-axis in an intuitive way?
I would like to eventually build this into a linecall code.
best wishes,
Chris
I have a time-series dataset with some variables and where time is in years (1870-2017). To be precise, I use the Schularick 2017 macro dataset.
The problem I am facing is that line graphs I produce with the standard syntax (line y-var year) come with an x-axis starting in 1850 and ending in 2050. This makes the graphs too wide and more difficult to read.
I tried the xscale command as well as the tscale options, for line, toway, and tsline commands. none worked, with different errors.
Code:
line gdp year, xscale(1900-2000) *option 1900-2000 not allowed tsline gdp, tscale(1900-2000) *option 1900-2000 not allowed
Thus, my question is, can someone suggest a simple code-line for a line-graph where I can set the x-axis in an intuitive way?
I would like to eventually build this into a linecall code.
best wishes,
Chris
Comment