27 outputFileName_ = pset.
getParameter<
string>(
"OutputFileName");
30 etMin = parameters_.getParameter<
double>(
"etMin");
31 etMax = parameters_.getParameter<
double>(
"etMax");
32 etBin = parameters_.getParameter<
int>(
"etBin");
34 etaMin = parameters_.getParameter<
double>(
"etaMin");
35 etaMax = parameters_.getParameter<
double>(
"etaMax");
36 etaBin = parameters_.getParameter<
int>(
"etaBin");
37 etaBin2 = parameters_.getParameter<
int>(
"etaBin2");
39 phiMin = parameters_.getParameter<
double>(
"phiMin");
40 phiMax = parameters_.getParameter<
double>(
"phiMax");
41 phiBin = parameters_.getParameter<
int>(
"phiBin");
43 rMin = parameters_.getParameter<
double>(
"rMin");
44 rMax = parameters_.getParameter<
double>(
"rMax");
45 rBin = parameters_.getParameter<
int>(
"rBin");
47 zMin = parameters_.getParameter<
double>(
"zMin");
48 zMax = parameters_.getParameter<
double>(
"zMax");
49 zBin = parameters_.getParameter<
int>(
"zBin");
69 std::string simInfoPathName =
"EgammaV/ConversionValidator/SimulationInfo/";
70 std::string convPathName =
"EgammaV/ConversionValidator/ConversionInfo/";
71 std::string effPathName =
"EgammaV/ConversionValidator/EfficienciesAndFakeRate/";
81 histname =
"convEffVsPhiTwoTracks";
84 histname =
"convEffVsRTwoTracks";
87 histname =
"convEffVsZTwoTracks";
90 histname =
"convEffVsEtTwoTracks";
93 histname =
"convEffVsEtaTwoTracksAndVtxProbGT0";
95 histname =
"convEffVsEtaTwoTracksAndVtxProbGT0005";
97 histname =
"convEffVsRTwoTracksAndVtxProbGT0";
99 histname =
"convEffVsRTwoTracksAndVtxProbGT0005";
103 histname =
"convFakeRateVsEtaTwoTracks";
105 histname =
"convFakeRateVsPhiTwoTracks";
107 histname =
"convFakeRateVsRTwoTracks";
109 histname =
"convFakeRateVsZTwoTracks";
111 histname =
"convFakeRateVsEtTwoTracks";
115 dividePlots(
dbe_->
get(effPathName +
"convEffVsEtaTwoTracks"),
116 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksEta"),
117 dbe_->
get(simInfoPathName +
"h_VisSimConvEta"),
119 dividePlots(
dbe_->
get(effPathName +
"convEffVsPhiTwoTracks"),
120 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksPhi"),
121 dbe_->
get(simInfoPathName +
"h_VisSimConvPhi"),
123 dividePlots(
dbe_->
get(effPathName +
"convEffVsRTwoTracks"),
124 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksR"),
125 dbe_->
get(simInfoPathName +
"h_VisSimConvR"),
127 dividePlots(
dbe_->
get(effPathName +
"convEffVsZTwoTracks"),
128 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksZ"),
129 dbe_->
get(simInfoPathName +
"h_VisSimConvZ"),
131 dividePlots(
dbe_->
get(effPathName +
"convEffVsEtTwoTracks"),
132 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksEt"),
133 dbe_->
get(simInfoPathName +
"h_VisSimConvEt"),
135 dividePlots(
dbe_->
get(effPathName +
"convEffVsEtaTwoTracksAndVtxProbGT0"),
136 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksEtaAndVtxPGT0"),
137 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksEta"),
139 dividePlots(
dbe_->
get(effPathName +
"convEffVsEtaTwoTracksAndVtxProbGT0005"),
140 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksEtaAndVtxPGT0005"),
141 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksEta"),
143 dividePlots(
dbe_->
get(effPathName +
"convEffVsRTwoTracksAndVtxProbGT0"),
144 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksRAndVtxPGT0"),
145 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksR"),
147 dividePlots(
dbe_->
get(effPathName +
"convEffVsRTwoTracksAndVtxProbGT0005"),
148 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksRAndVtxPGT0005"),
149 dbe_->
get(simInfoPathName +
"h_SimConvTwoMTracksR"),
153 dividePlots(
dbe_->
get(effPathName +
"convFakeRateVsEtaTwoTracks"),
154 dbe_->
get(convPathName +
"convEtaAss2"),
155 dbe_->
get(convPathName +
"convEta2"),
157 dividePlots(
dbe_->
get(effPathName +
"convFakeRateVsPhiTwoTracks"),
158 dbe_->
get(convPathName +
"convPhiAss"),
159 dbe_->
get(convPathName +
"convPhi"),
161 dividePlots(
dbe_->
get(effPathName +
"convFakeRateVsRTwoTracks"),
162 dbe_->
get(convPathName +
"convRAss"),
163 dbe_->
get(convPathName +
"convR"),
165 dividePlots(
dbe_->
get(effPathName +
"convFakeRateVsZTwoTracks"),
166 dbe_->
get(convPathName +
"convZAss"),
167 dbe_->
get(convPathName +
"convZ"),
169 dividePlots(
dbe_->
get(effPathName +
"convFakeRateVsEtTwoTracks"),
170 dbe_->
get(convPathName +
"convPtAss"),
171 dbe_->
get(convPathName +
"convPt"),
187 if (dividend ==
nullptr || numerator ==
nullptr || denominator ==
nullptr)
194 else if (type ==
"fakerate")
213 if (dividend ==
nullptr || numerator ==
nullptr)
217 if (denominator != 0) {
219 err =
sqrt(value * (1 - value) / denominator);
T getParameter(std::string const &) const
virtual void runPostprocessing()
void analyze(const edm::Event &, const edm::EventSetup &) override
dqm::legacy::DQMStore * dbe_
void dividePlots(MonitorElement *dividend, MonitorElement *numerator, MonitorElement *denominator, std::string type)
void endRun(const edm::Run &, const edm::EventSetup &) override
MonitorElement * get(std::string const &path) const
get ME from full pathname (e.g. "my/long/dir/my_histo")
virtual int getNbinsX() const
get # of bins in X-axis
virtual double getBinContent(int binx) const
get content of bin (1-D)
ConversionPostprocessing(const edm::ParameterSet &pset)
virtual void setBinContent(int binx, double content)
set content of bin (1-D)
void setCurrentFolder(std::string const &fullpath)
~ConversionPostprocessing() override
bool open(std::string const &filename, bool overwrite=false, std::string const &path="", std::string const &prepend="", OpenRunDirs stripdirs=KeepRunDirs, bool fileMustExist=true)
MonitorElement * book1D(char_string const &name, char_string const &title, int const nchX, double const lowX, double const highX)
Book 1D histogram.
virtual void setBinError(int binx, double error)
set uncertainty on content of bin (1-D)
void save(std::string const &filename, std::string const &path="", std::string const &pattern="", std::string const &rewrite="", uint32_t run=0, uint32_t lumi=0, SaveReferenceTag ref=SaveWithReference, int minStatus=dqm::qstatus::STATUS_OK, std::string const &fileupdate="RECREATE")