37 cout <<
"gx = " << gx.getVal() << endl;
41 cout <<
"gx_Norm[x] = " << gx.getVal(&nset) << endl;
45 std::unique_ptr<RooAbsReal> igx{gx.createIntegral(
x)};
46 cout <<
"gx_Int[x] = " << igx->getVal() << endl;
52 x.setRange(
"signal", -5, 5);
57 std::unique_ptr<RooAbsReal> igx_sig{gx.createIntegral(
x,
NormSet(
x),
Range(
"signal"))};
58 cout <<
"gx_Int[x|signal]_Norm[x] = " << igx_sig->getVal() << endl;
65 std::unique_ptr<RooAbsReal> gx_cdf{gx.createCdf(
x)};
69 gx_cdf->plotOn(frame);
72 new TCanvas(
"rf110_normintegration",
"rf110_normintegration", 600, 600);
73 gPad->SetLeftMargin(0.15);
RooArgSet is a container object that can hold multiple RooAbsArg objects.
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.
Variable that can be changed from the outside.
virtual void SetTitleOffset(Float_t offset=1)
Set distance between the axis and the axis title.
RooCmdArg NormSet(Args_t &&... argsOrArgSet)
The namespace RooFit contains mostly switches that change the behaviour of functions of PDFs (or othe...