47 _xf(
"!xf",
"xf",this,false,false),
48 _ixf(
"!ixf",
"ixf",this),
53 std::string pname=
Form(
"%s_product",
name) ;
55 std::unique_ptr<RooFormulaVar> XF;
57 std::string formula=
Form(
"pow((@0-@1),%d)*@2",
_order) ;
60 XF = std::make_unique<RooFormulaVar>(pname.c_str(),formula.c_str(),
RooArgList(
x,*mom1,func)) ;
65 std::string formula=
Form(
"pow(@0,%d)*@1",
_order) ;
66 XF = std::make_unique<RooFormulaVar>(pname.c_str(),formula.c_str(),
RooArgSet(
x,func)) ;
71 XF->specialIntegratorConfig(
true)->method1D().setLabel(
"RooBinIntegrator");
74 std::unique_ptr<RooAbsReal> intXF{XF->createIntegral(
x)};
90 Int_t orderIn,
bool centr,
bool takeRoot,
bool intNSet) :
92 _xf(
"!xf",
"xf",this,false,false),
93 _ixf(
"!ixf",
"ixf",this),
100 std::string pname=
Form(
"%s_product",
name) ;
101 std::unique_ptr<RooFormulaVar> XF;
103 std::string formula=
Form(
"pow((@0-@1),%d)*@2",
_order) ;
106 XF = std::make_unique<RooFormulaVar>(pname.c_str(),formula.c_str(),
RooArgList(
x,*mom1,func)) ;
109 _mean.setArg(*mom1) ;
111 std::string formula=
Form(
"pow(@0,%d)*@1",
_order) ;
112 XF = std::make_unique<RooFormulaVar>(pname.c_str(),formula.c_str(),
RooArgSet(
x,func)) ;
117 XF->specialIntegratorConfig(
true)->method1D().setLabel(
"RooBinIntegrator");
121 if (intNSet) intSet.
add(
_nset,
true) ;
123 std::unique_ptr<RooAbsReal> intXF{XF->createIntegral(intSet, &
_nset)};
129 _ixf.setArg(*intXF) ;
int Int_t
Signed integer 4 bytes (int).
char * Form(const char *fmt,...)
Formats a string in a circular formatting buffer.
RooExpensiveObjectCache & expensiveObjectCache() const
virtual void setExpensiveObjectCache(RooExpensiveObjectCache &cache)
bool addOwnedComponents(const RooAbsCollection &comps)
Take ownership of the contents of 'comps'.
friend class RooRealIntegral
virtual bool add(const RooAbsArg &var, bool silent=false)
Add the specified argument to list.
RooRealProxy _mean
Mean (if calculated for central moment).
Int_t _order
Moment order.
Int_t _takeRoot
Return n-order root of moment.
RooSetProxy _nset
Normalization set (optional).
RooAbsMoment * mean(RooRealVar &obs)
RooAbsReal()
coverity[UNINIT_CTOR] Default constructor
virtual bool isBinnedDistribution(const RooArgSet &) const
Tests if the distribution is binned. Unless overridden by derived classes, this always returns false.
RooFit::OwningPtr< RooAbsReal > createIntegral(const RooArgSet &iset, const RooCmdArg &arg1, const RooCmdArg &arg2={}, const RooCmdArg &arg3={}, const RooCmdArg &arg4={}, const RooCmdArg &arg5={}, const RooCmdArg &arg6={}, const RooCmdArg &arg7={}, const RooCmdArg &arg8={}) const
Create an object that represents the integral of the function over one or more observables listed in ...
RooArgList is a container object that can hold multiple RooAbsArg objects.
RooArgSet is a container object that can hold multiple RooAbsArg objects.
double evaluate() const override
Calculate value.
RooRealProxy _if
Int(F(x))dx ;.
RooRealProxy _ixf
Int(X*F(X))dx ;.
Variable that can be changed from the outside.
const char * GetName() const override
Returns name of object.