hello !
I would like to know by what line commands, I can get back the average or the RMS of a histogram to use it, to draw a curve.
I wrote a program which allows me to read data from an ascii file and form 64 histograms. I need 64 RMS of these histograms to draw a curve of the variation of the RMS. At present I copy out 64 RMS by hand, and it is a very painful and long work.
The command TpaveStats* ps = (TPaveStats *)h - > GetListOfFunctions() - > FindObject (" stats ");Allows me to get back all the statistical table. But what I want is to get the RMS and the average.
Hello and thank you before.
[quote=“papajean”]hello !
I would like to know by what line commands, I can get back the average or the RMS of a histogram to use it, to draw a curve.
I wrote a program which allows me to read data from an ascii file and form 64 histograms. I need 64 RMS of these histograms to draw a curve of the variation of the RMS. At present I copy out 64 RMS by hand, and it is a very painful and long work.
The command TpaveStats* ps = (TPaveStats *)h - > GetListOfFunctions() - > FindObject (" stats ");Allows me to get back all the statistical table. But what I want is to get the RMS and the average.
Hello and thank you before.[/quote]
I assume that h is the histogram pointer, in this case using the calls:
Double_t mean = h->GetMean();
Double_t RMS = h->GetRMS();
I think I’ll obtain what you want, exist the *Error() also, returning the error for each parameter.