14 #ifndef ROOSTATS_HypoTestResult
15 #define ROOSTATS_HypoTestResult
21 #ifndef ROOSTATS_RooStatsUtils
25 #ifndef ROOSTATS_SamplingDistribution
106 double thisCLb =
CLb();
108 std::cout <<
"Error: Cannot compute CLs because CLb = 0. Returning CLs = -1\n";
112 return thisCLsb / thisCLb;
void SetBackgroundAsAlt(Bool_t l=kTRUE)
void SetAltDistribution(SamplingDistribution *alt)
Double_t CLbError() const
The error on the "confidence level" of the null hypothesis.
Double_t fNullPValueError
void SetFitInfo(RooDataSet *d)
RooDataSet * GetFitInfo(void) const
const RooArgList * fAllTestStatisticsData
virtual Double_t CLs() const
CLs is simply CLs+b/CLb (not a method, but a quantity)
Double_t PValueToSignificance(Double_t pvalue)
HypoTestResult is a base class for results from hypothesis tests.
HypoTestResult & operator=(const HypoTestResult &other)
assignment operator
RooDataSet * GetNullDetailedOutput(void) const
RooDataSet * fNullDetailedOutput
Double_t SignificanceError() const
The error on the significance, computed from NullPValueError via error propagation.
void UpdatePValue(const SamplingDistribution *distr, Double_t &pvalue, Double_t &perror, Bool_t pIsRightTail)
updates the pvalue if sufficient data is available
SamplingDistribution * GetAltDistribution(void) const
virtual Double_t CLsplusb() const
Convert AlternatePValue into a "confidence level".
double distr(double *x, double *p)
#define ClassDef(name, id)
RooDataSet * GetAltDetailedOutput(void) const
The TNamed class is the base class for all named ROOT classes.
void Print(const Option_t *="") const
const RooArgList * GetAllTestStatisticsData(void) const
Double_t fTestStatisticData
virtual Double_t NullPValue() const
Return p-value for null hypothesis.
void SetAllTestStatisticsData(const RooArgList *tsd)
Double_t fAlternatePValue
virtual Double_t CLb() const
Convert NullPValue into a "confidence level".
virtual ~HypoTestResult()
destructor
Double_t NullPValueError() const
The error on the Null p-value.
SamplingDistribution * fAltDistr
Double_t fAlternatePValueError
void SetAltDetailedOutput(RooDataSet *d)
Bool_t fPValueIsRightTail
virtual Double_t Significance() const
familiar name for the Null p-value in terms of 1-sided Gaussian significance
Bool_t HasTestStatisticData(void) const
Bool_t GetPValueIsRightTail(void) const
RooDataSet is a container class to hold unbinned data.
void SetTestStatisticData(const Double_t tsd)
This class simply holds a sampling distribution of some test statistic.
HypoTestResult(const char *name=0)
default constructor
virtual void Append(const HypoTestResult *other)
add values from another HypoTestResult
void SetPValueIsRightTail(Bool_t pr)
SamplingDistribution * fNullDistr
SamplingDistribution * GetNullDistribution(void) const
virtual Double_t AlternatePValue() const
Return p-value for alternate hypothesis.
void SetNullDetailedOutput(RooDataSet *d)
RooDataSet * fAltDetailedOutput
Double_t CLsplusbError() const
The error on the "confidence level" of the alternative hypothesis.
Double_t GetTestStatisticData(void) const
void SetNullDistribution(SamplingDistribution *null)
Double_t CLsError() const
The error on the ratio CLs+b/CLb.
Bool_t GetBackGroundIsAlt(void) const