46 _parName(poi->
first()->GetName()),
47 _plc(0),_ul(0),_poi(0), _data(0),_cl(CL), _model(0)
49 std::cout<<
"RooUpperLimitConstructor ParName:"<<
_parName<<std::endl;
50 std::cout<<
"RooUpperLimitConstructor CL:"<<
_cl<<std::endl;
62 _parName(other._poi->
first()->GetName()),
63 _plc(0),_ul(0),_poi(other._poi), _data(0), _cl(other._cl), _model(other._model)
97 coutE(InputArguments) <<
"UpperLimitMCSModule::initializeInstance:: ERROR: No parameter named " <<
_parName <<
" in RooMCStudy!" << endl ;
103 std::cout<<
"RooUpperLimit Initialize Instance: POI Set:"<<std::endl;
105 std::cout<<
"RooUpperLimit Initialize Instance: End:"<<std::endl;
171 std::cout<<
"after generation Test"<<std::endl;
189 if (!pllint)
return false;
192 std::cout<<(static_cast<RooRealVar*>((
fitParams()->find(
_parName.c_str()))))->getVal()<<std::endl;
204 std::cout<<
"UL:"<<
_ul->
getVal()<<std::endl;
char * Form(const char *fmt,...)
Formats a string in a circular formatting buffer.
RooAbsArg * first() const
RooAbsArg * find(const char *name) const
Find object with given name in list.
void Print(Option_t *options=nullptr) const override
This method must be overridden when a class wants to print itself.
virtual Int_t numEntries() const
Return number of entries in dataset, i.e., count unweighted entries.
RooAbsMCStudyModule is a base class for add-on modules to RooMCStudy that can perform additional calc...
RooAbsData * genSample()
Return generate sample.
RooAbsPdf * fitModel()
Return fit model.
RooArgSet * fitParams()
Return current value of parameters of fit model.
RooArgSet * fitInitParams()
Return initial value of parameters of fit model.
double getVal(const RooArgSet *normalisationSet=nullptr) const
Evaluate object.
RooArgSet is a container object that can hold multiple RooAbsArg objects.
RooDataSet is a container class to hold unbinned data.
void add(const RooArgSet &row, double weight=1.0, double weightError=0.0) override
Add one ore more rows of data.
RooRealVar represents a variable that can be changed from the outside.
void setVal(double value) override
Set value of variable to 'value'.
void SetTestSize(double size) override
set the size of the test (rate of Type I error) ( Eg. 0.05 for a 95% Confidence Interval)
ConfInterval is an interface class for a generic interval in the RooStats framework.
LikelihoodInterval is a concrete implementation of the RooStats::ConfInterval interface.
double UpperLimit(const RooRealVar ¶m)
return the upper bound of the interval on a given parameter
The ProfileLikelihoodCalculator is a concrete implementation of CombinedCalculator (the interface cla...
LikelihoodInterval * GetInterval() const override
Return a likelihood interval.
This class allow to compute in the ToyMcStudy framework the ProfileLikelihood upper limit for each to...
const RooArgSet * _poi
parameters of interest
UpperLimitMCSModule(const RooArgSet *poi, double CL=0.95)
RooDataSet * finalizeRun() override
Return auxiliary dataset with results of delta(-log(L)) calculations of this module so that it is mer...
~UpperLimitMCSModule() override
Destructor.
bool processBetweenGenAndFit(Int_t) override
Method called after generation of toy data sample and resetting of fit parameters to initial values a...
RooStats::ProfileLikelihoodCalculator * _plc
bool initializeRun(Int_t) override
Initialize module at beginning of RooCMStudy run.
std::string _parName
Name of Nsignal parameter.
RooDataSet * _data
Summary dataset to store results.
bool initializeInstance() override
Initialize module after attachment to RooMCStudy object.
const char * Data() const
Namespace for the RooStats classes.