From: Mikhail K. <mko...@gm...> - 2012-12-10 01:40:03
|
there are two things involved, tic interval and tic label format. with set format x "%b %Y" you manually set tic label format to "month year". but x tic interval is not changed. by default x tic interval is calculated by gnuplot automatically based on x data range. with automatic x tic interval and a short x range (like 1-2 months or less) you can get several xtics within one month, like 2012-12-01, 2012-12-20 or so. As right before you've set format x "%b %Y" you will see both tics displayed as "Dec 2012". This will not happen if xrange is long enough. You can plot some data several years long with you script, for example, by making two test data points like: 2010-01-01 1.1 2012-06-01 1.2 and check x tics and x tic labels on the resulting plot. On 07/12/2012 16:26, Victor Porton wrote: > I have calculated average value of some data for each month (each month during which the data was collected). > > I need to display this average data. > > Now I have the trouble to display month names at the X-axis. Each month name should be displayed maximum once. > > "set format x ''%b %Y" however outputs several major tics with the same label (month name). > > Also: if I I display every month name, then I will (a few years later) run out of horizontal space in X-axis to display all month names. What to do? > |