38using std::endl, std::vector, std::string;
50 bool ignoreNonVisible) :
52 _catList(
"catList",
"list of cats", this),
60 coutE(InputArguments) <<
"RooMultiBinomial::ctor(" << GetName() <<
") ERROR: Wrong input, should have equal number of categories and efficiencies." << endl;
61 throw string(
"RooMultiBinomial::ctor() ERROR: Wrong input, should have equal number of categories and efficiencies") ;
87 vector<double> effFuncVal(effFuncListSize);
88 for (
int i=0;
i<effFuncListSize; ++
i) {
94 for (
int i=0;
i<effFuncListSize; ++
i) {
95 if (effFuncVal[
i]>1) {
96 coutW(Eval) <<
"WARNING: Efficiency >1 (equal to " << effFuncVal[
i]
97 <<
" ), for i = " <<
i <<
"...TRUNCATED" << endl;
99 }
else if (effFuncVal[
i]<0) {
100 effFuncVal[
i] = 0.0 ;
101 coutW(Eval) <<
"WARNING: Efficiency <0 (equal to " << effFuncVal[
i]
102 <<
" ), for i = " <<
i <<
"...TRUNCATED" << endl;
106 vector<double> effValue(effFuncListSize);
107 bool notVisible =
true;
111 for (
int i=0;
i<effFuncListSize; ++
i) {
114 effValue[
i] = effFuncVal[
i] ;
118 effValue[
i] = 1 - effFuncVal[
i] ;
120 coutW(Eval) <<
"WARNING: WRONG CATEGORY NAMES GIVEN!, label = " << (
static_cast<RooAbsCategory&
>(
_catList[
i])).getCurrentIndex() << endl;
130 for (
int i=0;
i<effFuncListSize; ++
i) {
131 _effVal=_effVal*effValue[
i];
A space to attach TBranches.
Storage_t::size_type size() const
double getVal(const RooArgSet *normalisationSet=nullptr) const
Evaluate object.
RooAbsReal()
coverity[UNINIT_CTOR] Default constructor
RooArgList is a container object that can hold multiple RooAbsArg objects.
RooMultiBinomial is an efficiency function which makes all combinations of efficiencies given as inpu...
RooListProxy _effFuncList
double evaluate() const override
Calculate the raw value of the function which is the effFunc value if cat==1 and it is (1-effFunc) if...