ROOT  6.06/09
Reference Guide
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
RooStats::ToyMCImportanceSampler Class Reference

ToyMCImportanceSampler is an extension of the ToyMCSampler for Importance Sampling.

Implementation based on a work by Cranmer, Kreiss, Read (in Preparation)

Definition at line 37 of file ToyMCImportanceSampler.h.

Public Member Functions

 ToyMCImportanceSampler ()
 
 ToyMCImportanceSampler (TestStatistic &ts, Int_t ntoys)
 
virtual ~ToyMCImportanceSampler ()
 
virtual RooDataSetGetSamplingDistributionsSingleWorker (RooArgSet &paramPoint)
 
virtual RooAbsDataGenerateToyData (RooArgSet &paramPoint, double &weight) const
 
virtual RooAbsDataGenerateToyData (RooArgSet &paramPoint, double &weight, std::vector< double > &impNLLs, double &nullNLL) const
 
virtual RooAbsDataGenerateToyData (std::vector< double > &weights) const
 
virtual RooAbsDataGenerateToyData (std::vector< double > &weights, std::vector< double > &nullNLLs, std::vector< double > &impNLLs) const
 
void SetDensityToGenerateFromByIndex (unsigned int i, bool fromNull=false)
 specifies the pdf to sample from More...
 
void AddImportanceDensity (RooAbsPdf *p, const RooArgSet *s)
 
void AddNullDensity (RooAbsPdf *p, const RooArgSet *s=NULL)
 
virtual void SetPdf (RooAbsPdf &pdf)
 
void SetParametersForTestStat (const RooArgSet &nullpoi)
 
void SetApplyVeto (bool b=true)
 
void SetReuseNLL (bool r=true)
 
virtual void SetConditionalObservables (const RooArgSet &set)
 
int CreateNImpDensitiesForOnePOI (RooAbsPdf &pdf, const RooArgSet &allPOI, RooRealVar &poi, int n, double poiValueForBackground=0.0)
 
int CreateImpDensitiesForOnePOIAdaptively (RooAbsPdf &pdf, const RooArgSet &allPOI, RooRealVar &poi, double nStdDevOverlap=0.5, double poiValueForBackground=0.0)
 
void SetEqualNumToysPerDensity (void)
 
void SetExpIncreasingNumToysPerDensity (void)
 
- Public Member Functions inherited from RooStats::ToyMCSampler
 ToyMCSampler ()
 
 ToyMCSampler (TestStatistic &ts, Int_t ntoys)
 
virtual ~ToyMCSampler ()
 
void SetUseMultiGen (Bool_t flag)
 
virtual SamplingDistributionGetSamplingDistribution (RooArgSet &paramPoint)
 
virtual RooDataSetGetSamplingDistributions (RooArgSet &paramPoint)
 
virtual SamplingDistributionAppendSamplingDistribution (RooArgSet &allParameters, SamplingDistribution *last, Int_t additionalMC)
 
virtual void AddTestStatistic (TestStatistic *t=NULL)
 
virtual RooAbsDataGenerateToyData (RooArgSet &paramPoint, RooAbsPdf &pdf) const
 
virtual RooAbsDataGenerateToyData (RooArgSet &paramPoint) const
 
virtual RooAbsDataGenerateToyData (RooArgSet &paramPoint, double &weight, RooAbsPdf &pdf) const
 
virtual void GenerateGlobalObservables (RooAbsPdf &pdf) const
 
virtual Double_t EvaluateTestStatistic (RooAbsData &data, RooArgSet &nullPOI, int i)
 
virtual Double_t EvaluateTestStatistic (RooAbsData &data, RooArgSet &nullPOI)
 
virtual RooArgListEvaluateAllTestStatistics (RooAbsData &data, const RooArgSet &poi)
 
virtual TestStatisticGetTestStatistic (unsigned int i) const
 
virtual TestStatisticGetTestStatistic (void) const
 
virtual Double_t ConfidenceLevel () const
 
virtual void Initialize (RooAbsArg &, RooArgSet &, RooArgSet &)
 
virtual Int_t GetNToys (void)
 
virtual void SetNToys (const Int_t ntoy)
 
virtual void SetNEventsPerToy (const Int_t nevents)
 
virtual void SetPriorNuisance (RooAbsPdf *pdf)
 
virtual void SetNuisanceParameters (const RooArgSet &np)
 
virtual void SetObservables (const RooArgSet &o)
 
virtual void SetGlobalObservables (const RooArgSet &o)
 
virtual void SetTestSize (Double_t size)
 
virtual void SetConfidenceLevel (Double_t cl)
 
virtual void SetTestStatistic (TestStatistic *testStatistic, unsigned int i)
 
virtual void SetTestStatistic (TestStatistic *t)
 
virtual void SetExpectedNuisancePar (Bool_t i=kTRUE)
 
virtual void SetAsimovNuisancePar (Bool_t i=kTRUE)
 
Bool_t CheckConfig (void)
 
void SetGenerateBinned (bool binned=true)
 
void SetGenerateBinnedTag (const char *binnedTag="")
 
