Hi Stephanie, TH1::GetEntries return the number of entries (number of calls to TH1::Fill). This includes underflow and overflow entries. The GetMean/RMS use only the bins in the nortmal range. You can use TH1::Integral(Int_t binx1, Int_t binx2) to return the integral of the bin contents in a specified range. TH1::Integral() returns the integral of the bin contents in the histogram range. This should be OK for you if you are filling with weights=1. Rene Brun On Fri, 6 Oct 2000, S. Escoffier-300901 wrote: > > Dear rooters, > > I want to get mean and entries of a TH1F histogram. > So I call h1->GetEntries() and h1->GetMean(). > > But if I modifie the range of my histogram (smaller range), and I fill it > in the same conditions (some events are out of range), so the mean > value has changed, but nentries is the same than before, and there is > neither overflow nor underflow ! I obtain the same result with graphical > options if I select a specific range of my histogram. > So, how could I know on what events the mean value is obtained? > Maybe I do something wrong.. > I use the 2.25 /02 version on Solaris. > > Thank you, > > Stephanie. > >
This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:34 MET