46void rs_numberCountingCombination_expected();
47void rs_numberCountingCombination_observed();
48void rs_numberCountingCombination_observedWithTau();
52void rs_numberCountingCombination(
int flag=1)
55 rs_numberCountingCombination_expected();
57 rs_numberCountingCombination_observed();
59 rs_numberCountingCombination_observedWithTau();
63void rs_numberCountingCombination_expected()
90 f.AddModel(
s,2,wspace,
"TopLevelPdf",
"masterSignal");
95 f.AddExpData(
s,
b, db, 2, wspace,
"ExpectedNumberCountingData");
115 *wspace->
pdf(
"TopLevelPdf"), *poi, 0.05, nullParams);
121 cout <<
"-------------------------------------------------" << endl;
122 cout <<
"The p-value for the null is " << htr->
NullPValue() << endl;
123 cout <<
"Corresponding to a significance of " << htr->
Significance() << endl;
124 cout <<
"-------------------------------------------------\n\n" << endl;
138 RooArgSet* paramsOfInterest = nullParams;
139 plc.SetParameters(*paramsOfInterest);
150 lrPlot.SetMaximum(3.);
154 cout <<
"lower limit on master signal = " << lower << endl;
155 cout <<
"upper limit on master signal = " << upper << endl;
164 cout <<
"-------------------------------------------------" << endl;
165 std::cout <<
"Consider this parameter point:" << std::endl;
168 std::cout <<
"It IS in the interval." << std::endl;
170 std::cout <<
"It is NOT in the interval." << std::endl;
171 cout <<
"-------------------------------------------------\n\n" << endl;
175 cout <<
"-------------------------------------------------" << endl;
176 std::cout <<
"Consider this parameter point:" << std::endl;
179 std::cout <<
"It IS in the interval." << std::endl;
181 std::cout <<
"It is NOT in the interval." << std::endl;
182 cout <<
"-------------------------------------------------\n\n" << endl;
231void rs_numberCountingCombination_observed()
257 f.AddModel(
s,2,wspace,
"TopLevelPdf",
"masterSignal");
262 Double_t bkgMeas[2] = {111.23,98.76};
264 f.AddData(mainMeas, bkgMeas, dbMeas, 2, wspace,
"ObservedNumberCountingData");
284 *wspace->
pdf(
"TopLevelPdf"), *poi, 0.05, nullParams);
291 cout <<
"-------------------------------------------------" << endl;
292 cout <<
"The p-value for the null is " << htr->
NullPValue() << endl;
293 cout <<
"Corresponding to a significance of " << htr->
Significance() << endl;
294 cout <<
"-------------------------------------------------\n\n" << endl;
309 RooArgSet* paramsOfInterest = nullParams;
310 plc.SetParameters(*paramsOfInterest);
315 cout <<
"lower limit on master signal = " << lrint->
LowerLimit(*mu ) << endl;
316 cout <<
"upper limit on master signal = " << lrint->
UpperLimit(*mu ) << endl;
328void rs_numberCountingCombination_observedWithTau()
353 f.AddModel(
s,2,wspace,
"TopLevelPdf",
"masterSignal");
358 Double_t sideband[2] = {11123.,9876.};
360 f.AddDataWithSideband(mainMeas, sideband, tau, 2, wspace,
"ObservedNumberCountingDataWithSideband");
380 *wspace->
pdf(
"TopLevelPdf"), *poi, 0.05, nullParams);
385 cout <<
"-------------------------------------------------" << endl;
386 cout <<
"The p-value for the null is " << htr->
NullPValue() << endl;
387 cout <<
"Corresponding to a significance of " << htr->
Significance() << endl;
388 cout <<
"-------------------------------------------------\n\n" << endl;
403 RooArgSet* paramsOfInterest = nullParams;
404 plc.SetParameters(*paramsOfInterest);
411 cout <<
"lower limit on master signal = " << lrint->
LowerLimit(*mu ) << endl;
412 cout <<
"upper limit on master signal = " << lrint->
UpperLimit(*mu ) << endl;
virtual void Print(Option_t *options=0) const
Print TNamed name and title.
RooAbsArg * first() const
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Bool_t setRealValue(const char *name, Double_t newVal=0, Bool_t verbose=kFALSE)
Set value of a RooAbsRealLValye stored in set with given name to newVal No error messages are printed...
virtual void addClone(const RooAbsCollection &col, Bool_t silent=kFALSE)
Add a collection of arguments to this collection by calling addOwned() for each element in the source...
RooRealVar represents a fundamental (non-derived) real valued object.
HypoTestResult is a base class for results from hypothesis tests.
virtual Double_t Significance() const
familiar name for the Null p-value in terms of 1-sided Gaussian significance
virtual Double_t NullPValue() const
Return p-value for null hypothesis.
This class provides simple and straightforward utilities to plot a LikelihoodInterval object.
LikelihoodInterval is a concrete implementation of the RooStats::ConfInterval interface.
Double_t LowerLimit(const RooRealVar ¶m)
return the lower bound of the interval on a given parameter
virtual void SetConfidenceLevel(Double_t cl)
set the confidence level for the interval (e.g 0.682 for a 1-sigma interval)
Double_t UpperLimit(const RooRealVar ¶m)
return the upper bound of the interval on a given parameter
virtual Bool_t IsInInterval(const RooArgSet &) const
check if given point is in the interval
A factory for building PDFs and data for a number counting combination.
ProfileLikelihoodCalculator is a concrete implementation of CombinedCalculator (the interface class f...
The RooWorkspace is a persistable container for RooFit projects.
RooAbsData * data(const char *name) const
Retrieve dataset (binned or unbinned) with given name. A null pointer is returned if not found.
RooRealVar * var(const char *name) const
Retrieve real-valued variable (RooRealVar) with given name. A null pointer is returned if not found.
RooAbsPdf * pdf(const char *name) const
Retrieve p.d.f (RooAbsPdf) with given name. A null pointer is returned if not found.
@(#)root/roostats:$Id$ Author: George Lewis, Kyle Cranmer
static constexpr double s