void SetGenerateAutoBinned (Bool_t autoBinned=kTRUE)
 
void SetSamplingDistName (const char *name)
 
std::string GetSamplingDistName (void)
 
void SetMaxToys (Double_t t)
 
void SetToysLeftTail (Double_t toys, Double_t threshold)
 
void SetToysRightTail (Double_t toys, Double_t threshold)
 
void SetToysBothTails (Double_t toys, Double_t low_threshold, Double_t high_threshold)
 
void SetProofConfig (ProofConfig *pc=NULL)
 
void SetProtoData (const RooDataSet *d)
 
- Public Member Functions inherited from RooStats::TestStatSampler
virtual ~TestStatSampler ()
 

Protected Member Functions

virtual void ClearCache ()
 
- Protected Member Functions inherited from RooStats::ToyMCSampler
const RooArgListEvaluateAllTestStatistics (RooAbsData &data, const RooArgSet &poi, DetailedOutputAggregator &detOutAgg)
 
RooAbsDataGenerate (RooAbsPdf &pdf, RooArgSet &observables, const RooDataSet *protoData=NULL, int forceEvents=0) const
 

Protected Attributes

unsigned int fIndexGenDensity
 
bool fGenerateFromNull
 
bool fApplyVeto
 
RooArgSet fConditionalObs
 
std::vector< RooAbsPdf * > fNullDensities
 
std::vector< const RooArgSet * > fNullSnapshots
 
std::vector< RooAbsPdf * > fImportanceDensities
 
std::vector< const RooArgSet * > fImportanceSnapshots
 
bool fReuseNLL
 
toysStrategies fToysStrategy
 
std::vector< RooAbsReal * > fNullNLLs
 
std::vector< RooAbsReal * > fImpNLLs
 
- Protected Attributes inherited from RooStats::ToyMCSampler
RooAbsPdffPdf
 
const RooArgSetfParametersForTestStat
 
std::vector< TestStatistic * > fTestStatistics
 
std::string fSamplingDistName
 
RooAbsPdffPriorNuisance
 
const RooArgSetfNuisancePars
 
const RooArgSetfObservables
 
const RooArgSetfGlobalObservables
 
Int_t fNToys
 
Int_t fNEvents
 
Double_t fSize
 
Bool_t fExpectedNuisancePar
 
Bool_t fGenerateBinned
 
TString fGenerateBinnedTag
 
Bool_t fGenerateAutoBinned
 
Double_t fToysInTails
 
Double_t fMaxToys
 
Double_t fAdaptiveLowLimit
 
Double_t fAdaptiveHighLimit
 
const RooDataSetfProtoData
 
ProofConfigfProofConfig
 
NuisanceParametersSamplerfNuisanceParametersSampler
 
RooArgSet_allVars
 
std::list< RooAbsPdf * > _pdfList
 
std::list< RooArgSet * > _obsList
 
std::list< RooAbsPdf::GenSpec * > _gsList
 
RooAbsPdf::GenSpec_gs1
 
RooAbsPdf::GenSpec_gs2
 GenSpec #1. More...
 
RooAbsPdf::GenSpec_gs3
 GenSpec #2. More...
 
RooAbsPdf::GenSpec_gs4
 GenSpec #3. More...
 
Bool_t fUseMultiGen
 

Additional Inherited Members

- Static Public Member Functions inherited from RooStats::ToyMCSampler
static void SetAlwaysUseMultiGen (Bool_t flag)
 
- Static Protected Attributes inherited from RooStats::ToyMCSampler
static Bool_t fgAlwaysUseMultiGen
 GenSpec #4. More...
 

#include <RooStats/ToyMCImportanceSampler.h>

+ Inheritance diagram for RooStats::ToyMCImportanceSampler:
+ Collaboration diagram for RooStats::ToyMCImportanceSampler:

Constructor & Destructor Documentation

RooStats::ToyMCImportanceSampler::ToyMCImportanceSampler ( )
inline

Definition at line 40 of file ToyMCImportanceSampler.h.

RooStats::ToyMCImportanceSampler::ToyMCImportanceSampler ( TestStatistic ts,
Int_t  ntoys 
)
inline

Definition at line 51 of file ToyMCImportanceSampler.h.

virtual RooStats::ToyMCImportanceSampler::~ToyMCImportanceSampler ( )
virtual

Member Function Documentation

void RooStats::ToyMCImportanceSampler::AddImportanceDensity ( RooAbsPdf p,
const RooArgSet s 
)
inline

Definition at line 103 of file ToyMCImportanceSampler.h.

void RooStats::ToyMCImportanceSampler::AddNullDensity ( RooAbsPdf p,
const RooArgSet s = NULL 
)
inline

Definition at line 124 of file ToyMCImportanceSampler.h.

Referenced by SetParametersForTestStat(), and SetPdf().

