CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
root::RooFitFunction< X, Expr > Class Template Reference

#include <RooFitFunction.h>

Inheritance diagram for root::RooFitFunction< X, Expr >:

Public Member Functions

void add (RooAbsReal &rA, funct::Parameter &a)
 
TObject * clone (const char *newName) const override
 
 RooFitFunction (const char *name, const char *title, const Expr &e, RooAbsReal &x)
 
 RooFitFunction (const char *name, const char *title, const Expr &e, RooAbsReal &x, RooAbsReal &rA, funct::Parameter &a)
 
 RooFitFunction (const char *name, const char *title, const Expr &e, RooAbsReal &x, RooAbsReal &rA, funct::Parameter &a, RooAbsReal &rB, funct::Parameter &b)
 
 RooFitFunction (const char *name, const char *title, const Expr &e, RooAbsReal &x, RooAbsReal &rA, funct::Parameter &a, RooAbsReal &rB, funct::Parameter &b, RooAbsReal &rC, funct::Parameter &c)
 
 RooFitFunction (const RooFitFunction< X, Expr > &other, const char *name=nullptr)
 
 ~RooFitFunction () override
 

Private Member Functions

Double_t evaluate () const override
 

Private Attributes

Expr e_
 
std::vector< std::pair< std::shared_ptr< double >, RooRealProxy > > pars_
 
RooRealProxy x_
 

Detailed Description

template<typename X, typename Expr>
class root::RooFitFunction< X, Expr >

Definition at line 14 of file RooFitFunction.h.

Constructor & Destructor Documentation

◆ RooFitFunction() [1/5]

template<typename X, typename Expr>
root::RooFitFunction< X, Expr >::RooFitFunction ( const RooFitFunction< X, Expr > &  other,
const char *  name = nullptr 
)
inline

Definition at line 16 of file RooFitFunction.h.

17  : RooAbsReal(other, name), e_(other.e_), x_(X::name(), this, other.x_) {
18  std::cout << ">>> making new RooFitFunction" << std::endl;
19  std::vector<std::pair<std::shared_ptr<double>, RooRealProxy> >::const_iterator i = other.pars_.begin(),
20  end = other.pars_.end();
21  for (; i != end; ++i) {
22  std::cout << ">>> adding par to RooFitFunction" << std::endl;
23  pars_.push_back(std::make_pair(i->first, RooRealProxy(i->second.GetName(), this, i->second)));
24  }
25  }

References gather_cfg::cout, end, mps_fire::i, trackingPlots::other, and root::RooFitFunction< X, Expr >::pars_.

◆ RooFitFunction() [2/5]

template<typename X, typename Expr>
root::RooFitFunction< X, Expr >::RooFitFunction ( const char *  name,
const char *  title,
const Expr &  e,
RooAbsReal &  x 
)
inline

Definition at line 26 of file RooFitFunction.h.

27  : RooAbsReal(name, title), e_(e), x_(X::name(), X::name(), this, x) {}

◆ RooFitFunction() [3/5]

template<typename X, typename Expr>
root::RooFitFunction< X, Expr >::RooFitFunction ( const char *  name,
const char *  title,
const Expr &  e,
RooAbsReal &  x,
RooAbsReal &  rA,
funct::Parameter a 
)
inline

Definition at line 28 of file RooFitFunction.h.

30  : RooAbsReal(name, title), e_(e), x_(X::name(), X::name(), this, x) {
31  pars_.push_back(std::make_pair(a.ptr(), RooRealProxy(a.name().c_str(), a.name().c_str(), this, rA)));
32  }

References a, and root::RooFitFunction< X, Expr >::pars_.

◆ RooFitFunction() [4/5]

template<typename X, typename Expr>
root::RooFitFunction< X, Expr >::RooFitFunction ( const char *  name,
const char *  title,
const Expr &  e,
RooAbsReal &  x,
RooAbsReal &  rA,
funct::Parameter a,
RooAbsReal &  rB,
funct::Parameter b 
)
inline

Definition at line 33 of file RooFitFunction.h.

41  : RooAbsReal(name, title), e_(e), x_(X::name(), X::name(), this, x) {
42  pars_.push_back(std::make_pair(a.ptr(), RooRealProxy(a.name().c_str(), a.name().c_str(), this, rA)));
43  pars_.push_back(std::make_pair(b.ptr(), RooRealProxy(b.name().c_str(), b.name().c_str(), this, rB)));
44  }

References a, b, and root::RooFitFunction< X, Expr >::pars_.

