Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
PointSetInterval.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_PointSetInterval
12 #define RooStats_PointSetInterval
13 
14 #include "RooArgSet.h"
15 #include "RooAbsData.h"
16 #include "RooStats/ConfInterval.h"
17 
18 
19 namespace RooStats {
20 
21  class PointSetInterval : public ConfInterval {
22 
23  public:
24 
25  /// default constructors
26  explicit PointSetInterval(const char* name = 0);
27 
28  /// constructor from name and data set specifying the interval points
29  PointSetInterval(const char* name, RooAbsData&);
30 
31  /// destructor
32  virtual ~PointSetInterval();
33 
34 
35  /// check if parameter is in the interval
36  virtual Bool_t IsInInterval(const RooArgSet&) const;
37 
38  /// set the confidence level for the interval
39  virtual void SetConfidenceLevel(Double_t cl) {fConfidenceLevel = cl;}
40 
41  /// return the confidence level for the interval
42  virtual Double_t ConfidenceLevel() const {return fConfidenceLevel;}
43 
44  /// Method to return lower limit on a given parameter
45  /// Double_t LowerLimit(RooRealVar& param) ; // could provide, but misleading?
46  /// Double_t UpperLimit(RooRealVar& param) ; // could provide, but misleading?
47 
48  /// return a cloned list with the parameter of interest
49  virtual RooArgSet* GetParameters() const;
50 
51  /// return a copy of the data set (points) defining this interval
52  RooAbsData* GetParameterPoints() const {return (RooAbsData*)fParameterPointsInInterval->Clone();}
53 
54  /// return a cloned list with the parameter of interest
55  Bool_t CheckParameters(const RooArgSet&) const ;
56 
57  /// return lower limit on a given parameter
58  Double_t LowerLimit(RooRealVar& param) ;
59 
60  /// return upper limit on a given parameter
61  Double_t UpperLimit(RooRealVar& param) ;
62 
63 
64  protected:
65 
66  ClassDef(PointSetInterval,1) /// Concrete implementation of ConfInterval for simple 1-D intervals in the form [a,b]
67 
68  private:
69 
70  // RooArgSet* fParameters; // parameter of interest
71  Double_t fConfidenceLevel; /// confidence level
72  RooAbsData* fParameterPointsInInterval; /// either a histogram (RooDataHist) or a tree (RooDataSet)
73 
74 
75  };
76 }
77 
78 #endif