Hi,
I am trying to display a plot with two different axis which should be “attached” to the same datapoints.
I have tried to follow the tips here: http://root.cern.ch/root/html/tutorials/hist/transpad.C.html
but am not exactly getting the result I would like.
The point is: I have a graph, and I want to display the x-axis in two different formats, in my case, one with time, and the other with lumiblocks.
I tried the approach to make two versions of the same graph, and draw them on top of each other, with the second pad invisible. However, the second pad anyway seems to cover the first, and only the second graph drawn is shown (but both axis are as I want visible.)
I attach a small macro which shows the two graphs (which have identical y-values, but different x-values connected to them), drawn separately, and then tried to drawn together, but with the wrong result (only blue markers are shown, and not the red which are hidden beneath pad2).
Another difficulty is: I want to make sure that the two graphs really are drawn exactly on top of each other, that means that the x-values need to be spaced in the same way. Is there something I have to take especial care of then?
Thanks a lot,
Maiken
axisTest.py (6.08 KB)