I am using HistFactory in ROOT to perform a fit and I would like to obtain the per bin MC statistical errors of each sample or template after the fit.
In the RooStats::HistFactory::Sample class reference, there is the
GetStatError() function that returns a StatError object, which I believe provides information about the MC statistical uncertainty.
First, do I need to do
ActivateStatError() for each sample before the fit, in order for the
GetStatError() to return MC statistical uncertainty correctly?
Second, if the fit varies the normalisation factors (from
AddNormFactor to the sample) and shape variations (from
AddHistoSys to the sample), does the MC statistical uncertainties obtained from
GetStatError() reflect the changes in the normalisation factors and shape variations?