Go to the documentation of this file.00001 #ifndef FitHist_h
00002 #define FitHist_h
00003
00004 #include "Validation/RecoJets/interface/CompHist.h"
00005 #include "Validation/RecoJets/interface/CompMethods.h"
00006
00007
00008 class FitHist : public CompHist{
00009
00010 public:
00011
00012 enum EvalType{kStabilizedGauss, kHistogramMean, kMaximalValue, kQuantile};
00013
00014 public:
00015
00016 FitHist():CompHist(false){};
00017 FitHist(bool verbose):CompHist(verbose){};
00018
00019 virtual ~FitHist(){};
00020
00021
00022 void fitAndDrawPs();
00023 void fitAndDrawEps();
00024 void fillTargetHistograms();
00025 void writeFitOutput();
00026
00027 protected:
00028
00029
00030 void configBlockFit(ConfigFile&);
00031
00032
00033 bool checkTargetHistList();
00034 bool isInFitTargetList(std::string&);
00035 TH1F& findFitHistogram(const TObjArray&, TString&, TString&, int&);
00036 TH1F& findTargetHistogram(const TObjArray&, TString&, TString&, TString&);
00037 double normalize(TString&, double);
00038 void fillTargetHistogram(std::string&);
00039 void fillTargetHistogramBin(TH1F&, TH1F&, int);
00040 void fillTargetHistogramBin(TH1F&, TH1F&, int, TString&, Quantile&);
00041 void fillTargetHistogramBin(TH1F&, TH1F&, int, TString&, MaximalValue&);
00042 void fillTargetHistogramBin(TH1F&, TH1F&, int, TString&, HistogramMean&);
00043 void fillTargetHistogramBin(TH1F&, TH1F&, int, TString&, StabilizedGauss&);
00044 void setFitHistogramAxes(TH1F&, int);
00045 void addBinLabelToFitHist(const TObjArray&, int&, TString&, TString&);
00046 void addParLabelToFitHist(const TH1F&);
00047
00048 protected:
00049
00050
00051
00052
00053
00054
00055 std::vector<std::string> targetHistList_;
00056
00057
00058 std::vector<int> axesIndex_;
00059 std::vector<std::string> xAxesFit_;
00060 std::vector<std::string> yAxesFit_;
00061
00062
00063
00064 int evalType_;
00065 int fitFuncType_;
00066 std::string fitFuncName_;
00067 std::string fitFuncTitle_;
00068 double fitFuncLowerBound_;
00069 double fitFuncUpperBound_;
00070 };
00071
00072 #endif