Re: Can't get TH2:GetBinLowEdge to return both axes

Rene Brun (Rene.Brun@cern.ch)
Fri, 06 Jun 1997 10:36:37 +0200


Chris Green wrote:
>
> (v1.01/4)
>
> Hi,
>
> Can't seem to get this function to tell me what I want to know -- ie the
> bin edges in both the X and Y directions. Is this possible? Is there some
> other way of finding out what I want to know (as it stands, it appears to
> return only the Y axis low edge).

TH1::GetBinLowEdge is a shortcut for
h->GetXaxis()->GetBinLowEdge

To be general, I would strongly recommend to always get the
axis info (1-d,2-d,3-d, why-not multi-d}) via
TAxis *xaxis = h->GetXaxis(); xlow = xaxis->GetBinLowEdge(bin);
TAxis *yaxis = h->GetYaxis(); ylow = yaxis->GetBinLowEdge();
etc.

Rene Brun