I have produced a graph using the community-contributed command tableplot.
The graph itself is fine, but on the x-axis there are a lot of years, which overlap and are not legible. I have thus tried to label only every decade or something similar. My initial attempts did not work, so I checked the Stata manual.
However, the manual appears to confirm that I coded it correctly xlabel(1935(5)1955). I then tried to feed Stata a fixed number of labels xlabel(#10). This works better, but the first label is year 0. Obviously year 0 is not in the data and there are no missing values or any other issues with the data.
I have reproduced the problem with an example dataset below and the problems are the same:
use http://www.stata-press.com/data/r15/grunfeld.dta, clear
codebook year
tableplot rbar invest company year, graphregion(color(none)) bgcolor(white) subtitle("") ///
xtitle("Year") ytitle("Firm")
tableplot rbar invest company year, graphregion(color(none)) bgcolor(white) subtitle("") ///
xtitle("Year") ytitle("Firm") xlabel(1935(5)1955)
*Coding is in line with Stata manual page 9:
*https://www.stata.com/manuals13/g-3axis_label_options.pdf
tableplot rbar invest company year, graphregion(color(none)) bgcolor(white) subtitle("") ///
xtitle("Year") ytitle("Firm") xlabel(#10)
I would be happy if somebody could point out to me how I can convince Stata and tableplot to label the x-axis from a specified start-year(1935) to an end-year(1955) with a given interval in between.
I use Stata 15 and the most up to date version of tableplot.



tableplot rbar invest company year, graphregion(color(none)) bgcolor(white) subtitle("") xtitle("Year") ytitle("Firm") xlabel(1(5)20)I do not understand why it is setup in this way, but thanks! - Christoph