Hi Luca,
I would suggest this:
TTree *data = ....
data->Draw("variable>>his");
TH1F *his = gDirectory->Get("his");
his->GetRMS();
his->GetMean();
etc....
Arne.
On 10/07/2009 12:48 AM, Luca Grandi wrote:
> Dear ROOT users,
>
> I am looking for a way to get mean, rms, min and max of a variable in
> a tree once applied some cuts on the events. Apart from plotting the
> distribution and extracting the info from the Stat box, is there a
> different way to do it?
> regards
>
> luca
>
-- Arne Vandenbroucke, Stanford University Dept. of Radiology, Alway Building M001 300 Pasteur Drive, STANFORD, CA 94305-5128 Tel : +1 650 498 4591Received on Wed Oct 07 2009 - 21:59:15 CEST
This archive was generated by hypermail 2.2.0 : Thu Oct 08 2009 - 11:50:02 CEST