67void rf204b_extendedLikelihood_rangedFit()
75 RooRealVar alpha(
"alpha",
"alpha", -0.04, -0.1, -0.0);
79 x.setRange(
"LEFT",10,20);
80 x.setRange(
"RIGHT",60,100);
82 x.setRange(
"FULL",10,100);
101 RooExtendPdf extmodel(
"extmodel",
"Extended model", model,
N,
"FULL");
137 model.paramOn(frame,
Label(
"Bkg fit. Large errors since\nnormalisation ignored"));
145 extmodel.plotOn(frame2);
147 extmodel.paramOn(frame2,
Label(
"Bkg fit. Normalisation\nincluded"),
Layout(0.4,0.95));
161 RooRealVar Nsig(
"Nsig",
"Number of signal events", 1000, 0, 2000);
162 RooRealVar Nbkg(
"Nbkg",
"Number of background events", 10000, 0, 20000);
164 RooRealVar mean(
"mean",
"Mean of signal model", 40.);
182 modelsum.plotOn(frame3);
184 modelsum.paramOn(frame3,
Label(
"S+B fit with RooAddPdf"),
Layout(0.3,0.95));
include TDocParser_001 C image html pict1_TDocParser_001 png width
virtual RooPlot * plotOn(RooPlot *frame, const RooCmdArg &arg1=RooCmdArg::none(), const RooCmdArg &arg2=RooCmdArg::none(), const RooCmdArg &arg3=RooCmdArg::none(), const RooCmdArg &arg4=RooCmdArg::none(), const RooCmdArg &arg5=RooCmdArg::none(), const RooCmdArg &arg6=RooCmdArg::none(), const RooCmdArg &arg7=RooCmdArg::none(), const RooCmdArg &arg8=RooCmdArg::none()) const
RooAddPdf is an efficient implementation of a sum of PDFs of the form.
RooArgSet is a container object that can hold multiple RooAbsArg objects.
RooDataSet is a container class to hold unbinned data.
RooExtendPdf is a wrapper around an existing PDF that adds a parameteric extended likelihood term to ...
RooFitResult is a container class to hold the input and output of a PDF fit to a dataset.
A RooPlot is a plot frame and a container for graphics objects within that frame.
static RooPlot * frame(const RooAbsRealLValue &var, Double_t xmin, Double_t xmax, Int_t nBins)
Create a new frame for a given variable in x.
virtual void Draw(Option_t *options=0)
Draw this plot and all of the elements it contains.
RooRealVar represents a variable that can be changed from the outside.
RooCmdArg Layout(Double_t xmin, Double_t xmax=0.99, Double_t ymin=0.95)
RooCmdArg Save(Bool_t flag=kTRUE)
RooCmdArg PrintLevel(Int_t code)
RooCmdArg VisualizeError(const RooDataSet ¶mData, Double_t Z=1)
const Rcpp::internal::NamedPlaceHolder & Label
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...