SetAxisRange(0.0,1.0,"Y"); is ineffective

I am trying to draw 4 histograms on the same canvas.

When I do this:

This call is absolutely ineffective. It does nothing with the Y axis range. How do you set the Y axis range?

Okay, I figured it out, it is utterly retarded, SetAxisRange has to be called after you call Scale or it doesn’t work.

This is probably a bug, it shouldn’t matter when Scale is called.

1 Like

From my experience … for a TH1 I am usually using something like this:
histo->SetAxisRange(xmin, xmax, “X”);
histo->SetAxisRange(ymin, ymax, “Y”);
histo->Draw(); // make sure it’s redrawn
If I am dealing with a THStack of several TH1 histograms, I am usually using something like this:
stack->GetXaxis()->SetLimits(xmin, xmax);
stack->Draw(“H”); // make sure it’s redrawn