|
From: Alexander P. <a.h...@gm...> - 2012-03-04 13:45:33
|
---------- Forwarded message ----------
From: Alexander Pohl <a.h...@gm...>
Date: 4 March 2012 12:49
Subject: newhistogram bars not matching tics position
To: gnu...@li...
Hi,
I would like to assign a different line style to the first bar than to the
rest of the bars in the histogram. For this I use indices and the
newhistogram command. The problem I have is that the bars are not centred
at the tic marks, but offset by half the bar width to the right. This looks
ugly and I need to urgently resolve this.
here is the data file:
# set A
0 3.5241611 0.0227152
# set B
1 3.4974980 0.0250806
2 3.5143099 0.0287665
3 3.5097331 0.0305371
4 3.5412929 0.0294131
5 3.5442677 0.0299973
And here the gnuplot plot:
set terminal wxt
set xtics ("Bar1" 0, "Bar2" 1, "Bar3" 2, "Bar4" 3, "Bar5" 4, "Bar5" 5)
plot 'plot.dat' index 0 using 2 title '' with histogram,\
newhistogram '' at 1, '' index 1 using 2 title '' with histogram,\
'' index 0 using 1:2:3 ti '' with yerrorbar,\
'' index 1 using 1:2:3 ti '' with errorlines
Anybody knows how to centre the bars under the tics marks?
Thanks for any help,
Alexander
|