11 #ifndef ROOSTATS_HISTOTOWORKSPACEFACTORY 12 #define ROOSTATS_HISTOTOWORKSPACEFACTORY 32 namespace HistFactory{
34 struct EstimateSummary;
45 std::map<std::string,std::pair<double,double> > systMap,
46 std::vector<std::string>& likelihoodTermNames, std::vector<std::string>& totSystTermNames);
52 void AddPoissonTerms(
RooWorkspace* proto, std::string prefix, std::string obsPrefix, std::string expPrefix,
int lowBin,
int highBin,
53 std::vector<std::string>& likelihoodTermNames);
61 void Customize(
RooWorkspace* proto,
const char* pdfNameChar, std::map<std::string,std::string> renameMap);
63 void EditSyst(
RooWorkspace* proto,
const char* pdfNameChar, std::map<std::string,double> gammaSyst, std::map<std::string,double> uniformSyst, std::map<std::string,double> logNormSyst);
65 void FormatFrameForLikelihood(
RooPlot* frame, std::string XTitle=std::string(
"#sigma / #sigma_{SM}"), std::string YTitle=std::string(
"-log likelihood"));
69 std::vector<std::string> sourceName, std::string prefix, std::string productPrefix, std::string systTerm,
70 int lowBin,
int highBin, std::vector<std::string>& likelihoodTermNames);
77 int lowBin,
int highBin, std::vector<std::string>& syst_x_expectedPrefixNames,
78 std::vector<std::string>& normByNames);
83 void ProcessExpectedHisto(
TH1* hist,
RooWorkspace* proto, std::string prefix, std::string productPrefix, std::string systTerm,
double low,
double high,
int lowBin,
int highBin);
void MakeTotalExpected(RooWorkspace *proto, std::string totName, std::string, std::string, int lowBin, int highBin, std::vector< std::string > &syst_x_expectedPrefixNames, std::vector< std::string > &normByNames)
void EditSyst(RooWorkspace *proto, const char *pdfNameChar, std::map< std::string, double > gammaSyst, std::map< std::string, double > uniformSyst, std::map< std::string, double > logNormSyst)
cout << "in edit, gammamap.size = " << gammaSyst.size() << ", unimap.size = " << uniformSyst.size() << endl;
void SetObsToExpected(RooWorkspace *proto, std::string obsPrefix, std::string expPrefix, int lowBin, int highBin)
HistoToWorkspaceFactory()
A ROOT file is a suite of consecutive data records (TKey instances) with a well defined format...
std::string AddNormFactor(RooWorkspace *, std::string &, std::string &, EstimateSummary &, bool)
void PrintCovarianceMatrix(RooFitResult *result, RooArgSet *params, std::string filename)
void ProcessExpectedHisto(TH1 *hist, RooWorkspace *proto, std::string prefix, std::string productPrefix, std::string systTerm, double low, double high, int lowBin, int highBin)
std::string fFileNamePrefix
#define ClassDef(name, id)
void FormatFrameForLikelihood(RooPlot *frame, std::string XTitle=std::string("#sigma / #sigma_{SM}"), std::string YTitle=std::string("-log likelihood"))
std::vector< std::string > fSystToFix
void LinInterpWithConstraint(RooWorkspace *proto, TH1 *nominal, std::vector< TH1 *> lowHist, std::vector< TH1 *> highHist, std::vector< std::string > sourceName, std::string prefix, std::string productPrefix, std::string systTerm, int lowBin, int highBin, std::vector< std::string > &likelihoodTermNames)
std::stringstream fResultsPrefixStr
void AddEfficiencyTerms(RooWorkspace *proto, std::string prefix, std::string interpName, std::map< std::string, std::pair< double, double > > systMap, std::vector< std::string > &likelihoodTermNames, std::vector< std::string > &totSystTermNames)
void Customize(RooWorkspace *proto, const char *pdfNameChar, std::map< std::string, std::string > renameMap)
void AddMultiVarGaussConstraint(RooWorkspace *proto, std::string prefix, int lowBin, int highBin, std::vector< std::string > &likelihoodTermNames)
A RooPlot is a plot frame and a container for graphics objects within that frame. ...
Namespace for the RooStats classes.
TDirectory * Mkdir(TDirectory *file, std::string name)
TDirectory * Makedirs(TDirectory *file, std::vector< std::string > names)
Describe directory structure in memory.
void AddPoissonTerms(RooWorkspace *proto, std::string prefix, std::string obsPrefix, std::string expPrefix, int lowBin, int highBin, std::vector< std::string > &likelihoodTermNames)
RooWorkspace * MakeCombinedModel(std::vector< std::string >, std::vector< RooWorkspace *>)
void FitModel(RooWorkspace *, std::string, std::string, std::string, bool=false)
RooWorkspace * MakeSingleChannelModel(std::vector< RooStats::HistFactory::EstimateSummary > summary, std::vector< std::string > systToFix, bool doRatio=false)
Mother of all ROOT objects.
std::string FilePrefixStr(std::string)
virtual ~HistoToWorkspaceFactory()
The RooWorkspace is a persistable container for RooFit projects.