ROOT
git-r3/HEAD
Reference Guide
Loading...
Searching...
No Matches
RooExtendedBinding.cxx
Go to the documentation of this file.
1
/*
2
* Project: RooFit
3
*
4
* Copyright (c) 2023, CERN
5
*
6
* Redistribution and use in source and binary forms,
7
* with or without modification, are permitted according to the terms
8
* listed in LICENSE (http://roofit.sourceforge.net/license.txt)
9
*/
10
11
#include <
RooExtendedBinding.h
>
12
13
14
RooExtendedBinding::RooExtendedBinding
(
const
char
*
name
,
const
char
*title,
RooAbsPdf
&_pdf)
15
:
RooAbsReal
(
name
, title),
pdf
(
"pdf"
,
"pdf"
, this, _pdf)
16
{
17
}
18
19
RooExtendedBinding::RooExtendedBinding
(
const
char
*
name
,
const
char
*title,
RooAbsPdf
&_pdf,
const
RooArgSet
&obs)
20
:
RooExtendedBinding
{
name
, title, _pdf}
21
{
22
_obsList
= std::make_unique<RooSetProxy>(
"obsList"
,
"List of observables"
,
this
,
false
,
false
);
23
_obsList
->add(obs);
24
}
25
26
RooExtendedBinding::RooExtendedBinding
(
const
RooExtendedBinding
&other,
const
char
*
name
)
27
:
RooAbsReal
(other,
name
),
pdf
(
"pdf"
, this, other.
pdf
)
28
{
29
if
(other.
_obsList
) {
30
_obsList = std::make_unique<RooSetProxy>(
"obsList"
, this, *other._obsList);
31
}
32
}
33
34
double
RooExtendedBinding::evaluate
()
const
35
{
36
RooArgSet
const
*normSet =
_obsList
?
_obsList
.get() :
nullptr
;
37
return
(
const_cast<
RooAbsPdf
&
>
(
static_cast<
RooAbsPdf
const
&
>
(
pdf
.arg()))).expectedEvents(normSet);
38
}
RooExtendedBinding.h
name
char name[80]
Definition
TGX11.cxx:148
RooAbsPdf
Abstract interface for all probability density functions.
Definition
RooAbsPdf.h:32
RooAbsReal::RooAbsReal
RooAbsReal()
coverity[UNINIT_CTOR] Default constructor
Definition
RooAbsReal.cxx:196
RooArgSet
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Definition
RooArgSet.h:24
RooExtendedBinding::pdf
RooRealProxy pdf
Definition
RooExtendedBinding.h:30
RooExtendedBinding::RooExtendedBinding
RooExtendedBinding()
Definition
RooExtendedBinding.h:21
RooExtendedBinding::_obsList
std::unique_ptr< RooSetProxy > _obsList
Definition
RooExtendedBinding.h:31
RooExtendedBinding::evaluate
double evaluate() const override
Evaluate this PDF / function / constant. Needs to be overridden by all derived classes.
Definition
RooExtendedBinding.cxx:34
roofit
roofitcore
src
RooExtendedBinding.cxx
ROOTgit-r3/HEAD - Reference Guide Generated on
(GVA Time) using Doxygen 1.16.1