Scale graphs with different y axes

Hi,

I have two graphs with different y-axes and I want to plot them on the same canvas. I need to scale both graphs to normalize the y axes.

Can I simply scale each graph before plotting them?

You can modify graph’s points as you wish.

You can also have a single pad with two pairs of different X and Y axes:

Ok, thanks.

I need only one Y axis, so I think it’s better if I normalize each graph independently and then plot them on the same canvas. I think it should work.

TMultiGraph

TMultigraph is the best solution. But in case one of the graph (let’s say g1) has a range that includes the range of the other one (let’s say g2). You can simply draw them in the order:

g1->Draw("AL");
g2->Draw("L")

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.