16 #ifndef ROO_HIST_ERROR 17 #define ROO_HIST_ERROR 60 Double_t mu(xvec[0]),result(1),factorial(1);
63 result+=
pow(mu,k)/factorial;
65 return exp(-mu)*result;
88 for(
Int_t k= 0; k <= _n1; k++) {
89 if(k > 0) { fact2*= k; fact1*= _N1-k+1; }
119 for(
Int_t k= 0; k <= _n1; k++) {
120 if(k > 0) { fact2*= k; fact1*= _N1-k+1; }
Double_t _poissonHiLUT[1000]
Double_t getMinLimit(UInt_t) const
BinomialSumEff(Int_t n, Int_t m)
static RooAbsFunc * createPoissonSum(Int_t n)
Create and return a PoissonSum function binding.
Double_t operator()(const Double_t xvec[]) const
Double_t seek(const RooAbsFunc &f, Double_t startAt, Double_t step, Double_t value) const
Scan f(x)-value until it changes sign.
#define ClassDef(name, id)
static double p2(double t, double a, double b, double c)
double pow(double, double)
Bool_t getInterval(const RooAbsFunc *Qu, const RooAbsFunc *Ql, Double_t pointEstimate, Double_t stepSize, Double_t &lo, Double_t &hi, Double_t nSigma) const
Calculate a confidence interval using the cumulative functions provided.
Double_t getMaxLimit(UInt_t) const
Double_t operator()(const Double_t xvec[]) const
Double_t getMaxLimit(UInt_t) const
static Double_t infinity()
Return internal infinity representation.
static const RooHistError & instance()
Return a reference to a singleton object that is created the first time this method is called...
static double p1(double t, double a, double b)
Double_t getMinLimit(UInt_t) const
RooHistError()
Construct our singleton object.
Double_t _poissonLoLUT[1000]
Double_t getMaxLimit(UInt_t) const
Bool_t getBinomialIntervalAsym(Int_t n, Int_t m, Double_t &a1, Double_t &a2, Double_t nSigma=1) const
Return 'nSigma' binomial confidence interval for (n,m).
Double_t operator()(const Double_t xvec[]) const
Bool_t getPoissonInterval(Int_t n, Double_t &mu1, Double_t &mu2, Double_t nSigma=1) const
Return a confidence interval for the expected number of events given n observed (unweighted) events...
static RooAbsFunc * createBinomialSum(Int_t n, Int_t m, Bool_t eff)
Create and return a BinomialSum function binding.
Bool_t getBinomialIntervalEff(Int_t n, Int_t m, Double_t &a1, Double_t &a2, Double_t nSigma=1) const
Return 'nSigma' binomial confidence interval for (n,m).
float type_of_call hi(const int &, const int &)
BinomialSumAsym(Int_t n, Int_t m)
Bool_t getPoissonIntervalCalc(Int_t n, Double_t &mu1, Double_t &mu2, Double_t nSigma=1) const
Calculate a confidence interval for the expected number of events given n observed (unweighted) event...
Abstract interface for evaluating a real-valued function of one real variable and performing numerica...
Double_t getMinLimit(UInt_t) const
RooHistError is a singleton class used to calculate the error bars for each bin of a RooHist object...