Logo ROOT   6.08/07
Reference Guide
NumberCountingUtils.h
Go to the documentation of this file.
1 // @(#)root/roostats:$Id$
2 // Author: Kyle Cranmer 28/07/2008
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2008, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 #ifndef RooStats_NumberCountingUtils
13 #define RooStats_NumberCountingUtils
14 
15 //_________________________________________________
16 /*
17 BEGIN_HTML
18 <h2>NumberCountingUtils</h2>
19 <p>
20 These are RooStats standalone utilities
21 that calculate the p-value or Z value (eg. significance in
22 1-sided Gaussian standard deviations) for a number counting experiment.
23 This is a hypothesis test between background only and signal-plus-background.
24 The background estimate has uncertainty derived from an auxiliary or sideband
25 measurement.
26 </p>
27 <p>
28 This is based on code and comments from Bob Cousins
29 and on the following papers:
30 <p>
31 <ul>
32 <li>Evaluation of three methods for calculating statistical significance when incorporating a
33 systematic uncertainty into a test of the background-only hypothesis for a Poisson process<br />
34 Authors: Robert D. Cousins, James T. Linnemann, Jordan Tucker<br />
35 http://arxiv.org/abs/physics/0702156<br />
36 NIM A 595 (2008) 480--501</li>
37 
38 <li>
39 Statistical Challenges for Searches for New Physics at the LHC<br />
40 Authors: Kyle Cranmer<br />
41 http://arxiv.org/abs/physics/0511028
42 </li>
43 <li>
44  Measures of Significance in HEP and Astrophysics<br />
45  Authors: J. T. Linnemann<br />
46  http://arxiv.org/abs/physics/0312059
47 </li>
48 </ul>
49 <p>
50 The problem is treated in a fully frequentist fashion by
51 interpreting the relative background uncertainty as
52 being due to an auxiliary or sideband observation
53 that is also Poisson distributed with only background.
54 Finally, one considers the test as a ratio of Poisson means
55 where an interval is well known based on the conditioning on the total
56 number of events and the binomial distribution.
57 </p>
58 
59 <p>
60 In short, this is an exact frequentist solution to the problem of
61 a main measurement x distributed as a Poisson around s+b and a sideband or
62 auxiliary measurement y distributed as a Poisson around tau*b. Eg.
63 </p>
64 END_HTML
65 BEGIN_LATEX
66 L(x,y|s,b,#tau) = Pois(x|s+b) Pois(y|#tau b)
67 END_LATEX
68 BEGIN_HTML
69 <pre>
70 Naming conventions:
71 Exp = Expected
72 Obs = Observed
73 P = p-value
74 Z = Z-value or significance in sigma (one-sided convention)
75 </pre>
76 END_HTML
77 */
78 //
79 
80 #include "Rtypes.h"
81 
82 
83 namespace RooStats{
84 
85  namespace NumberCountingUtils {
86 
87 
88  // Expected P-value for s=0 in a ratio of Poisson means.
89  // Here the background and its uncertainty are provided directly and
90  // assumed to be from the double Poisson counting setup described in the
91  // BinomialWithTau functions.
92  // Normally one would know tau directly, but here it is determiend from
93  // the background uncertainty. This is not strictly correct, but a useful
94  // approximation.
95  Double_t BinomialExpZ(Double_t sExp, Double_t bExp, Double_t fractionalBUncertainty);
96 
97  // See BinomialWithTauExpP
99 
100  // See BinomialObsP
101  Double_t BinomialObsZ(Double_t nObs, Double_t bExp, Double_t fractionalBUncertainty);
102 
103  // See BinomialWithTauObsP
105 
106  // See BinomialExpP
107  Double_t BinomialExpP(Double_t sExp, Double_t bExp, Double_t fractionalBUncertainty);
108 
109  // Expected P-value for s=0 in a ratio of Poisson means.
110  // Based on two expectations, a main measurement that might have signal
111  // and an auxiliarly measurement for the background that is signal free.
112  // The expected background in the auxiliary measurement is a factor
113  // tau larger than in the main measurement.
115 
116  // P-value for s=0 in a ratio of Poisson means.
117  // Here the background and its uncertainty are provided directly and
118  // assumed to be from the double Poisson counting setup.
119  // Normally one would know tau directly, but here it is determiend from
120  // the background uncertainty. This is not strictly correct, but a useful
121  // approximation.
122  Double_t BinomialObsP(Double_t nObs, Double_t, Double_t fractionalBUncertainty);
123 
124  // P-value for s=0 in a ratio of Poisson means.
125  // Based on two observations, a main measurement that might have signal
126  // and an auxiliarly measurement for the background that is signal free.
127  // The expected background in the auxiliary measurement is a factor
128  // tau larger than in the main measurement.
130 
131 
132  }
133 }
134 
135 #endif
Double_t BinomialWithTauObsP(Double_t nObs, Double_t bExp, Double_t tau)
Double_t BinomialObsP(Double_t nObs, Double_t, Double_t fractionalBUncertainty)
you should not use this method at all Int_t Int_t Double_t Double_t Double_t Int_t Double_t Double_t Double_t tau
Definition: TRolke.cxx:630
Double_t BinomialWithTauObsZ(Double_t nObs, Double_t bExp, Double_t tau)
Double_t BinomialExpZ(Double_t sExp, Double_t bExp, Double_t fractionalBUncertainty)
Namespace for the RooStats classes.
Definition: Asimov.h:20
double Double_t
Definition: RtypesCore.h:55
Double_t BinomialExpP(Double_t sExp, Double_t bExp, Double_t fractionalBUncertainty)
Double_t BinomialWithTauExpP(Double_t sExp, Double_t bExp, Double_t tau)
Double_t BinomialObsZ(Double_t nObs, Double_t bExp, Double_t fractionalBUncertainty)
Double_t BinomialWithTauExpZ(Double_t sExp, Double_t bExp, Double_t tau)