◆ RooFitFunction() [5/5]

template<typename X, typename Expr>
root::RooFitFunction< X, Expr >::RooFitFunction ( const char *  name,
const char *  title,
const Expr &  e,
RooAbsReal &  x,
RooAbsReal &  rA,
funct::Parameter a,
RooAbsReal &  rB,
funct::Parameter b,
RooAbsReal &  rC,
funct::Parameter c 
)
inline

Definition at line 45 of file RooFitFunction.h.

55  : RooAbsReal(name, title), e_(e), x_(X::name(), X::name(), this, x) {
56  pars_.push_back(std::make_pair(a.ptr(), RooRealProxy(a.name().c_str(), a.name().c_str(), this, rA)));
57  pars_.push_back(std::make_pair(b.ptr(), RooRealProxy(b.name().c_str(), b.name().c_str(), this, rB)));
58  pars_.push_back(std::make_pair(c.ptr(), RooRealProxy(c.name().c_str(), c.name().c_str(), this, rC)));
59  }

References a, b, HltBtagPostValidation_cff::c, and root::RooFitFunction< X, Expr >::pars_.

◆ ~RooFitFunction()

template<typename X, typename Expr>
root::RooFitFunction< X, Expr >::~RooFitFunction ( )
inlineoverride

Definition at line 60 of file RooFitFunction.h.

60 {}

Member Function Documentation

◆ add()

template<typename X, typename Expr>
void root::RooFitFunction< X, Expr >::add ( RooAbsReal &  rA,
funct::Parameter a 
)
inline

Definition at line 61 of file RooFitFunction.h.

61  {
62  pars_.push_back(std::make_pair(a.ptr(), RooRealProxy(a.name().c_str(), a.name().c_str(), this, rA)));
63  }

References a, and root::RooFitFunction< X, Expr >::pars_.

Referenced by counter.Counter::register().

◆ clone()

template<typename X, typename Expr>
TObject* root::RooFitFunction< X, Expr >::clone ( const char *  newName) const
inlineoverride

Definition at line 64 of file RooFitFunction.h.

64 { return new RooFitFunction<X, Expr>(*this, newName); }

References mps_merge::newName.

◆ evaluate()

template<typename X, typename Expr>
Double_t root::RooFitFunction< X, Expr >::evaluate ( ) const
inlineoverrideprivate

Definition at line 70 of file RooFitFunction.h.

70  {
71  X::set(x_);
72  std::vector<std::pair<std::shared_ptr<double>, RooRealProxy> >::const_iterator i = pars_.begin(),
73  end = pars_.end();
74  for (; i != end; ++i)
75  *(i->first) = i->second;
76  return e_();
77  }

References root::RooFitFunction< X, Expr >::e_, end, mps_fire::i, root::RooFitFunction< X, Expr >::pars_, and root::RooFitFunction< X, Expr >::x_.

Member Data Documentation

◆ e_

template<typename X, typename Expr>
Expr root::RooFitFunction< X, Expr >::e_
private

Definition at line 67 of file RooFitFunction.h.

Referenced by root::RooFitFunction< X, Expr >::evaluate().

◆ pars_

template<typename X, typename Expr>
std::vector<std::pair<std::shared_ptr<double>, RooRealProxy> > root::RooFitFunction< X, Expr >::pars_
private

◆ x_

template<typename X, typename Expr>
RooRealProxy root::RooFitFunction< X, Expr >::x_
private

Definition at line 68 of file RooFitFunction.h.

Referenced by root::RooFitFunction< X, Expr >::evaluate().

mps_fire.i
i
Definition: mps_fire.py:355
gather_cfg.cout
cout
Definition: gather_cfg.py:144
end
#define end
Definition: vmac.h:39
trackingPlots.other
other
Definition: trackingPlots.py:1465
b
double b
Definition: hdecay.h:118
a
double a
Definition: hdecay.h:119
HltBtagPostValidation_cff.c
c
Definition: HltBtagPostValidation_cff.py:31
mps_merge.newName
string newName
Definition: mps_merge.py:86
overlapproblemtsosanalyzer_cfi.title
title
Definition: overlapproblemtsosanalyzer_cfi.py:7
root::RooFitFunction::e_
Expr e_
Definition: RooFitFunction.h:67
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
root::RooFitFunction::pars_
std::vector< std::pair< std::shared_ptr< double >, RooRealProxy > > pars_
Definition: RooFitFunction.h:69
root::RooFitFunction::x_
RooRealProxy x_
Definition: RooFitFunction.h:68
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37