Re: [ROOT] Re: TProfile->Scale()

From: Rene Brun (Rene.Brun@cern.ch)
Date: Fri Apr 14 2000 - 11:46:13 MEST


Art,
I have introduced a new function :
  TH1D *TProfile::ProjectionX(const char* name="_px", const char *option="e")

Similarly to TH2::ProjectionX, this new function fills the profile projection
along X. It creates a TH1D histogram. if the option "e" is specified
the histogram has the profile error bars.

Rene Brun

Art Poskanzer wrote:
> 
> Rene:
> 
> Thanks for telling me that the only way to scale a TProfile in a 1D sense is to
> convert it to a 1D. This is what I suspected in my original mail.
> 
> The behavior of TProfile::Scale() is correct if you think of a profile only as
> the mean of the y of a 2D vs. x. But many of us use a profile histogram to
> calculate the mean of any quantity vs. x. We fill the profile with the quantity
> as the weight. Then manipulations, like Scale() of the contents, make sense.
> Thus, I think, it would be good to have a TProfile function to transform to a
> 1D, so that 1D style manipulations could be done. I suggest this for a future
> improvement.
> 
> Art
> 
> Brun wrote:
> 
> > Art,
> >
> > The behaviour of TProfile::Scale is correct in PAW and Root.
> >
> > Rene Brun
> >
> > Art Poskanzer wrote:
> > >
> > > > Is the only way to convert it to loop over the bins getting each
> > > > content and error and putting them into the 1D?
> > > >
> > > > Art Poskanzer and Glenn Cooper
> 
>   --------------------------------------------------------------------------------
> 
>   Art Poskanzer <AMPoskanzer@lbl.gov>
>   Lawrence Berkeley National Laboratory
> 
>   Art Poskanzer
>   Lawrence Berkeley National Laboratory  <AMPoskanzer@lbl.gov>
>                                          HTML Mail
>                                          Fax: 510-486-7105
>                                          Home: 510-841-4710
>                                          Work: 510-486-5618
>                                          Netscape Conference Address
>                                          Specific DLS Server
>   Additional Information:
>   Last Name   Poskanzer
>   First Name  Art
>   Version     2.1



This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:23 MET