25void rs701_BayesianCalculator(
bool useBkg =
true,
double confLevel = 0.90)
29 w->
factory(
"SUM::pdf(s[0.001,15]*Uniform(x[0,1]),b[1,0,2]*Uniform(x))");
30 w->
factory(
"Gaussian::prior_b(b,1,1)");
31 w->
factory(
"PROD::model(pdf,prior_b)");
49 nuisPar = &nuisanceParameters;
52 double size = 1. - confLevel;
53 std::cout <<
"\nBayesian Result using a Flat prior " << std::endl;
55 bcalc.SetTestSize(size);
58 std::cout << cl <<
"% CL central interval: [ " << interval->
LowerLimit() <<
" - " << interval->
UpperLimit()
59 <<
" ] or " << cl + (1. - cl) / 2 <<
"% CL limits\n";
60 RooPlot *plot = bcalc.GetPosteriorPlot();
67 std::cout <<
"\nBayesian Result using a 1/sqrt(s) prior " << std::endl;
69 bcalc2.SetTestSize(size);
72 std::cout << cl <<
"% CL central interval: [ " << interval2->
LowerLimit() <<
" - " << interval2->
UpperLimit()
73 <<
" ] or " << cl + (1. - cl) / 2 <<
"% CL limits\n";
75 RooPlot *plot2 = bcalc2.GetPosteriorPlot();
RooAbsRealLValue is the common abstract base class for objects that represent a real value that may a...
Double_t 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.
static RooMsgService & instance()
Return reference to singleton instance.
void setGlobalKillBelow(RooFit::MsgLevel level)
A RooPlot is a plot frame and a container for graphics objects within that frame.
virtual void Draw(Option_t *options=0)
Draw this plot and all of the elements it contains.
BayesianCalculator is a concrete implementation of IntervalCalculator, providing the computation of a...
SimpleInterval is a concrete implementation of the ConfInterval interface.
virtual Double_t ConfidenceLevel() const
return confidence level
virtual Double_t UpperLimit()
virtual Double_t LowerLimit()
The RooWorkspace is a persistable container for RooFit projects.
RooRealVar * var(const char *name) const
Retrieve real-valued variable (RooRealVar) with given name. A null pointer is returned if not found.
RooFactoryWSTool & factory()
Return instance to factory tool.
RooAbsPdf * pdf(const char *name) const
Retrieve p.d.f (RooAbsPdf) with given name. A null pointer is returned if not found.
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...
Namespace for the RooStats classes.