11#ifndef HISTFACTORY_SAMPLE_H
12#define HISTFACTORY_SAMPLE_H
37 Sample(std::string Name, std::string HistoName, std::string InputFile, std::string HistoPath=
"");
39 void Print(std::ostream& = std::cout)
const;
40 void PrintXML( std::ofstream& xml )
const;
41 void writeToFile( std::string FileName, std::string DirName );
53 void ActivateStatError( std::string HistoName, std::string InputFile, std::string HistoPath=
"" );
55 void AddOverallSys( std::string Name,
double Low,
double High );
58 void AddNormFactor( std::string
const& Name,
double Val,
double Low,
double High );
61 void AddHistoSys( std::string Name, std::string HistoNameLow, std::string HistoFileLow, std::string HistoPathLow,
62 std::string HistoNameHigh, std::string HistoFileHigh, std::string HistoPathHigh );
65 void AddHistoFactor( std::string Name, std::string HistoNameLow, std::string HistoFileLow, std::string HistoPathLow,
66 std::string HistoNameHigh, std::string HistoFileHigh, std::string HistoPathHigh );
72 void AddShapeSys( std::string Name,
Constraint::Type ConstraintType, std::string HistoName, std::string HistoFile, std::string HistoPath=
"" );
void Error(const char *location, const char *msgfmt,...)
Use this function in case an error occurred.
Internal class wrapping an histogram and managing its content.
Configuration for an *un*constrained, coherent shape variation of affected samples.
Configuration for a constrained, coherent shape variation of affected samples.
Configuration for an un- constrained overall systematic to scale sample normalisations.
Configuration for a constrained overall systematic to scale sample normalisations.
std::unique_ptr< TH1 > fhCountingHist
std::vector< RooStats::HistFactory::OverallSys > & GetOverallSysList()
std::vector< RooStats::HistFactory::OverallSys > fOverallSysList
std::string GetHistoName() const
get histogram name
void SetStatError(RooStats::HistFactory::StatError Error)
void AddShapeSys(std::string Name, Constraint::Type ConstraintType, std::string HistoName, std::string HistoFile, std::string HistoPath="")
void AddOverallSys(std::string Name, double Low, double High)
std::string GetName() const
get name of sample
void writeToFile(std::string FileName, std::string DirName)
const TH1 * GetHisto() const
std::vector< RooStats::HistFactory::HistoFactor > fHistoFactorList
void SetInputFile(const std::string &InputFile)
set input ROOT file
void SetValue(double Val)
RooStats::HistFactory::StatError fStatError
Properties.
void SetChannelName(const std::string &ChannelName)
set name of associated channel
void AddNormFactor(std::string const &Name, double Val, double Low, double High)
const RooStats::HistFactory::StatError & GetStatError() const
void SetHistoName(const std::string &HistoName)
set histogram name
std::vector< RooStats::HistFactory::NormFactor > fNormFactorList
std::vector< RooStats::HistFactory::HistoSys > fHistoSysList
std::string fChannelName
The Name of the parent channel.
void SetHisto(TH1 *histo)
void Print(std::ostream &=std::cout) const
const std::vector< RooStats::HistFactory::HistoFactor > & GetHistoFactorList() const
const std::vector< RooStats::HistFactory::HistoSys > & GetHistoSysList() const
Sample & operator=(const Sample &other)
bool HasStatError() const
std::string GetHistoPath() const
get histogram path
std::vector< RooStats::HistFactory::ShapeSys > fShapeSysList
void SetNormalizeByTheory(bool norm)
defines whether the normalization scale with luminosity
const std::vector< RooStats::HistFactory::ShapeFactor > & GetShapeFactorList() const
RooStats::HistFactory::StatError & GetStatError()
void AddHistoFactor(std::string Name, std::string HistoNameLow, std::string HistoFileLow, std::string HistoPathLow, std::string HistoNameHigh, std::string HistoFileHigh, std::string HistoPathHigh)
std::vector< RooStats::HistFactory::ShapeFactor > & GetShapeFactorList()
void SetName(const std::string &Name)
set name of sample
std::vector< RooStats::HistFactory::HistoFactor > & GetHistoFactorList()
void SetHistoPath(const std::string &HistoPath)
set histogram path
std::string GetChannelName() const
get name of associated channel
std::vector< RooStats::HistFactory::NormFactor > & GetNormFactorList()
std::string GetInputFile() const
get input ROOT file
const std::vector< RooStats::HistFactory::OverallSys > & GetOverallSysList() const
std::vector< RooStats::HistFactory::HistoSys > & GetHistoSysList()
bool GetNormalizeByTheory() const
does the normalization scale with luminosity
HistRef fhNominal
The Nominal Shape.
void AddShapeFactor(std::string Name)
std::vector< RooStats::HistFactory::ShapeFactor > fShapeFactorList
const std::vector< RooStats::HistFactory::NormFactor > & GetNormFactorList() const
std::vector< RooStats::HistFactory::ShapeSys > & GetShapeSysList()
void AddHistoSys(std::string Name, std::string HistoNameLow, std::string HistoFileLow, std::string HistoPathLow, std::string HistoNameHigh, std::string HistoFileHigh, std::string HistoPathHigh)
void PrintXML(std::ofstream &xml) const
const std::vector< RooStats::HistFactory::ShapeSys > & GetShapeSysList() const
*Un*constrained bin-by-bin variation of affected histogram.
Constrained bin-by-bin variation of affected histogram.
Statistical error of Monte Carlo predictions.
TH1 is the base class of all histogram classes in ROOT.
const char * GetName() const override
Returns name of object.
Namespace for the RooStats classes.