Logo ROOT   6.10/00
Reference Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
HypoTestInverterOriginal.h
Go to the documentation of this file.
1 // @(#)root/roostats:$Id$
2 // Author: Kyle Cranmer, Lorenzo Moneta, Gregory Schott, Wouter Verkerke
3 /*************************************************************************
4  * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. *
5  * All rights reserved. *
6  * *
7  * For the licensing terms see $ROOTSYS/LICENSE. *
8  * For the list of contributors see $ROOTSYS/README/CREDITS. *
9  *************************************************************************/
10 
11 #ifndef ROOSTATS_HypoTestInverterOriginal
12 #define ROOSTATS_HypoTestInverterOriginal
13 
14 
15 
17 
19 
21 
22 class RooRealVar;
23 
24 
25 namespace RooStats {
26 
28 
29  public:
30 
31  // default constructor (used only for I/O)
33 
34 
35  // constructor
37  RooRealVar& scannedVariable,
38  double size = 0.05) ;
39 
40 
41 
42  virtual HypoTestInverterResult* GetInterval() const { return fResults; } ;
43 
44  bool RunAutoScan( double xMin, double xMax, double target, double epsilon=0.005, unsigned int numAlgorithm=0 );
45 
46  bool RunFixedScan( int nBins, double xMin, double xMax );
47 
48  bool RunOnePoint( double thisX );
49 
50  void UseCLs( bool on = true) { fUseCLs = on; if (fResults) fResults->UseCLs(on); }
51 
52  virtual void SetData(RooAbsData &) { } // not needed
53 
54  virtual void SetModel(const ModelConfig &) { } // not needed
55 
56  // set the size of the test (rate of Type I error) ( Eg. 0.05 for a 95% Confidence Interval)
57  virtual void SetTestSize(Double_t size) {fSize = size; if (fResults) fResults->SetTestSize(size); }
58  // set the confidence level for the interval (eg. 0.95 for a 95% Confidence Interval)
59  virtual void SetConfidenceLevel(Double_t cl) {fSize = 1.-cl; if (fResults) fResults->SetConfidenceLevel(cl); }
60  // Get the size of the test (eg. rate of Type I error)
61  virtual Double_t Size() const {return fSize;}
62  // Get the Confidence level for the test
63  virtual Double_t ConfidenceLevel() const {return 1.-fSize;}
64 
65  // destructor
66  virtual ~HypoTestInverterOriginal() ;
67 
68  private:
69 
70  void CreateResults();
71 
72  HypoTestCalculator* fCalculator0; // pointer to the calculator passed in the constructor
73  RooRealVar* fScannedVariable; // pointer to the constrained variable
75 
76  bool fUseCLs;
77  double fSize;
78 
79  protected:
80 
81  ClassDef(HypoTestInverterOriginal,1) // HypoTestInverterOriginal class
82 
83  };
84 }
85 
86 #endif
virtual void SetModel(const ModelConfig &)
Set the Model.
virtual HypoTestInverterResult * GetInterval() const
Main interface to get a ConfInterval, pure virtual.
ModelConfig is a simple class that holds configuration information specifying how a model should be u...
Definition: ModelConfig.h:30
IntervalCalculator is an interface class for a tools which produce RooStats ConfIntervals.
bool RunAutoScan(double xMin, double xMax, double target, double epsilon=0.005, unsigned int numAlgorithm=0)
virtual void SetTestSize(Double_t size)
set the size of the test (rate of Type I error) (eg. 0.05 for a 95% Confidence Interval) ...
virtual void SetData(RooAbsData &)
Set the DataSet ( add to the the workspace if not already there ?)
#define ClassDef(name, id)
Definition: Rtypes.h:297
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
void UseCLs(bool on=true)
flag to switch between using CLsb (default) or CLs as confidence level
virtual void SetTestSize(Double_t size)
set the size of the test (rate of Type I error) ( e.g. 0.05 for a 95% Confidence Interval) ...
HypoTestCalculator is an interface class for a tools which produce RooStats HypoTestResults.
RooRealVar represents a fundamental (non-derived) real valued object.
Definition: RooRealVar.h:36
virtual Double_t Size() const
Get the size of the test (eg. rate of Type I error)
virtual void SetConfidenceLevel(Double_t cl)
set the confidence level for the interval (e.g. 0.95 for a 95% Confidence Interval) ...
RooAbsData is the common abstract base class for binned and unbinned datasets.
Definition: RooAbsData.h:37
bool RunOnePoint(double thisX)
run only one point
REAL epsilon
Definition: triangle.c:617
virtual Double_t ConfidenceLevel() const
Get the Confidence level for the test.
This class is now deprecated and to be replaced by the HypoTestInverter.
HypoTestInverterResult class holds the array of hypothesis test results and compute a confidence inte...
double Double_t
Definition: RtypesCore.h:55
bool RunFixedScan(int nBins, double xMin, double xMax)
virtual void SetConfidenceLevel(Double_t cl)
set the confidence level for the interval (eg. 0.95 for a 95% Confidence Interval) ...