Re: Copy subrange of an Histogam

Rene Brun (Rene.Brun@cern.ch)
Tue, 27 Jul 1999 08:06:06 +0000


Norbert Danneberg wrote:
>
> Hi,
>
> is there a clever way to copy a subrange, from bin min to bin max, of
> one histogram into another ?

Hi Norbert,
Simply do:
for (Int_t bin=binmin;bin<binmax;bin++) h2->SetBinContent(bin,
h1->GetBinContent(bin));

Rene Brun