virtual void RooStats::ToyMCImportanceSampler::ClearCache ( )
protectedvirtual
int RooStats::ToyMCImportanceSampler::CreateImpDensitiesForOnePOIAdaptively ( RooAbsPdf pdf,
const RooArgSet allPOI,
RooRealVar poi,
double  nStdDevOverlap = 0.5,
double  poiValueForBackground = 0.0 
)
int RooStats::ToyMCImportanceSampler::CreateNImpDensitiesForOnePOI ( RooAbsPdf pdf,
const RooArgSet allPOI,
RooRealVar poi,
int  n,
double  poiValueForBackground = 0.0 
)
virtual RooAbsData* RooStats::ToyMCImportanceSampler::GenerateToyData ( RooArgSet paramPoint,
double weight 
) const
virtual

Reimplemented from RooStats::ToyMCSampler.

virtual RooAbsData* RooStats::ToyMCImportanceSampler::GenerateToyData ( RooArgSet paramPoint,
double weight,
std::vector< double > &  impNLLs,
double nullNLL 
) const
virtual
virtual RooAbsData* RooStats::ToyMCImportanceSampler::GenerateToyData ( std::vector< double > &  weights) const
virtual
virtual RooAbsData* RooStats::ToyMCImportanceSampler::GenerateToyData ( std::vector< double > &  weights,
std::vector< double > &  nullNLLs,
std::vector< double > &  impNLLs 
) const
virtual
virtual RooDataSet* RooStats::ToyMCImportanceSampler::GetSamplingDistributionsSingleWorker ( RooArgSet paramPoint)
virtual

Reimplemented from RooStats::ToyMCSampler.

void RooStats::ToyMCImportanceSampler::SetApplyVeto ( bool  b = true)
inline

Definition at line 166 of file ToyMCImportanceSampler.h.

virtual void RooStats::ToyMCImportanceSampler::SetConditionalObservables ( const RooArgSet set)
inlinevirtual

Definition at line 174 of file ToyMCImportanceSampler.h.

void RooStats::ToyMCImportanceSampler::SetDensityToGenerateFromByIndex ( unsigned int  i,
bool  fromNull = false 
)
inline

specifies the pdf to sample from

Definition at line 83 of file ToyMCImportanceSampler.h.

void RooStats::ToyMCImportanceSampler::SetEqualNumToysPerDensity ( void  )
inline

Definition at line 192 of file ToyMCImportanceSampler.h.

void RooStats::ToyMCImportanceSampler::SetExpIncreasingNumToysPerDensity ( void  )
inline

Definition at line 193 of file ToyMCImportanceSampler.h.

void RooStats::ToyMCImportanceSampler::SetParametersForTestStat ( const RooArgSet nullpoi)
inlinevirtual

Reimplemented from RooStats::ToyMCSampler.

Definition at line 150 of file ToyMCImportanceSampler.h.

virtual void RooStats::ToyMCImportanceSampler::SetPdf ( RooAbsPdf pdf)
inlinevirtual

Reimplemented from RooStats::ToyMCSampler.

Definition at line 140 of file ToyMCImportanceSampler.h.

void RooStats::ToyMCImportanceSampler::SetReuseNLL ( bool  r = true)
inline

Definition at line 168 of file ToyMCImportanceSampler.h.

Member Data Documentation

bool RooStats::ToyMCImportanceSampler::fApplyVeto
protected

Definition at line 202 of file ToyMCImportanceSampler.h.

Referenced by SetApplyVeto(), and ToyMCImportanceSampler().

RooArgSet RooStats::ToyMCImportanceSampler::fConditionalObs
protected

Definition at line 204 of file ToyMCImportanceSampler.h.

Referenced by SetConditionalObservables().

bool RooStats::ToyMCImportanceSampler::fGenerateFromNull
protected
std::vector<RooAbsReal*> RooStats::ToyMCImportanceSampler::fImpNLLs
mutableprotected

Definition at line 219 of file ToyMCImportanceSampler.h.

Referenced by AddImportanceDensity().

std::vector<RooAbsPdf*> RooStats::ToyMCImportanceSampler::fImportanceDensities
protected
std::vector<const RooArgSet*> RooStats::ToyMCImportanceSampler::fImportanceSnapshots
protected

Definition at line 212 of file ToyMCImportanceSampler.h.

Referenced by AddImportanceDensity().

unsigned int RooStats::ToyMCImportanceSampler::fIndexGenDensity
protected
std::vector<RooAbsPdf*> RooStats::ToyMCImportanceSampler::fNullDensities
protected
std::vector<RooAbsReal*> RooStats::ToyMCImportanceSampler::fNullNLLs
mutableprotected

Definition at line 218 of file ToyMCImportanceSampler.h.

Referenced by AddNullDensity().

std::vector<const RooArgSet*> RooStats::ToyMCImportanceSampler::fNullSnapshots
mutableprotected

Definition at line 208 of file ToyMCImportanceSampler.h.

Referenced by AddNullDensity(), and SetParametersForTestStat().

bool RooStats::ToyMCImportanceSampler::fReuseNLL
protected

Definition at line 214 of file ToyMCImportanceSampler.h.

Referenced by SetReuseNLL(), and ToyMCImportanceSampler().

toysStrategies RooStats::ToyMCImportanceSampler::fToysStrategy
protected

The documentation for this class was generated from the following file: