Re: TH1::SetBins

Rene Brun (Rene.Brun@cern.ch)
Wed, 28 May 1997 09:41:18 +0200


OLSZEWSKI@vsk02.ifj.edu.pl wrote:
>
> Hi,
>
> when I SetBins(nx,lx,hx) on an existing histogram new boundaries (lx,hx)
> are not used to cut off contents outside of them as I would expect but
> rather the whole contents of the histogram is reallocated into new bins.
>

yes, when calling TH1::SetBins the whole histogram contents must
be reallocated. You change the number of bins, bin size, everything.
In Root, this function is called by TTree::Draw.

Rene Brun