RooFIt: get sigma() from a dataset within a certain variable range

Hi,
In RooFit, I would like o use the sigma() function from a simple dataset to calculate its RMS. I want to specify the range of the variable for this.
According to the reference, it is possible: https://root.cern.ch/root/html/RooAbsData.html#RooAbsData:sigma

But I don’t understand how to skip the cutSpec argument and how to specify the cutRange properly. These don’t work for me:

ds.sigma(var, None, "myRangeName") ds.sigma(var, "", "myRangeName")

Any help would be great.

My solution to the problem is to use reduce() function to a dataset before sigma().
Still, would be nice to use this functionality in sigma() itself.

Andrey,

yes, it should be possible to pass nullptr. I have zero time for PyROOT at the moment. Please file a bug report (sft.its.cern.ch/jira/browse/ROOT) to keep track of this issue.

Cheers,
Wim