Logo ROOT  
Reference Guide
TestStatSampler.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_TestStatSampler
12#define ROOSTATS_TestStatSampler
13
14
15#include "Rtypes.h"
16
17class RooAbsArg;
18class RooAbsData;
19class RooArgSet;
20class RooAbsPdf;
21
22
23
24
25namespace RooStats {
26
27 class SamplingDistribution;
28 class TestStatistic;
29
30/** \class RooStats::TestStatSampler
31 \ingroup Roostats
32
33TestStatSampler is an interface class for a tools which produce RooStats
34SamplingDistributions. Tools that implement this interface are expected to be
35used for coverage studies, the Neyman Construction, etc.
36
37*/
38
40
41 public:
42 // TestStatSampler();
43 virtual ~TestStatSampler() {}
44
45 // Main interface to get a ConfInterval, pure virtual
47
48 // Main interface to evaluate the test statistic on a dataset
49 virtual Double_t EvaluateTestStatistic(RooAbsData& data, RooArgSet& paramsOfInterest) = 0;
50
51 // Get the TestStatistic
52 virtual TestStatistic* GetTestStatistic() const = 0;
53
54 // Get the Confidence level for the test
55 virtual Double_t ConfidenceLevel() const = 0;
56
57 // Common Initialization
58 virtual void Initialize(RooAbsArg& testStatistic, RooArgSet& paramsOfInterest, RooArgSet& nuisanceParameters) = 0;
59
60 // Set the Pdf, add to the the workspace if not already there
61 virtual void SetPdf(RooAbsPdf&) = 0;
62 // How to randomize the prior. Set to NULL to deactivate randomization.
63 virtual void SetPriorNuisance(RooAbsPdf*) = 0;
64
65 // specify the values of parameters used when evaluating test statistic
66 virtual void SetParametersForTestStat(const RooArgSet& /*nullpoi*/) = 0;
67
68 // REMOVE THIS
69 // specify the parameters of interest in the interval
70 // virtual void SetParameters(const RooArgSet&) = 0;
71
72 // specify the nuisance parameters (eg. the rest of the parameters)
73 virtual void SetNuisanceParameters(const RooArgSet&) = 0;
74 // specify the observables in the dataset (needed to evaluate the test statistic)
75 virtual void SetObservables(const RooArgSet& ) = 0;
76 // specify the conditional observables
77 virtual void SetGlobalObservables(const RooArgSet& ) = 0;
78
79 // set the size of the test (rate of Type I error) ( Eg. 0.05 for a 95% Confidence Interval)
80 virtual void SetTestSize(Double_t size) = 0;
81 // set the confidence level for the interval (eg. 0.95 for a 95% Confidence Interval)
82 virtual void SetConfidenceLevel(Double_t cl) = 0;
83
84 // Set the TestStatistic (want the argument to be a function of the data & parameter points
85 virtual void SetTestStatistic(TestStatistic* testStatistic) = 0;
86
87 // Set the name of the sampling distribution used for plotting
88 virtual void SetSamplingDistName(const char* name) = 0;
89
90
91 protected:
92 ClassDef(TestStatSampler,1) // Interface for tools setting limits (producing confidence intervals)
93 };
94}
95
96
97#endif
double Double_t
Definition: RtypesCore.h:57
#define ClassDef(name, id)
Definition: Rtypes.h:322
char name[80]
Definition: TGX11.cxx:109
RooAbsArg is the common abstract base class for objects that represent a value (of arbitrary type) an...
Definition: RooAbsArg.h:73
RooAbsData is the common abstract base class for binned and unbinned datasets.
Definition: RooAbsData.h:44
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Definition: RooArgSet.h:28
This class simply holds a sampling distribution of some test statistic.
TestStatSampler is an interface class for a tools which produce RooStats SamplingDistributions.
virtual Double_t EvaluateTestStatistic(RooAbsData &data, RooArgSet &paramsOfInterest)=0
virtual void SetTestSize(Double_t size)=0
virtual void SetConfidenceLevel(Double_t cl)=0
virtual Double_t ConfidenceLevel() const =0
virtual void SetObservables(const RooArgSet &)=0
virtual void Initialize(RooAbsArg &testStatistic, RooArgSet &paramsOfInterest, RooArgSet &nuisanceParameters)=0
virtual TestStatistic * GetTestStatistic() const =0
virtual void SetTestStatistic(TestStatistic *testStatistic)=0
virtual void SetParametersForTestStat(const RooArgSet &)=0
virtual void SetPriorNuisance(RooAbsPdf *)=0
virtual void SetNuisanceParameters(const RooArgSet &)=0
virtual SamplingDistribution * GetSamplingDistribution(RooArgSet &paramsOfInterest)=0
virtual void SetSamplingDistName(const char *name)=0
virtual void SetGlobalObservables(const RooArgSet &)=0
virtual void SetPdf(RooAbsPdf &)=0
TestStatistic is an interface class to provide a facility for construction test statistics distributi...
Definition: TestStatistic.h:31
Namespace for the RooStats classes.
Definition: Asimov.h:19