I am trying to rescale the x-axis of a TH2. My problem is that I have a TH2 with custom bin sizes and the last bin is very large, 60% of the total width. In this case, this last bin goes from 40-100 (see attached plot).
I would like to rescale the x-axis such that all other bins remain the same (linear scale), but the last bin should shrink to ocupy only ~20% of the total x-width of the plot. The axis should still read “40” at the low edge of the bin and “100” at the high edge. Also, the content of the TH2 should not change.
Do you want your boxes to have equal size along x but non linear x labels?
if yes, post a file containing your histogram and I will show you how to do it.
this works for me, the labels are placed where I want them to be (to the edges of the new h2 bins), I am just interested if it was possible to change anyhow the axis markers which make no sense now so that they followed the labels.