Is RooTreeData mean() correct?

in inc/RooTreeData.h there appears the line:

Double_t mean(RooRealVar& var, const char* cutSpec=0, const char* cutRange=0) const { return moment(var,0,0,cutSpec,cutRange) ; }

This looks like it’s asking for the 0th moment, so mean() will always return 1.0? Is this the intended behaviour?! Or am I missing something? :confused:

Hi,

Thanks for finding that, this was incidentally also just pointed out to me by Kyle. This is was a mistake on my side. I’m fixing it now. You should be able to call the moment() function directly in the mean time to get the answer out.

Wouter