This problem seems rather random, I was plotting multiple data sets and most of them would show the correct custom tickmarks, except one set with longer data record. I extracted the values and simplied the codes as below:
Notice the two empty string in xticks I added for the first and last value, this is so that all bars will be plotted inside the figure without being cut off.
bar1=[44,2,10,8,67,21,55,77,9,6,48,95,18,93,55,63,115,124,31,11,6,0]
xvals=indgen(n_elements(bar1))
xticks=[' ',' 3',' 4',' 5',' 6',' 7',' 8',' 9','10','11','12','13',$
'14','15','16','17','18','19','20','21','22','23',' 0',' ']
b1=barplot(xvals,bar1,fill_color='red',xtickname=xticks)
I tried the "wiggle" method you suggested and the redrawing didn't fix the issue. Plus since I'm plotting multiple data sources and save the plot directly to a file, this mannual "fixing" method won't really work for me.
I appreaciate you reporting this bug, and please give me update when it is resolved. Thank you!
FYI, I'm running 8.0.1 in Fedora 13 64-bit.
|