Logo ROOT  
Reference Guide
Systematics.h
Go to the documentation of this file.
1 // @(#)root/roostats:$Id$
2 // Author: George Lewis, Kyle Cranmer
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 HISTFACTORY_SYSTEMATICS_H
12 #define HISTFACTORY_SYSTEMATICS_H
13 
14 #include <string>
15 #include <fstream>
16 #include <iostream>
17 
18 #include "TH1.h"
20 
21 namespace RooStats{
22 namespace HistFactory {
23 
24  namespace Constraint {
25  enum Type{ Gaussian, Poisson };
26  std::string Name( Type type );
27  Type GetType( const std::string& Name );
28  }
29 
30 
31  // Base class for common functions
32  /*
33  class Systematic {
34 
35  public:
36 
37  virtual void Print(std::ostream& = std::cout);
38  virtual void writeToFile(const std::string& FileName,
39  const std::string& Directory);
40 
41 
42  };
43  */
44 
45 /** \class OverallSys
46  * \ingroup HistFactory
47  * Configuration for a constrained overall systematic to scale sample normalisations.
48  */
49  class OverallSys {
50 
51  public:
52 
53  OverallSys() : fLow(0), fHigh(0) {}
54 
55  void SetName( const std::string& Name ) { fName = Name; }
56  const std::string& GetName() const { return fName; }
57 
58  void SetLow( double Low ) { fLow = Low; }
59  void SetHigh( double High ) { fHigh = High; }
60  double GetLow() const { return fLow; }
61  double GetHigh() const { return fHigh; }
62 
63  void Print(std::ostream& = std::cout) const;
64  void PrintXML(std::ostream&) const;
65 
66  protected:
67  std::string fName;
68  double fLow;
69  double fHigh;
70 
71  };
72 
73 /** \class NormFactor
74  * \ingroup HistFactory
75  * Configuration for an \a un- constrained overall systematic to scale sample normalisations.
76  */
77  class NormFactor {
78 
79  public:
80 
81  NormFactor();
82 
83  void SetName( const std::string& Name ) { fName = Name; }
84  std::string GetName() const { return fName; }
85 
86  void SetVal( double Val ) { fVal = Val; }
87  double GetVal() const { return fVal; }
88 
89  void SetConst( bool Const=true ) { fConst = Const; }
90  bool GetConst() const { return fConst; }
91 
92  void SetLow( double Low ) { fLow = Low; }
93  void SetHigh( double High ) { fHigh = High; }
94  double GetLow() const { return fLow; }
95  double GetHigh() const { return fHigh; }
96 
97  void Print(std::ostream& = std::cout) const;
98  void PrintXML(std::ostream&) const;
99 
100  protected:
101 
102  std::string fName;
103  double fVal;
104  double fLow;
105  double fHigh;
106  bool fConst;
107 
108  };
109 
110 
111  /** ////////////////////////////////////////////////////////////////////////////////////////////
112  * \class HistogramUncertaintyBase
113  * \ingroup HistFactory
114  * Base class to store the up and down variations for histogram uncertainties.
115  * Use the derived classes for actual models.
116  */
118 
119  public:
120 
121  HistogramUncertaintyBase() : fhLow(nullptr), fhHigh(nullptr) {}
122  HistogramUncertaintyBase(const std::string& Name) : fName(Name), fhLow(nullptr), fhHigh(nullptr) {}
124  fName{oth.fName},
125  fInputFileLow{oth.fInputFileLow}, fHistoNameLow{oth.fHistoNameLow}, fHistoPathLow{oth.fHistoPathLow},
126  fInputFileHigh{oth.fInputFileHigh}, fHistoNameHigh{oth.fHistoNameHigh}, fHistoPathHigh{oth.fHistoPathHigh},
127  fhLow{oth.fhLow ? static_cast<TH1*>(oth.fhLow->Clone()) : nullptr},
128  fhHigh{oth.fhHigh ? static_cast<TH1*>(oth.fhHigh->Clone()) : nullptr} {
129 
130  }
132 
134 
135 
136  // Need deep copies because the class owns its histograms.
138  fName = oth.fName;
145  fhLow.reset(oth.fhLow ? static_cast<TH1*>(oth.fhLow->Clone()) : nullptr);
146  fhHigh.reset(oth.fhHigh ? static_cast<TH1*>(oth.fhHigh->Clone()) : nullptr);
147 
148  return *this;
149  }
151 
152  virtual void Print(std::ostream& = std::cout) const;
153  virtual void PrintXML(std::ostream&) const = 0;
154  virtual void writeToFile( const std::string& FileName, const std::string& DirName );
155 
156  void SetHistoLow(TH1* Low ) {Low->SetDirectory(nullptr); fhLow.reset(Low);}
157  void SetHistoHigh(TH1* High ) {High->SetDirectory(nullptr); fhHigh.reset(High);}
158 
159  const TH1* GetHistoLow() const {return fhLow.get();}
160  const TH1* GetHistoHigh() const {return fhHigh.get();}
161 
162  void SetName( const std::string& Name ) { fName = Name; }
163  const std::string& GetName() const { return fName; }
164 
165  void SetInputFileLow( const std::string& InputFileLow ) { fInputFileLow = InputFileLow; }
166  void SetInputFileHigh( const std::string& InputFileHigh ) { fInputFileHigh = InputFileHigh; }
167 
168  const std::string& GetInputFileLow() const { return fInputFileLow; }
169  const std::string& GetInputFileHigh() const { return fInputFileHigh; }
170 
171  void SetHistoNameLow( const std::string& HistoNameLow ) { fHistoNameLow = HistoNameLow; }
172  void SetHistoNameHigh( const std::string& HistoNameHigh ) { fHistoNameHigh = HistoNameHigh; }
173 
174  const std::string& GetHistoNameLow() const { return fHistoNameLow; }
175  const std::string& GetHistoNameHigh() const { return fHistoNameHigh; }
176 
177  void SetHistoPathLow( const std::string& HistoPathLow ) { fHistoPathLow = HistoPathLow; }
178  void SetHistoPathHigh( const std::string& HistoPathHigh ) { fHistoPathHigh = HistoPathHigh; }
179 
180  const std::string& GetHistoPathLow() const { return fHistoPathLow; }
181  const std::string& GetHistoPathHigh() const { return fHistoPathHigh; }
182 
183  protected:
184 
185  std::string fName;
186 
187  std::string fInputFileLow;
188  std::string fHistoNameLow;
189  std::string fHistoPathLow;
190 
191  std::string fInputFileHigh;
192  std::string fHistoNameHigh;
193  std::string fHistoPathHigh;
194 
195  // The Low and High Histograms
196  std::unique_ptr<TH1> fhLow;
197  std::unique_ptr<TH1> fhHigh;
198 
199  };
200 
201 /** \class HistoSys
202  * \ingroup HistFactory
203  * Configuration for a constrained, coherent shape variation of affected samples.
204  */
205 class HistoSys final : public HistogramUncertaintyBase {
206 public:
207  virtual ~HistoSys() {}
208  virtual void PrintXML(std::ostream&) const override;
209 };
210 
211 /** \class HistoFactor
212  * \ingroup HistFactory
213  * Configuration for an *un*constrained, coherent shape variation of affected samples.
214  */
215  class HistoFactor final : public HistogramUncertaintyBase {
216  public:
217  virtual ~HistoFactor() {}
218  void PrintXML(std::ostream&) const override;
219  };
220 
221 /** \class ShapeSys
222  * \ingroup HistFactory
223  * Constrained bin-by-bin variation of affected histogram.
224  */
225  class ShapeSys final : public HistogramUncertaintyBase {
226 
227  public:
228 
231  fConstraintType(Constraint::Gaussian) {}
232  ShapeSys(const ShapeSys& other) :
235  ShapeSys& operator=(const ShapeSys& oth) {
236  if (this == &oth) return *this;
239  return *this;
240  }
241  ShapeSys& operator=(ShapeSys&&) = default;
242 
243  void SetInputFile( const std::string& InputFile ) { fInputFileHigh = InputFile; }
244  std::string GetInputFile() const { return fInputFileHigh; }
245 
246  void SetHistoName( const std::string& HistoName ) { fHistoNameHigh = HistoName; }
247  std::string GetHistoName() const { return fHistoNameHigh; }
248 
249  void SetHistoPath( const std::string& HistoPath ) { fHistoPathHigh = HistoPath; }
250  std::string GetHistoPath() const { return fHistoPathHigh; }
251 
252  void Print(std::ostream& = std::cout) const override;
253  void PrintXML(std::ostream&) const override;
254  void writeToFile( const std::string& FileName, const std::string& DirName ) override;
255 
256  const TH1* GetErrorHist() const {
257  return fhHigh.get();
258  }
259  void SetErrorHist(TH1* hError) {
260  fhHigh.reset(hError);
261  }
262 
263  void SetConstraintType( Constraint::Type ConstrType ) { fConstraintType = ConstrType; }
265 
266  protected:
268  };
269 
270 /** \class ShapeFactor
271  * \ingroup HistFactory
272  * *Un*constrained bin-by-bin variation of affected histogram.
273  */
275 
276  public:
277 
280  fConstant{false},
281  fHasInitialShape{false} {}
282 
283  void Print(std::ostream& = std::cout) const override;
284  void PrintXML(std::ostream&) const override;
285  void writeToFile( const std::string& FileName, const std::string& DirName) override;
286 
287  void SetInitialShape(TH1* shape) {
288  fhHigh.reset(shape);
289  }
290  const TH1* GetInitialShape() const { return fhHigh.get(); }
291 
292  void SetConstant(bool constant) { fConstant = constant; }
293  bool IsConstant() const { return fConstant; }
294 
295  bool HasInitialShape() const { return fHasInitialShape; }
296 
297  void SetInputFile( const std::string& InputFile ) {
298  fInputFileHigh = InputFile;
299  fHasInitialShape=true;
300  }
301  const std::string& GetInputFile() const { return fInputFileHigh; }
302 
303  void SetHistoName( const std::string& HistoName ) {
304  fHistoNameHigh = HistoName;
305  fHasInitialShape=true;
306  }
307  const std::string& GetHistoName() const { return fHistoNameHigh; }
308 
309  void SetHistoPath( const std::string& HistoPath ) {
310  fHistoPathHigh = HistoPath;
311  fHasInitialShape=true;
312  }
313  const std::string& GetHistoPath() const { return fHistoPathHigh; }
314 
315  protected:
316 
317  bool fConstant;
318 
319  // A histogram representing
320  // the initial shape
322  };
323 
324 /** \class StatError
325  * \ingroup HistFactory
326  * Statistical error of Monte Carlo predictions.
327  */
329 
330  public:
331 
334  fActivate(false), fUseHisto(false) {}
335 
336  void Print(std::ostream& = std::cout) const override;
337  void PrintXML(std::ostream&) const override;
338  void writeToFile( const std::string& FileName, const std::string& DirName ) override;
339 
340  void Activate( bool IsActive=true ) { fActivate = IsActive; }
341  bool GetActivate() const { return fActivate; }
342 
343  void SetUseHisto( bool UseHisto=true ) { fUseHisto = UseHisto; }
344  bool GetUseHisto() const { return fUseHisto; }
345 
346  void SetInputFile( const std::string& InputFile ) { fInputFileHigh = InputFile; }
347  const std::string& GetInputFile() const { return fInputFileHigh; }
348 
349  void SetHistoName( const std::string& HistoName ) { fHistoNameHigh = HistoName; }
350  const std::string& GetHistoName() const { return fHistoNameHigh; }
351 
352  void SetHistoPath( const std::string& HistoPath ) { fHistoPathHigh = HistoPath; }
353  const std::string& GetHistoPath() const { return fHistoPathHigh; }
354 
355 
356  const TH1* GetErrorHist() const {
357  return fhHigh.get();
358  }
360  fhHigh.reset(Error);
361  }
362 
363  protected:
364 
365  bool fActivate;
366  bool fUseHisto; // Use an external histogram for the errors
367  };
368 
369 /** \class StatErrorConfig
370  * \ingroup HistFactory
371  * Configuration to automatically assign nuisance parameters for the statistical
372  * error of the Monte Carlo simulations.
373  * The default is to assign a Poisson uncertainty to a bin when its statistical uncertainty
374  * is larger than 5% of the bin content.
375  */
377 
378  public:
379 
381  void Print(std::ostream& = std::cout) const;
382  void PrintXML(std::ostream&) const;
383 
384  void SetRelErrorThreshold( double Threshold ) { fRelErrorThreshold = Threshold; }
385  double GetRelErrorThreshold() const { return fRelErrorThreshold; }
386 
387  void SetConstraintType( Constraint::Type ConstrType ) { fConstraintType = ConstrType; }
389 
390  protected:
391 
394 
395  };
396 
397 
398 }
399 }
400 
401 #endif
RooStats::HistFactory::HistogramUncertaintyBase::GetHistoNameHigh
const std::string & GetHistoNameHigh() const
Definition: Systematics.h:175
RooStats::HistFactory::HistogramUncertaintyBase::GetInputFileLow
const std::string & GetInputFileLow() const
Definition: Systematics.h:168
RooStats::HistFactory::HistogramUncertaintyBase::GetHistoLow
const TH1 * GetHistoLow() const
Definition: Systematics.h:159
RooStats::HistFactory::HistogramUncertaintyBase::SetInputFileHigh
void SetInputFileHigh(const std::string &InputFileHigh)
Definition: Systematics.h:166
RooStats::HistFactory::ShapeFactor::SetInitialShape
void SetInitialShape(TH1 *shape)
Definition: Systematics.h:287
RooStats::HistFactory::ShapeSys::ShapeSys
ShapeSys()
Definition: Systematics.h:229
RooStats::HistFactory::ShapeSys::operator=
ShapeSys & operator=(ShapeSys &&)=default
RooStats::HistFactory::OverallSys::fHigh
double fHigh
Definition: Systematics.h:69
RooStats::HistFactory::ShapeFactor::SetInputFile
void SetInputFile(const std::string &InputFile)
Definition: Systematics.h:297
RooStats::HistFactory::StatError::PrintXML
void PrintXML(std::ostream &) const override
Definition: Systematics.cxx:293
RooStats::HistFactory::HistogramUncertaintyBase::SetHistoHigh
void SetHistoHigh(TH1 *High)
Definition: Systematics.h:157
RooStats::HistFactory::HistogramUncertaintyBase::GetHistoPathLow
const std::string & GetHistoPathLow() const
Definition: Systematics.h:180
RooStats::HistFactory::OverallSys::fName
std::string fName
Definition: Systematics.h:67
RooStats::HistFactory::HistogramUncertaintyBase::GetInputFileHigh
const std::string & GetInputFileHigh() const
Definition: Systematics.h:169
RooStats::HistFactory::ShapeSys::SetInputFile
void SetInputFile(const std::string &InputFile)
Definition: Systematics.h:243
RooStats::HistFactory::StatErrorConfig::PrintXML
void PrintXML(std::ostream &) const
Definition: Systematics.cxx:274
RooStats::HistFactory::NormFactor::GetLow
double GetLow() const
Definition: Systematics.h:94
RooStats::HistFactory::StatErrorConfig::GetRelErrorThreshold
double GetRelErrorThreshold() const
Definition: Systematics.h:385
RooStats::HistFactory::HistoSys::PrintXML
virtual void PrintXML(std::ostream &) const override
Definition: Systematics.cxx:143
RooStats::HistFactory::OverallSys::fLow
double fLow
Definition: Systematics.h:68
RooStats::HistFactory::OverallSys::SetLow
void SetLow(double Low)
Definition: Systematics.h:58
RooStats::HistFactory::HistogramUncertaintyBase::SetHistoLow
void SetHistoLow(TH1 *Low)
Definition: Systematics.h:156
RooStats::HistFactory::HistoSys::~HistoSys
virtual ~HistoSys()
Definition: Systematics.h:207
RooStats::HistFactory::StatError::GetActivate
bool GetActivate() const
Definition: Systematics.h:341
RooStats::HistFactory::OverallSys::GetHigh
double GetHigh() const
Definition: Systematics.h:61
RooStats::HistFactory::HistogramUncertaintyBase::SetHistoPathLow
void SetHistoPathLow(const std::string &HistoPathLow)
Definition: Systematics.h:177
RooStats::HistFactory::StatErrorConfig::Print
void Print(std::ostream &=std::cout) const
Definition: Systematics.cxx:268
RooStats::HistFactory::HistoFactor::PrintXML
void PrintXML(std::ostream &) const override
Definition: Systematics.cxx:201
RooStats::HistFactory::HistogramUncertaintyBase::operator=
HistogramUncertaintyBase & operator=(const HistogramUncertaintyBase &oth)
Definition: Systematics.h:137
RooStats::HistFactory::ShapeFactor::ShapeFactor
ShapeFactor()
Definition: Systematics.h:278
RooStats::HistFactory::Constraint::Poisson
@ Poisson
Definition: Systematics.h:25
RooStats::HistFactory::ShapeFactor::SetHistoName
void SetHistoName(const std::string &HistoName)
Definition: Systematics.h:303
RooStats::HistFactory::ShapeSys::SetConstraintType
void SetConstraintType(Constraint::Type ConstrType)
Definition: Systematics.h:263
RooStats::HistFactory::NormFactor
Configuration for an un- constrained overall systematic to scale sample normalisations.
Definition: Systematics.h:77
RooStats::HistFactory::NormFactor::NormFactor
NormFactor()
Definition: Systematics.cxx:57
RooStats::HistFactory::StatError::StatError
StatError()
Definition: Systematics.h:332
RooStats::HistFactory::HistoSys
Configuration for a constrained, coherent shape variation of affected samples.
Definition: Systematics.h:205
RooStats::HistFactory::HistogramUncertaintyBase::SetInputFileLow
void SetInputFileLow(const std::string &InputFileLow)
Definition: Systematics.h:165
RooStats::HistFactory::NormFactor::fLow
double fLow
Definition: Systematics.h:104
RooStats::HistFactory::HistogramUncertaintyBase::fhLow
std::unique_ptr< TH1 > fhLow
Definition: Systematics.h:196
RooStats::HistFactory::NormFactor::PrintXML
void PrintXML(std::ostream &) const
Definition: Systematics.cxx:70
RooStats::HistFactory::ShapeSys::writeToFile
void writeToFile(const std::string &FileName, const std::string &DirName) override
Definition: Systematics.cxx:176
RooStats::HistFactory::OverallSys::GetLow
double GetLow() const
Definition: Systematics.h:60
RooStats::HistFactory::OverallSys::Print
void Print(std::ostream &=std::cout) const
Definition: Systematics.cxx:80
RooStats::HistFactory::HistogramUncertaintyBase::PrintXML
virtual void PrintXML(std::ostream &) const =0
RooStats::HistFactory::NormFactor::GetHigh
double GetHigh() const
Definition: Systematics.h:95
RooStats::HistFactory::ShapeSys
Constrained bin-by-bin variation of affected histogram.
Definition: Systematics.h:225
RooStats::HistFactory::HistogramUncertaintyBase::~HistogramUncertaintyBase
virtual ~HistogramUncertaintyBase()
Definition: Systematics.h:133
RooStats::HistFactory::HistogramUncertaintyBase::fHistoPathHigh
std::string fHistoPathHigh
Definition: Systematics.h:193
RooStats::HistFactory::ShapeFactor::IsConstant
bool IsConstant() const
Definition: Systematics.h:293
RooStats::HistFactory::HistogramUncertaintyBase::HistogramUncertaintyBase
HistogramUncertaintyBase()
Definition: Systematics.h:121
RooStats::HistFactory::HistogramUncertaintyBase::HistogramUncertaintyBase
HistogramUncertaintyBase(const HistogramUncertaintyBase &oth)
Definition: Systematics.h:123
RooStats::HistFactory::ShapeSys::PrintXML
void PrintXML(std::ostream &) const override
Definition: Systematics.cxx:166
RooStats::HistFactory::OverallSys::SetName
void SetName(const std::string &Name)
Definition: Systematics.h:55
RooFit::HistFactory
@ HistFactory
Definition: RooGlobalFunc.h:69
RooStats::HistFactory::HistogramUncertaintyBase::HistogramUncertaintyBase
HistogramUncertaintyBase(const std::string &Name)
Definition: Systematics.h:122
RooStats::HistFactory::ShapeSys::SetHistoName
void SetHistoName(const std::string &HistoName)
Definition: Systematics.h:246
RooStats::HistFactory::ShapeSys::ShapeSys
ShapeSys(const ShapeSys &other)
Definition: Systematics.h:232
RooStats::HistFactory::HistogramUncertaintyBase
////////////////////////////////////////////////////////////////////////////////////////////Base clas...
Definition: Systematics.h:117
RooStats::HistFactory::HistogramUncertaintyBase::SetHistoNameLow
void SetHistoNameLow(const std::string &HistoNameLow)
Definition: Systematics.h:171
RooStats::HistFactory::HistogramUncertaintyBase::SetHistoPathHigh
void SetHistoPathHigh(const std::string &HistoPathHigh)
Definition: Systematics.h:178
RooStats::HistFactory::OverallSys::PrintXML
void PrintXML(std::ostream &) const
Definition: Systematics.cxx:87
RooStats::HistFactory::StatErrorConfig::SetConstraintType
void SetConstraintType(Constraint::Type ConstrType)
Definition: Systematics.h:387
RooStats::HistFactory::StatErrorConfig::fConstraintType
Constraint::Type fConstraintType
Definition: Systematics.h:393
RooStats::HistFactory::HistogramUncertaintyBase::writeToFile
virtual void writeToFile(const std::string &FileName, const std::string &DirName)
Definition: Systematics.cxx:106
RooStats::HistFactory::StatError
Statistical error of Monte Carlo predictions.
Definition: Systematics.h:328
RooStats::HistFactory::ShapeFactor::GetHistoPath
const std::string & GetHistoPath() const
Definition: Systematics.h:313
RooStats::HistFactory::StatError::SetUseHisto
void SetUseHisto(bool UseHisto=true)
Definition: Systematics.h:343
RooStats::HistFactory::OverallSys::SetHigh
void SetHigh(double High)
Definition: Systematics.h:59
RooStats::HistFactory::StatError::GetUseHisto
bool GetUseHisto() const
Definition: Systematics.h:344
RooStats::HistFactory::HistogramUncertaintyBase::GetName
const std::string & GetName() const
Definition: Systematics.h:163
RooStats::HistFactory::StatError::Activate
void Activate(bool IsActive=true)
Definition: Systematics.h:340
RooStats::HistFactory::StatErrorConfig::StatErrorConfig
StatErrorConfig()
Definition: Systematics.h:380
RooStats::HistFactory::NormFactor::SetLow
void SetLow(double Low)
Definition: Systematics.h:92
RooStats::HistFactory::HistogramUncertaintyBase::Print
virtual void Print(std::ostream &=std::cout) const
Definition: Systematics.cxx:95
RooStats::HistFactory::OverallSys::GetName
const std::string & GetName() const
Definition: Systematics.h:56
RooStats::HistFactory::StatError::GetHistoName
const std::string & GetHistoName() const
Definition: Systematics.h:350
RooStats::HistFactory::ShapeFactor::SetConstant
void SetConstant(bool constant)
Definition: Systematics.h:292
RooStats::HistFactory::HistogramUncertaintyBase::HistogramUncertaintyBase
HistogramUncertaintyBase(HistogramUncertaintyBase &&)=default
RooStats::HistFactory::ShapeSys::Print
void Print(std::ostream &=std::cout) const override
Definition: Systematics.cxx:157
RooStats::HistFactory::NormFactor::SetHigh
void SetHigh(double High)
Definition: Systematics.h:93
RooStats::HistFactory::ShapeFactor::GetInitialShape
const TH1 * GetInitialShape() const
Definition: Systematics.h:290
RooStats::HistFactory::HistogramUncertaintyBase::fInputFileLow
std::string fInputFileLow
Definition: Systematics.h:187
RooStats::HistFactory::Constraint::Gaussian
@ Gaussian
Definition: Systematics.h:25
RooStats::HistFactory::NormFactor::Print
void Print(std::ostream &=std::cout) const
Definition: Systematics.cxx:61
RooStats::HistFactory::Constraint::Type
Type
Definition: Systematics.h:25
RooStats::HistFactory::ShapeSys::GetErrorHist
const TH1 * GetErrorHist() const
Definition: Systematics.h:256
RooStats::HistFactory::OverallSys
Configuration for a constrained overall systematic to scale sample normalisations.
Definition: Systematics.h:49
RooStats::HistFactory::NormFactor::fVal
double fVal
Definition: Systematics.h:103
RooStats::HistFactory::ShapeFactor::HasInitialShape
bool HasInitialShape() const
Definition: Systematics.h:295
RooStats::HistFactory::StatErrorConfig
Configuration to automatically assign nuisance parameters for the statistical error of the Monte Carl...
Definition: Systematics.h:376
RooStats::HistFactory::HistogramUncertaintyBase::fInputFileHigh
std::string fInputFileHigh
Definition: Systematics.h:191
RooStats::HistFactory::ShapeFactor::writeToFile
void writeToFile(const std::string &FileName, const std::string &DirName) override
Definition: Systematics.cxx:233
RooStats::HistFactory::HistogramUncertaintyBase::GetHistoHigh
const TH1 * GetHistoHigh() const
Definition: Systematics.h:160
TH1::SetDirectory
virtual void SetDirectory(TDirectory *dir)
By default when an histogram is created, it is added to the list of histogram objects in the current ...
Definition: TH1.cxx:8703
RooStats::HistFactory::NormFactor::GetVal
double GetVal() const
Definition: Systematics.h:87
RooStats::HistFactory::HistogramUncertaintyBase::fName
std::string fName
Definition: Systematics.h:185
RooStats::HistFactory::NormFactor::fName
std::string fName
Definition: Systematics.h:102
RooStats::HistFactory::HistogramUncertaintyBase::GetHistoNameLow
const std::string & GetHistoNameLow() const
Definition: Systematics.h:174
RooStats::HistFactory::NormFactor::GetName
std::string GetName() const
Definition: Systematics.h:84
RooStats::HistFactory::ShapeFactor::PrintXML
void PrintXML(std::ostream &) const override
Definition: Systematics.cxx:256
RooStats::HistFactory::ShapeSys::GetInputFile
std::string GetInputFile() const
Definition: Systematics.h:244
RooStats::HistFactory::StatError::SetErrorHist
void SetErrorHist(TH1 *Error)
Definition: Systematics.h:359
RooStats::HistFactory::HistoFactor
Configuration for an *un*constrained, coherent shape variation of affected samples.
Definition: Systematics.h:215
RooStats::HistFactory::HistogramUncertaintyBase::operator=
HistogramUncertaintyBase & operator=(HistogramUncertaintyBase &&)=default
RooStats::HistFactory::HistogramUncertaintyBase::fhHigh
std::unique_ptr< TH1 > fhHigh
Definition: Systematics.h:197
RooStats::HistFactory::StatErrorConfig::SetRelErrorThreshold
void SetRelErrorThreshold(double Threshold)
Definition: Systematics.h:384
RooStats::HistFactory::OverallSys::OverallSys
OverallSys()
Definition: Systematics.h:53
RooStats::HistFactory::HistogramUncertaintyBase::fHistoNameLow
std::string fHistoNameLow
Definition: Systematics.h:188
RooStats::HistFactory::HistogramUncertaintyBase::SetHistoNameHigh
void SetHistoNameHigh(const std::string &HistoNameHigh)
Definition: Systematics.h:172
RooStats::HistFactory::HistogramUncertaintyBase::SetName
void SetName(const std::string &Name)
Definition: Systematics.h:162
RooStats::HistFactory::HistoFactor::~HistoFactor
virtual ~HistoFactor()
Definition: Systematics.h:217
RooStats::HistFactory::HistogramUncertaintyBase::fHistoPathLow
std::string fHistoPathLow
Definition: Systematics.h:189
RooStats::HistFactory::NormFactor::GetConst
bool GetConst() const
Definition: Systematics.h:90
RooStats
Namespace for the RooStats classes.
Definition: Asimov.h:19
RooStats::HistFactory::ShapeFactor::fHasInitialShape
bool fHasInitialShape
Definition: Systematics.h:321
RooStats::HistFactory::StatErrorConfig::fRelErrorThreshold
double fRelErrorThreshold
Definition: Systematics.h:392
RooStats::HistFactory::ShapeFactor::fConstant
bool fConstant
Definition: Systematics.h:317
RooStats::HistFactory::ShapeFactor::GetHistoName
const std::string & GetHistoName() const
Definition: Systematics.h:307
RooStats::HistFactory::StatError::fUseHisto
bool fUseHisto
Definition: Systematics.h:366
RooStats::HistFactory::StatError::SetHistoName
void SetHistoName(const std::string &HistoName)
Definition: Systematics.h:349
RooStats::HistFactory::StatError::fActivate
bool fActivate
Definition: Systematics.h:365
TH1
TH1 is the base class of all histogramm classes in ROOT.
Definition: TH1.h:58
RooStats::HistFactory::StatError::SetHistoPath
void SetHistoPath(const std::string &HistoPath)
Definition: Systematics.h:352
RooStats::HistFactory::HistogramUncertaintyBase::GetHistoPathHigh
const std::string & GetHistoPathHigh() const
Definition: Systematics.h:181
RooStats::HistFactory::ShapeFactor::GetInputFile
const std::string & GetInputFile() const
Definition: Systematics.h:301
RooStats::HistFactory::StatError::SetInputFile
void SetInputFile(const std::string &InputFile)
Definition: Systematics.h:346
RooStats::HistFactory::ShapeSys::operator=
ShapeSys & operator=(const ShapeSys &oth)
Definition: Systematics.h:235
RooStats::HistFactory::ShapeSys::SetHistoPath
void SetHistoPath(const std::string &HistoPath)
Definition: Systematics.h:249
RooStats::HistFactory::ShapeFactor
*Un*constrained bin-by-bin variation of affected histogram.
Definition: Systematics.h:274
RooStats::HistFactory::StatError::GetHistoPath
const std::string & GetHistoPath() const
Definition: Systematics.h:353
RooStats::HistFactory::ShapeSys::fConstraintType
Constraint::Type fConstraintType
Definition: Systematics.h:267
RooStats::HistFactory::NormFactor::fHigh
double fHigh
Definition: Systematics.h:105
RooStats::HistFactory::NormFactor::fConst
bool fConst
Definition: Systematics.h:106
RooStats::HistFactory::NormFactor::SetConst
void SetConst(bool Const=true)
Definition: Systematics.h:89
RooStats::HistFactory::StatError::writeToFile
void writeToFile(const std::string &FileName, const std::string &DirName) override
Definition: Systematics.cxx:308
RooStats::HistFactory::ShapeSys::SetErrorHist
void SetErrorHist(TH1 *hError)
Definition: Systematics.h:259
RooStats::HistFactory::ShapeSys::GetHistoName
std::string GetHistoName() const
Definition: Systematics.h:247
RooStats::HistFactory::ShapeSys::GetHistoPath
std::string GetHistoPath() const
Definition: Systematics.h:250
type
int type
Definition: TGX11.cxx:121
RooStats::HistFactory::ShapeFactor::SetHistoPath
void SetHistoPath(const std::string &HistoPath)
Definition: Systematics.h:309
RooStats::HistFactory::StatErrorConfig::GetConstraintType
Constraint::Type GetConstraintType() const
Definition: Systematics.h:388
RooStats::HistFactory::ShapeFactor::Print
void Print(std::ostream &=std::cout) const override
Definition: Systematics.cxx:216
RooStats::HistFactory::Constraint::Name
std::string Name(Type type)
Definition: Systematics.cxx:27
RooStats::HistFactory::StatError::GetInputFile
const std::string & GetInputFile() const
Definition: Systematics.h:347
RooStats::HistFactory::StatError::Print
void Print(std::ostream &=std::cout) const override
Definition: Systematics.cxx:285
RooStats::HistFactory::Constraint::GetType
Type GetType(const std::string &Name)
Definition: Systematics.cxx:34
TH1.h
RooStats::HistFactory::HistogramUncertaintyBase::fHistoNameHigh
std::string fHistoNameHigh
Definition: Systematics.h:192
RooStats::HistFactory::ShapeSys::GetConstraintType
Constraint::Type GetConstraintType() const
Definition: Systematics.h:264
RooStats::HistFactory::StatError::GetErrorHist
const TH1 * GetErrorHist() const
Definition: Systematics.h:356
HistRef.h
RooStats::HistFactory::NormFactor::SetName
void SetName(const std::string &Name)
Definition: Systematics.h:83
Error
void Error(const char *location, const char *msgfmt,...)
Use this function in case an error occurred.
Definition: TError.cxx:187
RooStats::HistFactory::NormFactor::SetVal
void SetVal(double Val)
Definition: Systematics.h:86