41 std::unique_ptr<RooDataSet>
data{p0.generate(
x, 1000)};
50 data->addColumn(wFunc);
77 std::unique_ptr<RooFitResult> r_ml_wgt{p2.fitTo(wdata,
Save(),
PrintLevel(-1))};
113 std::unique_ptr<RooDataSet> data2{genPdf.generate(
x, 1000)};
116 std::unique_ptr<RooDataSet> data3{genPdf.generate(
x, 43000)};
119 std::unique_ptr<RooFitResult> r_ml_unw10{p2.fitTo(*data2,
Save(),
PrintLevel(-1))};
120 std::unique_ptr<RooFitResult> r_ml_unw43{p2.fitTo(*data3,
Save(),
PrintLevel(-1))};
126 std::unique_ptr<RooAbsData> binnedData{wdata.binnedClone()};
127 binnedData->Print(
"v");
134 std::unique_ptr<RooAbsReal> chi2{
141 std::unique_ptr<RooFitResult> r_chi2_wgt{
m.save()};
151 cout <<
"==> ML Fit results on 1K unweighted events" << endl;
153 cout <<
"==> ML Fit results on 43K unweighted events" << endl;
155 cout <<
"==> ML Fit results on 1K weighted events with a summed weight of 43K" << endl;
157 cout <<
"==> Corrected ML Fit results on 1K weighted events with a summed weight of 43K" << endl;
158 r_ml_wgt_corr->Print();
159 cout <<
"==> Chi2 Fit results on 1K weighted events with a summed weight of 43K" << endl;
162 new TCanvas(
"rf403_weightedevts",
"rf403_weightedevts", 600, 600);
163 gPad->SetLeftMargin(0.15);
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
RooArgList is a container object that can hold multiple RooAbsArg objects.
Container class to hold N-dimensional binned data.
Container class to hold unbinned data.
Implementation of a probability density function that takes a RooArgList of servers and a C++ express...
Wrapper class around ROOT::Math::Minimizer that provides a seamless interface between the minimizer f...
Plot frame and a container for graphics objects within that frame.
static RooPlot * frame(const RooAbsRealLValue &var, double xmin, double xmax, Int_t nBins)
Create a new frame for a given variable in x.
void Draw(Option_t *options=nullptr) override
Draw this plot and all of the elements it contains.
RooPolynomial implements a polynomial p.d.f of the form.
Variable that can be changed from the outside.
virtual void SetTitleOffset(Float_t offset=1)
Set distance between the axis and the axis title.
void Print(Option_t *option="") const override
Dump this marker with its attributes.
RooCmdArg WeightVar(const char *name="weight", bool reinterpretAsWeight=false)
RooCmdArg Import(const char *state, TH1 &histo)
RooCmdArg Save(bool flag=true)
RooCmdArg SumW2Error(bool flag)
RooCmdArg PrintLevel(Int_t code)
RooCmdArg DataError(Int_t)
RooCmdArg LineColor(Color_t color)
RooCmdArg LineStyle(Style_t style)
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...