Logo ROOT   6.30.04
Reference Guide
 All Namespaces Files Pages
HypoTestInverterPlot.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_HypoTestInverterPlot
12 #define ROOSTATS_HypoTestInverterPlot
13 
14 #include "TNamed.h"
15 
16 class TGraphErrors;
17 class TMultiGraph;
18 
19 
20 namespace RooStats {
21 
22  class HypoTestInverterResult;
23  class SamplingDistPlot;
24 
25 
26  class HypoTestInverterPlot : public TNamed {
27 
28  public:
29 
30  // constructor
31  HypoTestInverterPlot(HypoTestInverterResult* results ) ;
32 
33  HypoTestInverterPlot( const char* name,
34  const char* title,
35  HypoTestInverterResult* results ) ;
36 
37  /// return a TGraphErrors with the obtained observed p-values
38  /// resultinf from the scan
39  /// By default (Option = "") return CLs or CLsb depending if the flag UseCLs is set
40  /// If Option = "CLb" return CLb plot
41  /// = "CLs+b" return CLs+b plot independently of the flag
42  /// = "CLs" return CLs plot independently of the flag
43  TGraphErrors* MakePlot(Option_t *opt="") ;
44 
45  /// Make the expected plot and the bands
46  /// nsig1 and nsig2 indicates the n-sigma value for the bands
47  /// if nsig1 = 0 no band is computed (only expected value)
48  /// if nsig2 > nsig1 (default is nsig1=1 and nsig2=2) the second band is also done.
49  /// The first band is drawn in green while the second in yellow
50  /// The plot (expected value + bands) is returned as a TMultiGraph object
51  TMultiGraph* MakeExpectedPlot(double sig1=1, double sig2=2) ;
52 
53  /// Plot the test statistic distributions
54  SamplingDistPlot * MakeTestStatPlot(int index, int type=0, int nbins = 100);
55 
56 
57  /// Draw the scan result in the current canvas
58  /// Possible options:
59  /// "" (default): draw observed + expected with 1 and 2 sigma bands
60  /// SAME : draw in the current axis
61  /// OBS : draw only the observed plot
62  /// EXP : draw only the expected plot
63  /// CLB : draw also CLb
64  /// 2CL : drow both CLs+b and CLs
65  void Draw(Option_t *opt="");
66 
67  /// destructor
68  ~HypoTestInverterPlot() ;
69 
70  private:
71 
72  HypoTestInverterResult* fResults;
73 
74  protected:
75 
76  ClassDef(HypoTestInverterPlot,1) // HypoTestInverterPlot class
77 
78  };
79 }
80 
81 #endif