CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ElectronMcFakeValidator.cc
Go to the documentation of this file.
1 
2 // user include files
4 
6 
8 
19 
22 
25 
31 
32 #include "CLHEP/Units/GlobalPhysicalConstants.h"
33 #include "TMath.h"
34 #include "TFile.h"
35 #include "TH1F.h"
36 #include "TH1I.h"
37 #include "TH2F.h"
38 #include "TProfile.h"
39 #include "TTree.h"
40 #include <vector>
41 #include <iostream>
42 
43 using namespace reco;
44 
46  electronCollection_ = consumes<reco::GsfElectronCollection>(conf.getParameter<edm::InputTag>("electronCollection"));
48  consumes<reco::GsfElectronCollection>(conf.getParameter<edm::InputTag>("electronCollectionEndcaps"));
50  consumes<reco::GsfElectronCoreCollection>(conf.getParameter<edm::InputTag>("electronCoreCollection"));
52  consumes<reco::GsfTrackCollection>(conf.getParameter<edm::InputTag>("electronTrackCollection"));
54  consumes<reco::ElectronSeedCollection>(conf.getParameter<edm::InputTag>("electronSeedCollection"));
56  consumes<reco::GenJetCollection>(conf.getParameter<edm::InputTag>("matchingObjectCollection"));
58  consumes<reco::VertexCollection>(conf.getParameter<edm::InputTag>("offlinePrimaryVertices"));
59 
60  beamSpotTag_ = consumes<reco::BeamSpot>(conf.getParameter<edm::InputTag>("beamSpot"));
61  readAOD_ = conf.getParameter<bool>("readAOD");
62 
63  isoFromDepsTk03Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsTk03"));
64  isoFromDepsTk04Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsTk04"));
66  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalFull03"));
68  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalFull04"));
70  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalReduced03"));
72  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalReduced04"));
73  isoFromDepsHcal03Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsHcal03"));
74  isoFromDepsHcal04Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsHcal04"));
75 
76  maxPt_ = conf.getParameter<double>("MaxPt");
77  maxAbsEta_ = conf.getParameter<double>("MaxAbsEta");
78  deltaR2_ = conf.getParameter<double>("DeltaR") * conf.getParameter<double>("DeltaR");
79  inputFile_ = conf.getParameter<std::string>("InputFile");
80  outputFile_ = conf.getParameter<std::string>("OutputFile");
81  inputInternalPath_ = conf.getParameter<std::string>("InputFolderName");
82  outputInternalPath_ = conf.getParameter<std::string>("OutputFolderName");
83 
84  // histos bining and limits
85 
86  edm::ParameterSet histosSet = conf.getParameter<edm::ParameterSet>("histosCfg");
87 
88  xyz_nbin = histosSet.getParameter<int>("Nbinxyz");
89 
90  p_nbin = histosSet.getParameter<int>("Nbinp");
91  p2D_nbin = histosSet.getParameter<int>("Nbinp2D");
92  p_max = histosSet.getParameter<double>("Pmax");
93 
94  pt_nbin = histosSet.getParameter<int>("Nbinpt");
95  pt2D_nbin = histosSet.getParameter<int>("Nbinpt2D");
96  pteff_nbin = histosSet.getParameter<int>("Nbinpteff");
97  pt_max = histosSet.getParameter<double>("Ptmax");
98 
99  fhits_nbin = histosSet.getParameter<int>("Nbinfhits");
100  fhits_max = histosSet.getParameter<double>("Fhitsmax");
101 
102  lhits_nbin = histosSet.getParameter<int>("Nbinlhits");
103  lhits_max = histosSet.getParameter<double>("Lhitsmax");
104 
105  eop_nbin = histosSet.getParameter<int>("Nbineop");
106  eop2D_nbin = histosSet.getParameter<int>("Nbineop2D");
107  eop_max = histosSet.getParameter<double>("Eopmax");
108  eopmaxsht = histosSet.getParameter<double>("Eopmaxsht");
109 
110  eta_nbin = histosSet.getParameter<int>("Nbineta");
111  eta2D_nbin = histosSet.getParameter<int>("Nbineta2D");
112  eta_min = histosSet.getParameter<double>("Etamin");
113  eta_max = histosSet.getParameter<double>("Etamax");
114 
115  deta_nbin = histosSet.getParameter<int>("Nbindeta");
116  deta_min = histosSet.getParameter<double>("Detamin");
117  deta_max = histosSet.getParameter<double>("Detamax");
118 
119  detamatch_nbin = histosSet.getParameter<int>("Nbindetamatch");
120  detamatch2D_nbin = histosSet.getParameter<int>("Nbindetamatch2D");
121  detamatch_min = histosSet.getParameter<double>("Detamatchmin");
122  detamatch_max = histosSet.getParameter<double>("Detamatchmax");
123 
124  phi_nbin = histosSet.getParameter<int>("Nbinphi");
125  phi2D_nbin = histosSet.getParameter<int>("Nbinphi2D");
126  phi_min = histosSet.getParameter<double>("Phimin");
127  phi_max = histosSet.getParameter<double>("Phimax");
128 
129  dphi_nbin = histosSet.getParameter<int>("Nbindphi");
130  dphi_min = histosSet.getParameter<double>("Dphimin");
131  dphi_max = histosSet.getParameter<double>("Dphimax");
132 
133  dphimatch_nbin = histosSet.getParameter<int>("Nbindphimatch");
134  dphimatch2D_nbin = histosSet.getParameter<int>("Nbindphimatch2D");
135  dphimatch_min = histosSet.getParameter<double>("Dphimatchmin");
136  dphimatch_max = histosSet.getParameter<double>("Dphimatchmax");
137 
138  mee_nbin = histosSet.getParameter<int>("Nbinmee");
139  mee_min = histosSet.getParameter<double>("Meemin");
140  mee_max = histosSet.getParameter<double>("Meemax");
141 
142  hoe_nbin = histosSet.getParameter<int>("Nbinhoe");
143  hoe_min = histosSet.getParameter<double>("Hoemin");
144  hoe_max = histosSet.getParameter<double>("Hoemax");
145 
146  popmatching_nbin = histosSet.getParameter<int>("Nbinpopmatching");
147  popmatching_min = histosSet.getParameter<double>("Popmatchingmin");
148  popmatching_max = histosSet.getParameter<double>("Popmatchingmax");
149 
150  set_EfficiencyFlag = histosSet.getParameter<bool>("EfficiencyFlag");
151  set_StatOverflowFlag = histosSet.getParameter<bool>("StatOverflowFlag");
152 
153  opv_nbin = histosSet.getParameter<int>("NbinOPV");
154  opv_min = histosSet.getParameter<double>("OPV_min");
155  opv_max = histosSet.getParameter<double>("OPV_max");
156 
157  ele_nbin = histosSet.getParameter<int>("NbinELE");
158  ele_min = histosSet.getParameter<double>("ELE_min");
159  ele_max = histosSet.getParameter<double>("ELE_max");
160 
161  core_nbin = histosSet.getParameter<int>("NbinCORE");
162  core_min = histosSet.getParameter<double>("CORE_min");
163  core_max = histosSet.getParameter<double>("CORE_max");
164 
165  track_nbin = histosSet.getParameter<int>("NbinTRACK");
166  track_min = histosSet.getParameter<double>("TRACK_min");
167  track_max = histosSet.getParameter<double>("TRACK_max");
168 
169  seed_nbin = histosSet.getParameter<int>("NbinSEED");
170  seed_min = histosSet.getParameter<double>("SEED_min");
171  seed_max = histosSet.getParameter<double>("SEED_max");
172 
173  // so to please coverity
174  h1_matchingObjectNum = nullptr;
175  h1_recEleNum_ = nullptr;
176  h1_recCoreNum_ = nullptr;
177  h1_recTrackNum_ = nullptr;
178  h1_recSeedNum_ = nullptr;
179  h1_recOfflineVertices_ = nullptr;
180 
181  h1_matchingObjectEta = nullptr;
182  h1_matchingObjectAbsEta = nullptr;
183  h1_matchingObjectP = nullptr;
184  h1_matchingObjectPt = nullptr;
185  h1_matchingObjectPhi = nullptr;
186  h1_matchingObjectZ = nullptr;
187 
188  h1_ele_EoverP_all = nullptr;
189  h1_ele_EseedOP_all = nullptr;
190  h1_ele_EoPout_all = nullptr;
191  h1_ele_EeleOPout_all = nullptr;
192  h1_ele_dEtaSc_propVtx_all = nullptr;
193  h1_ele_dPhiSc_propVtx_all = nullptr;
194  h1_ele_dEtaCl_propOut_all = nullptr;
195  h1_ele_dPhiCl_propOut_all = nullptr;
196  h1_ele_TIP_all = nullptr;
197  h1_ele_HoE_all = nullptr;
198  h1_ele_vertexEta_all = nullptr;
199  h1_ele_vertexPt_all = nullptr;
200  h1_ele_mee_all = nullptr;
201  h1_ele_mee_os = nullptr;
202 
203  h2_ele_E2mnE1vsMee_all = nullptr;
204  h2_ele_E2mnE1vsMee_egeg_all = nullptr;
205 
211 
212  h1_ele_charge = nullptr;
213  h2_ele_chargeVsEta = nullptr;
214  h2_ele_chargeVsPhi = nullptr;
215  h2_ele_chargeVsPt = nullptr;
216  h1_ele_vertexP = nullptr;
217  h1_ele_vertexPt = nullptr;
218  h2_ele_vertexPtVsEta = nullptr;
219  h2_ele_vertexPtVsPhi = nullptr;
220  h1_ele_vertexEta = nullptr;
221  h2_ele_vertexEtaVsPhi = nullptr;
222  h1_ele_vertexAbsEta = nullptr;
223  h1_ele_vertexPhi = nullptr;
224  h1_ele_vertexX = nullptr;
225  h1_ele_vertexY = nullptr;
226  h1_ele_vertexZ = nullptr;
227  h1_ele_vertexTIP = nullptr;
228  h2_ele_vertexTIPVsEta = nullptr;
229  h2_ele_vertexTIPVsPhi = nullptr;
230  h2_ele_vertexTIPVsPt = nullptr;
231 
232  h1_ele_PoPmatchingObject = nullptr;
238 
248 
249  h1_scl_En_ = nullptr;
252  h1_scl_Et_ = nullptr;
253  h2_scl_EtVsEta_ = nullptr;
254  h2_scl_EtVsPhi_ = nullptr;
255  h2_scl_EtaVsPhi_ = nullptr;
256  h1_scl_Eta_ = nullptr;
257  h1_scl_Phi_ = nullptr;
258 
259  h1_scl_SigIEtaIEta_ = nullptr;
260  h1_scl_SigIEtaIEta_barrel_ = nullptr;
261  h1_scl_SigIEtaIEta_endcaps_ = nullptr;
265  h1_scl_E1x5_ = nullptr;
266  h1_scl_E1x5_barrel_ = nullptr;
267  h1_scl_E1x5_endcaps_ = nullptr;
268  h1_scl_E2x5max_ = nullptr;
269  h1_scl_E2x5max_barrel_ = nullptr;
270  h1_scl_E2x5max_endcaps_ = nullptr;
271  h1_scl_E5x5_ = nullptr;
272  h1_scl_E5x5_barrel_ = nullptr;
273  h1_scl_E5x5_endcaps_ = nullptr;
274 
275  h1_ele_ambiguousTracks = nullptr;
276  h2_ele_ambiguousTracksVsEta = nullptr;
277  h2_ele_ambiguousTracksVsPhi = nullptr;
278  h2_ele_ambiguousTracksVsPt = nullptr;
279  h1_ele_foundHits = nullptr;
280  h1_ele_foundHits_barrel = nullptr;
281  h1_ele_foundHits_endcaps = nullptr;
282  h2_ele_foundHitsVsEta = nullptr;
283  h2_ele_foundHitsVsPhi = nullptr;
284  h2_ele_foundHitsVsPt = nullptr;
285  h1_ele_lostHits = nullptr;
286  h1_ele_lostHits_barrel = nullptr;
287  h1_ele_lostHits_endcaps = nullptr;
288  h2_ele_lostHitsVsEta = nullptr;
289  h2_ele_lostHitsVsPhi = nullptr;
290  h2_ele_lostHitsVsPt = nullptr;
291  h1_ele_chi2 = nullptr;
292  h1_ele_chi2_barrel = nullptr;
293  h1_ele_chi2_endcaps = nullptr;
294  h2_ele_chi2VsEta = nullptr;
295  h2_ele_chi2VsPhi = nullptr;
296  h2_ele_chi2VsPt = nullptr;
297 
298  h1_ele_PinMnPout = nullptr;
299  h1_ele_PinMnPout_mode = nullptr;
300  h2_ele_PinMnPoutVsEta_mode = nullptr;
301  h2_ele_PinMnPoutVsPhi_mode = nullptr;
302  h2_ele_PinMnPoutVsPt_mode = nullptr;
303  h2_ele_PinMnPoutVsE_mode = nullptr;
304  h2_ele_PinMnPoutVsChi2_mode = nullptr;
305 
306  h1_ele_outerP = nullptr;
307  h1_ele_outerP_mode = nullptr;
308  h2_ele_outerPVsEta_mode = nullptr;
309  h1_ele_outerPt = nullptr;
310  h1_ele_outerPt_mode = nullptr;
311  h2_ele_outerPtVsEta_mode = nullptr;
312  h2_ele_outerPtVsPhi_mode = nullptr;
313  h2_ele_outerPtVsPt_mode = nullptr;
314  h1_ele_EoP = nullptr;
315  h1_ele_EoP_barrel = nullptr;
316  h1_ele_EoP_endcaps = nullptr;
317  h2_ele_EoPVsEta = nullptr;
318  h2_ele_EoPVsPhi = nullptr;
319  h2_ele_EoPVsE = nullptr;
320  h1_ele_EseedOP = nullptr;
321  h1_ele_EseedOP_barrel = nullptr;
322  h1_ele_EseedOP_endcaps = nullptr;
323  h2_ele_EseedOPVsEta = nullptr;
324  h2_ele_EseedOPVsPhi = nullptr;
325  h2_ele_EseedOPVsE = nullptr;
326  h1_ele_EoPout = nullptr;
327  h1_ele_EoPout_barrel = nullptr;
328  h1_ele_EoPout_endcaps = nullptr;
329  h2_ele_EoPoutVsEta = nullptr;
330  h2_ele_EoPoutVsPhi = nullptr;
331  h2_ele_EoPoutVsE = nullptr;
332  h1_ele_EeleOPout = nullptr;
333  h1_ele_EeleOPout_barrel = nullptr;
334  h1_ele_EeleOPout_endcaps = nullptr;
335  h2_ele_EeleOPoutVsEta = nullptr;
336  h2_ele_EeleOPoutVsPhi = nullptr;
337  h2_ele_EeleOPoutVsE = nullptr;
338 
339  h1_ele_dEtaSc_propVtx = nullptr;
342  h2_ele_dEtaScVsEta_propVtx = nullptr;
343  h2_ele_dEtaScVsPhi_propVtx = nullptr;
344  h2_ele_dEtaScVsPt_propVtx = nullptr;
345  h1_ele_dPhiSc_propVtx = nullptr;
348  h2_ele_dPhiScVsEta_propVtx = nullptr;
349  h2_ele_dPhiScVsPhi_propVtx = nullptr;
350  h2_ele_dPhiScVsPt_propVtx = nullptr;
351  h1_ele_dEtaCl_propOut = nullptr;
354  h2_ele_dEtaClVsEta_propOut = nullptr;
355  h2_ele_dEtaClVsPhi_propOut = nullptr;
356  h2_ele_dEtaClVsPt_propOut = nullptr;
357  h1_ele_dPhiCl_propOut = nullptr;
360  h2_ele_dPhiClVsEta_propOut = nullptr;
361  h2_ele_dPhiClVsPhi_propOut = nullptr;
362  h2_ele_dPhiClVsPt_propOut = nullptr;
363  h1_ele_dEtaEleCl_propOut = nullptr;
369  h1_ele_dPhiEleCl_propOut = nullptr;
375 
376  h1_ele_seed_subdet2_ = nullptr;
377  h1_ele_seed_mask_ = nullptr;
378  h1_ele_seed_mask_bpix_ = nullptr;
379  h1_ele_seed_mask_fpix_ = nullptr;
380  h1_ele_seed_mask_tec_ = nullptr;
381  h1_ele_seed_dphi2_ = nullptr;
382  h2_ele_seed_dphi2VsEta_ = nullptr;
383  h2_ele_seed_dphi2VsPt_ = nullptr;
384  h1_ele_seed_dphi2pos_ = nullptr;
385  h2_ele_seed_dphi2posVsEta_ = nullptr;
386  h2_ele_seed_dphi2posVsPt_ = nullptr;
387  h1_ele_seed_drz2_ = nullptr;
388  h2_ele_seed_drz2VsEta_ = nullptr;
389  h2_ele_seed_drz2VsPt_ = nullptr;
390  h1_ele_seed_drz2pos_ = nullptr;
391  h2_ele_seed_drz2posVsEta_ = nullptr;
392  h2_ele_seed_drz2posVsPt_ = nullptr;
393 
394  h1_ele_classes = nullptr;
395  h1_ele_eta = nullptr;
396  h1_ele_eta_golden = nullptr;
397  h1_ele_eta_bbrem = nullptr;
398  h1_ele_eta_narrow = nullptr;
399  h1_ele_eta_shower = nullptr;
400 
401  h1_ele_HoE = nullptr;
402  h1_ele_HoE_barrel = nullptr;
403  h1_ele_HoE_endcaps = nullptr;
404  h1_ele_HoE_fiducial = nullptr;
405  h2_ele_HoEVsEta = nullptr;
406  h2_ele_HoEVsPhi = nullptr;
407  h2_ele_HoEVsE = nullptr;
408  h1_scl_ESFrac_endcaps = nullptr;
409 
410  h1_ele_fbrem = nullptr;
411  p1_ele_fbremVsEta_mode = nullptr;
412  p1_ele_fbremVsEta_mean = nullptr;
413  h1_ele_superclusterfbrem = nullptr;
416  h2_ele_PinVsPoutGolden_mode = nullptr;
418  h2_ele_PinVsPoutGolden_mean = nullptr;
428 
429  h1_ele_mva = nullptr;
430  h1_ele_mva_isolated = nullptr;
431  h1_ele_provenance = nullptr;
432 
433  h1_ele_tkSumPt_dr03 = nullptr;
434  h1_ele_tkSumPt_dr03_barrel = nullptr;
435  h1_ele_tkSumPt_dr03_endcaps = nullptr;
436  h1_ele_ecalRecHitSumEt_dr03 = nullptr;
443  h1_ele_tkSumPt_dr04 = nullptr;
444  h1_ele_tkSumPt_dr04_barrel = nullptr;
445  h1_ele_tkSumPt_dr04_endcaps = nullptr;
446  h1_ele_ecalRecHitSumEt_dr04 = nullptr;
453 
454  h1_ele_convFlags = nullptr;
455  h1_ele_convFlags_all = nullptr;
456  h1_ele_convDist = nullptr;
457  h1_ele_convDist_all = nullptr;
458  h1_ele_convDcot = nullptr;
459  h1_ele_convDcot_all = nullptr;
460  h1_ele_convRadius = nullptr;
461  h1_ele_convRadius_all = nullptr;
462 }
463 
466 
467  setBookIndex(-1);
468  setBookPrefix("h");
471 
472  // matching object type
473  std::string matchingObjectType;
474  matchingObjectType = "GenJet";
475 
476  std::string htitle = "# " + matchingObjectType + "s", xtitle = "N_{" + matchingObjectType + "}";
477  h1_matchingObjectNum = bookH1withSumw2(iBooker, "matchingObjectNum", htitle, fhits_nbin, 0., fhits_max, xtitle);
478 
479  // rec event collections sizes
480  h1_recEleNum_ = bookH1(iBooker, "recEleNum", "# rec electrons", ele_nbin, ele_min, ele_max, "N_{ele}");
481  h1_recCoreNum_ = bookH1(iBooker, "recCoreNum", "# rec electron cores", core_nbin, core_min, core_max, "N_{core}");
482  h1_recTrackNum_ = bookH1(iBooker, "recTrackNum", "# rec gsf tracks", track_nbin, track_min, track_max, "N_{track}");
483  h1_recSeedNum_ = bookH1(iBooker, "recSeedNum", "# rec electron seeds", seed_nbin, seed_min, seed_max, "N_{seed}");
485  iBooker, "recOfflineVertices", "# rec Offline Primary Vertices", opv_nbin, opv_min, opv_max, "N_{Vertices}");
486 
487  // mc
489  bookH1withSumw2(iBooker, "matchingObject_eta", matchingObjectType + " #eta", eta_nbin, eta_min, eta_max, "#eta");
491  bookH1withSumw2(iBooker, "matchingObject_abseta", matchingObjectType + " |#eta|", eta_nbin / 2, 0., eta_max);
493  bookH1withSumw2(iBooker, "matchingObject_P", matchingObjectType + " p", p_nbin, 0., p_max, "p (GeV/c)");
495  bookH1withSumw2(iBooker, "matchingObject_Pt", matchingObjectType + " pt", pteff_nbin, 5., pt_max);
497  bookH1withSumw2(iBooker, "matchingObject_phi", matchingObjectType + " phi", phi_nbin, phi_min, phi_max);
498  h1_matchingObjectZ = bookH1withSumw2(iBooker, "matchingObject_z", matchingObjectType + " z", xyz_nbin, -25, 25);
499 
500  setBookPrefix("h_ele");
501 
502  // all electrons
504  "EoverP_all",
505  "ele E/P_{vertex}, all reco electrons",
506  eop_nbin,
507  0.,
508  eop_max,
509  "E/P_{vertex}",
510  "Events",
511  "ELE_LOGY E1 P");
513  "EseedOP_all",
514  "ele E_{seed}/P_{vertex}, all reco electrons",
515  eop_nbin,
516  0.,
517  eop_max,
518  "E_{seed}/P_{vertex}",
519  "Events",
520  "ELE_LOGY E1 P");
522  "EoPout_all",
523  "ele E_{seed}/P_{out}, all reco electrons",
524  eop_nbin,
525  0.,
526  eop_max,
527  "E_{seed}/P_{out}",
528  "Events",
529  "ELE_LOGY E1 P");
531  "EeleOPout_all",
532  "ele E_{ele}/P_{out}, all reco electrons",
533  eop_nbin,
534  0.,
535  eop_max,
536  "E_{ele}/P_{out}",
537  "Events",
538  "ELE_LOGY E1 P");
540  "dEtaSc_propVtx_all",
541  "ele #eta_{sc} - #eta_{tr}, prop from vertex, all reco electrons",
545  "#eta_{sc} - #eta_{tr}",
546  "Events",
547  "ELE_LOGY E1 P");
549  "dPhiSc_propVtx_all",
550  "ele #phi_{sc} - #phi_{tr}, prop from vertex, all reco electrons",
554  "#phi_{sc} - #phi_{tr} (rad)",
555  "Events",
556  "ELE_LOGY E1 P");
558  "dEtaCl_propOut_all",
559  "ele #eta_{cl} - #eta_{tr}, prop from outermost, all reco electrons",
563  "#eta_{sc} - #eta_{tr}",
564  "Events",
565  "ELE_LOGY E1 P");
567  "dPhiCl_propOut_all",
568  "ele #phi_{cl} - #phi_{tr}, prop from outermost, all reco electrons",
572  "#phi_{sc} - #phi_{tr} (rad)",
573  "Events",
574  "ELE_LOGY E1 P");
576  "TIP_all",
577  "ele vertex transverse radius, all reco electrons",
578  100,
579  0.,
580  0.2,
581  "r_{T} (cm)",
582  "Events",
583  "ELE_LOGY E1 P");
585  "HoE_all",
586  "ele hadronic energy / em energy, all reco electrons",
587  hoe_nbin,
588  hoe_min,
589  hoe_max,
590  "H/E",
591  "Events",
592  "ELE_LOGY E1 P");
594  "HoE_bc_all",
595  "ele hadronic energy / em energy, all reco electrons, behind cluster",
596  hoe_nbin,
597  hoe_min,
598  hoe_max,
599  "H/E",
600  "Events",
601  "ELE_LOGY E1 P");
603  "vertexEta_all",
604  "ele eta, all reco electrons",
605  eta_nbin,
606  eta_min,
607  eta_max,
608  "",
609  "Events",
610  "ELE_LOGY E1 P");
612  iBooker, "vertexPt_all", "ele p_{T}, all reco electrons", pteff_nbin, 5., pt_max, "", "Events", "ELE_LOGY E1 P");
614  "mee_all",
615  "ele pairs invariant mass, all reco electrons",
616  mee_nbin,
617  mee_min,
618  mee_max,
619  "m_{ee} (GeV/c^{2})");
620  h1_ele_mee_os = bookH1withSumw2(iBooker,
621  "mee_os",
622  "ele pairs invariant mass, opp. sign",
623  mee_nbin,
624  mee_min,
625  mee_max,
626  "m_{e^{+}e^{-}} (GeV/c^{2})");
627 
628  // duplicates
629  h2_ele_E2mnE1vsMee_all = bookH2(iBooker,
630  "E2mnE1vsMee_all",
631  "E2 - E1 vs ele pairs invariant mass, all electrons",
632  mee_nbin,
633  mee_min,
634  mee_max,
635  100,
636  -50.,
637  50.,
638  "m_{e^{+}e^{-}} (GeV/c^{2})",
639  "E2 - E1 (GeV)");
641  "E2mnE1vsMee_egeg_all",
642  "E2 - E1 vs ele pairs invariant mass, ecal driven pairs, all electrons",
643  mee_nbin,
644  mee_min,
645  mee_max,
646  100,
647  -50.,
648  50.,
649  "m_{e^{+}e^{-}} (GeV/c^{2})",
650  "E2 - E1 (GeV)");
651 
652  // matched electrons
653 
654  htitle = "Efficiency vs matching " + matchingObjectType + " ";
656  bookH1withSumw2(iBooker, "matchingObjectEta_matched", htitle + "#eta", eta_nbin, eta_min, eta_max);
658  bookH1withSumw2(iBooker, "matchingObjectAbsEta_matched", htitle + "|#eta|", eta_nbin / 2, 0., eta_max);
660  bookH1(iBooker, "matchingObjectPt_matched", htitle + "p_{T}", pteff_nbin, 5., pt_max);
662  bookH1withSumw2(iBooker, "matchingObjectPhi_matched", htitle + "phi", phi_nbin, phi_min, phi_max);
663  h1_ele_matchingObjectZ_matched = bookH1withSumw2(iBooker, "matchingObjectZ_matched", htitle + "z", xyz_nbin, -25, 25);
664 
665  h1_ele_charge = bookH1withSumw2(iBooker, "charge", "ele charge", 5, -2.5, 2.5, "charge");
666  h2_ele_chargeVsEta = bookH2(iBooker, "chargeVsEta", "ele charge vs eta", eta2D_nbin, eta_min, eta_max, 5, -2., 2.);
667  h2_ele_chargeVsPhi = bookH2(iBooker, "chargeVsPhi", "ele charge vs phi", phi2D_nbin, phi_min, phi_max, 5, -2., 2.);
668  h2_ele_chargeVsPt = bookH2(iBooker, "chargeVsPt", "ele charge vs pt", pt_nbin, 0., 100., 5, -2., 2.);
669  h1_ele_vertexP = bookH1withSumw2(iBooker, "vertexP", "ele momentum", p_nbin, 0., p_max, "p_{vertex} (GeV/c)");
671  bookH1withSumw2(iBooker, "vertexPt", "ele transverse momentum", pt_nbin, 0., pt_max, "p_{T vertex} (GeV/c)");
673  iBooker, "vertexPtVsEta", "ele transverse momentum vs eta", eta2D_nbin, eta_min, eta_max, pt2D_nbin, 0., pt_max);
675  iBooker, "vertexPtVsPhi", "ele transverse momentum vs phi", phi2D_nbin, phi_min, phi_max, pt2D_nbin, 0., pt_max);
676  h1_ele_vertexEta = bookH1withSumw2(iBooker, "vertexEta", "ele momentum eta", eta_nbin, eta_min, eta_max, "#eta");
678  iBooker, "vertexEtaVsPhi", "ele momentum eta vs phi", eta2D_nbin, eta_min, eta_max, phi2D_nbin, phi_min, phi_max);
680  bookH1withSumw2(iBooker, "vertexPhi", "ele momentum #phi", phi_nbin, phi_min, phi_max, "#phi (rad)");
681  h1_ele_vertexX = bookH1withSumw2(iBooker, "vertexX", "ele vertex x", xyz_nbin, -0.6, 0.6, "x (cm)");
682  h1_ele_vertexY = bookH1withSumw2(iBooker, "vertexY", "ele vertex y", xyz_nbin, -0.6, 0.6, "y (cm)");
683  h1_ele_vertexZ = bookH1withSumw2(iBooker, "vertexZ", "ele vertex z", xyz_nbin, -25, 25, "z (cm)");
685  "vertexTIP",
686  "ele transverse impact parameter (wrt gen vtx)",
687  90,
688  0.,
689  0.15,
690  "TIP (cm)",
691  "Events",
692  "ELE_LOGY E1 P");
693  h2_ele_vertexTIPVsEta = bookH2(iBooker,
694  "vertexTIPVsEta",
695  "ele transverse impact parameter (wrt gen vtx) vs eta",
696  eta2D_nbin,
697  eta_min,
698  eta_max,
699  45,
700  0.,
701  0.15,
702  "#eta",
703  "TIP (cm)");
704  h2_ele_vertexTIPVsPhi = bookH2(iBooker,
705  "vertexTIPVsPhi",
706  "ele transverse impact parameter (wrt gen vtx) vs phi",
707  phi2D_nbin,
708  phi_min,
709  phi_max,
710  45,
711  0.,
712  0.15,
713  "#phi (rad)",
714  "TIP (cm)");
715  h2_ele_vertexTIPVsPt = bookH2(iBooker,
716  "vertexTIPVsPt",
717  "ele transverse impact parameter (wrt gen vtx) vs transverse momentum",
718  pt2D_nbin,
719  0.,
720  pt_max,
721  45,
722  0.,
723  0.15,
724  "p_{T} (GeV/c)",
725  "TIP (cm)");
726 
727  htitle = "Electron / Matching " + matchingObjectType + ", momemtum";
728  xtitle = "P / P_{" + matchingObjectType + "}";
730  bookH1withSumw2(iBooker, "PoPmatchingObject", htitle, popmatching_nbin, popmatching_min, popmatching_max, xtitle);
732  "PoPmatchingObjectVsEta",
733  htitle + ",vs eta",
734  eta2D_nbin,
735  eta_min,
736  eta_max,
737  50,
741  "PoPmatchingObjectVsPhi",
742  htitle + ",vs phi",
743  phi2D_nbin,
744  phi_min,
745  phi_max,
746  50,
750  iBooker, "PoPmatchingObjectVsPt", htitle + ",vs eta", pt2D_nbin, 0., pt_max, 50, popmatching_min, popmatching_max);
752  "PoPmatchingObject_barrel",
753  htitle + ", barrel",
757  xtitle);
759  "PoPmatchingObject_endcaps",
760  htitle + ", endcaps",
764  xtitle);
765  htitle = "Ele - " + matchingObjectType + ", ";
766  xtitle = "#eta - #eta_{" + matchingObjectType + "}";
768  bookH1withSumw2(iBooker, "EtamatchingObjectEtaTrue", htitle + "eta", deta_nbin, deta_min, deta_max, xtitle);
770  "EtaMnEtamatchingObjectVsEta",
771  htitle + "eta, vs eta",
772  eta2D_nbin,
773  eta_min,
774  eta_max,
775  deta_nbin / 2,
776  deta_min,
777  deta_max);
779  "EtaMnEtamatchingObjectVsPhi",
780  htitle + "eta, vs phi",
781  phi2D_nbin,
782  phi_min,
783  phi_max,
784  deta_nbin / 2,
785  deta_min,
786  deta_max);
788  "EtaMnEtamatchingObjectVsPt",
789  htitle + "eta,, vs pt",
790  pt_nbin,
791  0.,
792  pt_max,
793  deta_nbin / 2,
794  deta_min,
795  deta_max);
796  xtitle = "#phi - #phi_{" + matchingObjectType + "} (rad)";
798  bookH1withSumw2(iBooker, "PhiMnPhimatchingObject", htitle + "phi", dphi_nbin, dphi_min, dphi_max, xtitle);
800  bookH1(iBooker, "PhiMnPhimatchingObject2", htitle + "phi", dphimatch2D_nbin, dphimatch_min, dphimatch_max);
802  "PhiMnPhimatchingObjectVsEta",
803  htitle + "phi, vs eta",
804  eta2D_nbin,
805  eta_min,
806  eta_max,
807  dphi_nbin / 2,
808  dphi_min,
809  dphi_max);
811  "PhiMnPhimatchingObjectVsPhi",
812  htitle + "phi, vs phi",
813  phi2D_nbin,
814  phi_min,
815  phi_max,
816  dphi_nbin / 2,
817  dphi_min,
818  dphi_max);
820  "PhiMnPhimatchingObjectVsPt",
821  htitle + "phi, vs pt",
822  pt2D_nbin,
823  0.,
824  pt_max,
825  dphi_nbin / 2,
826  dphi_min,
827  dphi_max);
828 
829  // matched electron, superclusters
830 
831  setBookPrefix("h_scl");
832 
833  h1_scl_En_ = bookH1withSumw2(iBooker, "energy", "ele supercluster energy", p_nbin, 0., p_max);
834  htitle = "Ele supercluster / " + matchingObjectType + ", energy";
835  xtitle = "E/E_{" + matchingObjectType + "}";
837  bookH1withSumw2(iBooker, "EoEmatchingObject_barrel", htitle + ", barrel", 50, 0.2, 1.2, xtitle);
839  bookH1withSumw2(iBooker, "EoEmatchingObject_endcaps", htitle + ", endcaps", 50, 0.2, 1.2, xtitle);
840  h1_scl_Et_ = bookH1withSumw2(iBooker, "et", "ele supercluster transverse energy", pt_nbin, 0., pt_max);
841  h2_scl_EtVsEta_ = bookH2(iBooker,
842  "etVsEta",
843  "ele supercluster transverse energy vs eta",
844  eta2D_nbin,
845  eta_min,
846  eta_max,
847  pt_nbin,
848  0.,
849  pt_max);
850  h2_scl_EtVsPhi_ = bookH2(iBooker,
851  "etVsPhi",
852  "ele supercluster transverse energy vs phi",
853  phi2D_nbin,
854  phi_min,
855  phi_max,
856  pt_nbin,
857  0.,
858  pt_max);
860  iBooker, "etaVsPhi", "ele supercluster eta vs phi", phi2D_nbin, phi_min, phi_max, eta2D_nbin, eta_min, eta_max);
861  h1_scl_Eta_ = bookH1withSumw2(iBooker, "eta", "ele supercluster eta", eta_nbin, eta_min, eta_max);
862  h1_scl_Phi_ = bookH1withSumw2(iBooker, "phi", "ele supercluster phi", phi_nbin, phi_min, phi_max);
864  "sigietaieta",
865  "ele supercluster sigma ieta ieta",
866  100,
867  0.,
868  0.05,
869  "#sigma_{i#eta i#eta}",
870  "Events",
871  "ELE_LOGY E1 P");
873  "sigietaieta_barrel",
874  "ele supercluster sigma ieta ieta, barrel",
875  100,
876  0.,
877  0.05,
878  "#sigma_{i#eta i#eta}",
879  "Events",
880  "ELE_LOGY E1 P");
882  "sigietaieta_endcaps",
883  "ele supercluster sigma ieta ieta, endcaps",
884  100,
885  0.,
886  0.05,
887  "#sigma_{i#eta i#eta}",
888  "Events",
889  "ELE_LOGY E1 P");
891  "full5x5_sigietaieta",
892  "ele supercluster full5x5 sigma ieta ieta",
893  100,
894  0.,
895  0.05,
896  "#sigma_{i#eta i#eta}",
897  "Events",
898  "ELE_LOGY E1 P");
900  "full5x5_sigietaieta_barrel",
901  "ele supercluster full5x5 sigma ieta ieta, barrel",
902  100,
903  0.,
904  0.05,
905  "#sigma_{i#eta i#eta}",
906  "Events",
907  "ELE_LOGY E1 P");
909  "full5x5_sigietaieta_endcaps",
910  "ele supercluster full5x5 sigma ieta ieta, endcaps",
911  100,
912  0.,
913  0.05,
914  "#sigma_{i#eta i#eta}",
915  "Events",
916  "ELE_LOGY E1 P");
918  iBooker, "E1x5", "ele supercluster energy in 1x5", p_nbin, 0., p_max, "E1x5 (GeV)", "Events", "ELE_LOGY E1 P");
920  "E1x5_barrel",
921  "ele supercluster energy in 1x5 barrel",
922  p_nbin,
923  0.,
924  p_max,
925  "E1x5 (GeV)",
926  "Events",
927  "ELE_LOGY E1 P");
929  "E1x5_endcaps",
930  "ele supercluster energy in 1x5 endcaps",
931  p_nbin,
932  0.,
933  p_max,
934  "E1x5 (GeV)",
935  "Events",
936  "ELE_LOGY E1 P");
938  "E2x5max",
939  "ele supercluster energy in 2x5 max",
940  p_nbin,
941  0.,
942  p_max,
943  "E2x5 (GeV)",
944  "Events",
945  "ELE_LOGY E1 P");
947  "E2x5max_barrel",
948  "ele supercluster energy in 2x5 _max barrel",
949  p_nbin,
950  0.,
951  p_max,
952  "E2x5 (GeV)",
953  "Events",
954  "ELE_LOGY E1 P");
956  "E2x5max_endcaps",
957  "ele supercluster energy in 2x5 _max endcaps",
958  p_nbin,
959  0.,
960  p_max,
961  "E2x5 (GeV)",
962  "Events",
963  "ELE_LOGY E1 P");
965  iBooker, "E5x5", "ele supercluster energy in 5x5", p_nbin, 0., p_max, "E5x5 (GeV)", "Events", "ELE_LOGY E1 P");
967  "E5x5_barrel",
968  "ele supercluster energy in 5x5 barrel",
969  p_nbin,
970  0.,
971  p_max,
972  "E5x5 (GeV)",
973  "Events",
974  "ELE_LOGY E1 P");
976  "E5x5_endcaps",
977  "ele supercluster energy in 5x5 endcaps",
978  p_nbin,
979  0.,
980  p_max,
981  "E5x5 (GeV)",
982  "Events",
983  "ELE_LOGY E1 P");
984 
985  // matched electron, gsf tracks
986 
987  setBookPrefix("h_ele");
988 
990  "ambiguousTracks",
991  "ele # ambiguous tracks",
992  5,
993  0.,
994  5.,
995  "N_{ambiguous tracks}",
996  "Events",
997  "ELE_LOGY E1 P");
999  iBooker, "ambiguousTracksVsEta", "ele # ambiguous tracks vs eta", eta2D_nbin, eta_min, eta_max, 5, 0., 5.);
1001  iBooker, "ambiguousTracksVsPhi", "ele # ambiguous tracks vs phi", phi2D_nbin, phi_min, phi_max, 5, 0., 5.);
1003  bookH2(iBooker, "ambiguousTracksVsPt", "ele # ambiguous tracks vs pt", pt2D_nbin, 0., pt_max, 5, 0., 5.);
1005  bookH1withSumw2(iBooker, "foundHits", "ele track # found hits", fhits_nbin, 0., fhits_max, "N_{hits}");
1006  h2_ele_foundHitsVsEta = bookH2(iBooker,
1007  "foundHitsVsEta",
1008  "ele track # found hits vs eta",
1009  eta2D_nbin,
1010  eta_min,
1011  eta_max,
1012  fhits_nbin,
1013  0.,
1014  fhits_max);
1015  h2_ele_foundHitsVsPhi = bookH2(iBooker,
1016  "foundHitsVsPhi",
1017  "ele track # found hits vs phi",
1018  phi2D_nbin,
1019  phi_min,
1020  phi_max,
1021  fhits_nbin,
1022  0.,
1023  fhits_max);
1025  iBooker, "foundHitsVsPt", "ele track # found hits vs pt", pt2D_nbin, 0., pt_max, fhits_nbin, 0., fhits_max);
1026  h1_ele_lostHits = bookH1withSumw2(iBooker, "lostHits", "ele track # lost hits", 5, 0., 5., "N_{lost hits}");
1028  iBooker, "lostHitsVsEta", "ele track # lost hits vs eta", eta2D_nbin, eta_min, eta_max, lhits_nbin, 0., lhits_max);
1030  iBooker, "lostHitsVsPhi", "ele track # lost hits vs eta", phi2D_nbin, phi_min, phi_max, lhits_nbin, 0., lhits_max);
1032  bookH2(iBooker, "lostHitsVsPt", "ele track # lost hits vs eta", pt2D_nbin, 0., pt_max, lhits_nbin, 0., lhits_max);
1033  h1_ele_chi2 =
1034  bookH1withSumw2(iBooker, "chi2", "ele track #chi^{2}", 100, 0., 15., "#Chi^{2}", "Events", "ELE_LOGY E1 P");
1036  bookH2(iBooker, "chi2VsEta", "ele track #chi^{2} vs eta", eta2D_nbin, eta_min, eta_max, 50, 0., 15.);
1038  bookH2(iBooker, "chi2VsPhi", "ele track #chi^{2} vs phi", phi2D_nbin, phi_min, phi_max, 50, 0., 15.);
1039  h2_ele_chi2VsPt = bookH2(iBooker, "chi2VsPt", "ele track #chi^{2} vs pt", pt2D_nbin, 0., pt_max, 50, 0., 15.);
1041  "PinMnPout",
1042  "ele track inner p - outer p, mean of GSF components",
1043  p_nbin,
1044  0.,
1045  200.,
1046  "P_{vertex} - P_{out} (GeV/c)");
1048  "PinMnPout_mode",
1049  "ele track inner p - outer p, mode of GSF components",
1050  p_nbin,
1051  0.,
1052  100.,
1053  "P_{vertex} - P_{out}, mode of GSF components (GeV/c)");
1055  "PinMnPoutVsEta_mode",
1056  "ele track inner p - outer p vs eta, mode of GSF components",
1057  eta2D_nbin,
1058  eta_min,
1059  eta_max,
1060  p2D_nbin,
1061  0.,
1062  100.);
1064  "PinMnPoutVsPhi_mode",
1065  "ele track inner p - outer p vs phi, mode of GSF components",
1066  phi2D_nbin,
1067  phi_min,
1068  phi_max,
1069  p2D_nbin,
1070  0.,
1071  100.);
1073  "PinMnPoutVsPt_mode",
1074  "ele track inner p - outer p vs pt, mode of GSF components",
1075  pt2D_nbin,
1076  0.,
1077  pt_max,
1078  p2D_nbin,
1079  0.,
1080  100.);
1081  h2_ele_PinMnPoutVsE_mode = bookH2(iBooker,
1082  "PinMnPoutVsE_mode",
1083  "ele track inner p - outer p vs E, mode of GSF components",
1084  p2D_nbin,
1085  0.,
1086  200.,
1087  p2D_nbin,
1088  0.,
1089  100.);
1091  "PinMnPoutVsChi2_mode",
1092  "ele track inner p - outer p vs track chi2, mode of GSF components",
1093  50,
1094  0.,
1095  20.,
1096  p2D_nbin,
1097  0.,
1098  100.);
1100  iBooker, "outerP", "ele track outer p, mean of GSF components", p_nbin, 0., p_max, "P_{out} (GeV/c)");
1102  iBooker, "outerP_mode", "ele track outer p, mode of GSF components", p_nbin, 0., p_max, "P_{out} (GeV/c)");
1104  bookH2(iBooker, "outerPVsEta_mode", "ele track outer p vs eta mode", eta2D_nbin, eta_min, eta_max, 50, 0., p_max);
1106  iBooker, "outerPt", "ele track outer p_{T}, mean of GSF components", pt_nbin, 0., pt_max, "P_{T out} (GeV/c)");
1108  "outerPt_mode",
1109  "ele track outer p_{T}, mode of GSF components",
1110  pt_nbin,
1111  0.,
1112  pt_max,
1113  "P_{T out} (GeV/c)");
1114  h2_ele_outerPtVsEta_mode = bookH2(iBooker,
1115  "outerPtVsEta_mode",
1116  "ele track outer p_{T} vs eta, mode of GSF components",
1117  eta2D_nbin,
1118  eta_min,
1119  eta_max,
1120  pt2D_nbin,
1121  0.,
1122  pt_max);
1123  h2_ele_outerPtVsPhi_mode = bookH2(iBooker,
1124  "outerPtVsPhi_mode",
1125  "ele track outer p_{T} vs phi, mode of GSF components",
1126  phi2D_nbin,
1127  phi_min,
1128  phi_max,
1129  pt2D_nbin,
1130  0.,
1131  pt_max);
1132  h2_ele_outerPtVsPt_mode = bookH2(iBooker,
1133  "outerPtVsPt_mode",
1134  "ele track outer p_{T} vs pt, mode of GSF components",
1135  pt2D_nbin,
1136  0.,
1137  100.,
1138  pt2D_nbin,
1139  0.,
1140  pt_max);
1141 
1142  // matched electrons, matching
1144  iBooker, "EoP", "ele E/P_{vertex}", eop_nbin, 0., eop_max, "E/P_{vertex}", "Events", "ELE_LOGY E1 P");
1146  "EoP_barrel",
1147  "ele E/P_{vertex} barrel",
1148  eop_nbin,
1149  0.,
1150  eop_max,
1151  "E/P_{vertex}",
1152  "Events",
1153  "ELE_LOGY E1 P");
1155  "EoP_endcaps",
1156  "ele E/P_{vertex} endcaps",
1157  eop_nbin,
1158  0.,
1159  eop_max,
1160  "E/P_{vertex}",
1161  "Events",
1162  "ELE_LOGY E1 P");
1163  h2_ele_EoPVsEta =
1164  bookH2(iBooker, "EoPVsEta", "ele E/P_{vertex} vs eta", eta2D_nbin, eta_min, eta_max, eop2D_nbin, 0., eopmaxsht);
1165  h2_ele_EoPVsPhi =
1166  bookH2(iBooker, "EoPVsPhi", "ele E/P_{vertex} vs phi", phi2D_nbin, phi_min, phi_max, eop2D_nbin, 0., eopmaxsht);
1167  h2_ele_EoPVsE = bookH2(iBooker, "EoPVsE", "ele E/P_{vertex} vs E", 50, 0., p_max, 50, 0., 5.);
1168  h1_ele_EseedOP = bookH1withSumw2(iBooker,
1169  "EseedOP",
1170  "ele E_{seed}/P_{vertex}",
1171  eop_nbin,
1172  0.,
1173  eop_max,
1174  "E_{seed}/P_{vertex}",
1175  "Events",
1176  "ELE_LOGY E1 P");
1178  "EseedOP_barrel",
1179  "ele E_{seed}/P_{vertex} barrel",
1180  eop_nbin,
1181  0.,
1182  eop_max,
1183  "E_{seed}/P_{vertex}",
1184  "Events",
1185  "ELE_LOGY E1 P");
1187  "EseedOP_endcaps",
1188  "ele E_{seed}/P_{vertex} endcaps",
1189  eop_nbin,
1190  0.,
1191  eop_max,
1192  "E_{seed}/P_{vertex}",
1193  "Events",
1194  "ELE_LOGY E1 P");
1195  h2_ele_EseedOPVsEta = bookH2(iBooker,
1196  "EseedOPVsEta",
1197  "ele E_{seed}/P_{vertex} vs eta",
1198  eta2D_nbin,
1199  eta_min,
1200  eta_max,
1201  eop2D_nbin,
1202  0.,
1203  eopmaxsht);
1204  h2_ele_EseedOPVsPhi = bookH2(iBooker,
1205  "EseedOPVsPhi",
1206  "ele E_{seed}/P_{vertex} vs phi",
1207  phi2D_nbin,
1208  phi_min,
1209  phi_max,
1210  eop2D_nbin,
1211  0.,
1212  eopmaxsht);
1213  h2_ele_EseedOPVsE = bookH2(iBooker, "EseedOPVsE", "ele E_{seed}/P_{vertex} vs E", 50, 0., p_max, 50, 0., 5.);
1215  iBooker, "EoPout", "ele E_{seed}/P_{out}", eop_nbin, 0., eop_max, "E_{seed}/P_{out}", "Events", "ELE_LOGY E1 P");
1217  "EoPout_barrel",
1218  "ele E_{seed}/P_{out} barrel",
1219  eop_nbin,
1220  0.,
1221  eop_max,
1222  "E_{seed}/P_{out}",
1223  "Events",
1224  "ELE_LOGY E1 P");
1226  "EoPout_endcaps",
1227  "ele E_{seed}/P_{out} endcaps",
1228  eop_nbin,
1229  0.,
1230  eop_max,
1231  "E_{seed}/P_{out}",
1232  "Events",
1233  "ELE_LOGY E1 P");
1235  iBooker, "EoPoutVsEta", "ele E_{seed}/P_{out} vs eta", eta2D_nbin, eta_min, eta_max, eop2D_nbin, 0., eopmaxsht);
1237  iBooker, "EoPoutVsPhi", "ele E_{seed}/P_{out} vs phi", phi2D_nbin, phi_min, phi_max, eop2D_nbin, 0., eopmaxsht);
1239  bookH2(iBooker, "EoPoutVsE", "ele E_{seed}/P_{out} vs E", p2D_nbin, 0., p_max, eop2D_nbin, 0., eopmaxsht);
1241  iBooker, "EeleOPout", "ele E_{ele}/P_{out}", eop_nbin, 0., eop_max, "E_{ele}/P_{out}", "Events", "ELE_LOGY E1 P");
1243  "EeleOPout_barrel",
1244  "ele E_{ele}/P_{out} barrel",
1245  eop_nbin,
1246  0.,
1247  eop_max,
1248  "E_{ele}/P_{out}",
1249  "Events",
1250  "ELE_LOGY E1 P");
1252  "EeleOPout_endcaps",
1253  "ele E_{ele}/P_{out} endcaps",
1254  eop_nbin,
1255  0.,
1256  eop_max,
1257  "E_{ele}/P_{out}",
1258  "Events",
1259  "ELE_LOGY E1 P");
1261  iBooker, "EeleOPoutVsEta", "ele E_{ele}/P_{out} vs eta", eta2D_nbin, eta_min, eta_max, eop2D_nbin, 0., eopmaxsht);
1263  iBooker, "EeleOPoutVsPhi", "ele E_{ele}/P_{out} vs phi", phi2D_nbin, phi_min, phi_max, eop2D_nbin, 0., eopmaxsht);
1265  bookH2(iBooker, "EeleOPoutVsE", "ele E_{ele}/P_{out} vs E", p2D_nbin, 0., p_max, eop2D_nbin, 0., eopmaxsht);
1267  "dEtaSc_propVtx",
1268  "ele #eta_{sc} - #eta_{tr}, prop from vertex",
1270  detamatch_min,
1271  detamatch_max,
1272  "#eta_{sc} - #eta_{tr}",
1273  "Events",
1274  "ELE_LOGY E1 P");
1276  "dEtaSc_propVtx_barrel",
1277  "ele #eta_{sc} - #eta_{tr}, prop from vertex, barrel",
1279  detamatch_min,
1280  detamatch_max,
1281  "#eta_{sc} - #eta_{tr}",
1282  "Events",
1283  "ELE_LOGY E1 P");
1285  "dEtaSc_propVtx_endcaps",
1286  "ele #eta_{sc} - #eta_{tr}, prop from vertex, endcaps",
1288  detamatch_min,
1289  detamatch_max,
1290  "#eta_{sc} - #eta_{tr}",
1291  "Events",
1292  "ELE_LOGY E1 P");
1294  "dEtaScVsEta_propVtx",
1295  "ele #eta_{sc} - #eta_{tr} vs eta, prop from vertex",
1296  eta2D_nbin,
1297  eta_min,
1298  eta_max,
1300  detamatch_min,
1301  detamatch_max);
1303  "dEtaScVsPhi_propVtx",
1304  "ele #eta_{sc} - #eta_{tr} vs phi, prop from vertex",
1305  phi2D_nbin,
1306  phi_min,
1307  phi_max,
1309  detamatch_min,
1310  detamatch_max);
1312  "dEtaScVsPt_propVtx",
1313  "ele #eta_{sc} - #eta_{tr} vs pt, prop from vertex",
1314  pt2D_nbin,
1315  0.,
1316  pt_max,
1318  detamatch_min,
1319  detamatch_max);
1321  "dPhiSc_propVtx",
1322  "ele #phi_{sc} - #phi_{tr}, prop from vertex",
1324  dphimatch_min,
1325  dphimatch_max,
1326  "#phi_{sc} - #phi_{tr} (rad)",
1327  "Events",
1328  "ELE_LOGY E1 P");
1330  "dPhiSc_propVtx_barrel",
1331  "ele #phi_{sc} - #phi_{tr}, prop from vertex, barrel",
1333  dphimatch_min,
1334  dphimatch_max,
1335  "#phi_{sc} - #phi_{tr} (rad)",
1336  "Events",
1337  "ELE_LOGY E1 P");
1339  "dPhiSc_propVtx_endcaps",
1340  "ele #phi_{sc} - #phi_{tr}, prop from vertex, endcaps",
1342  dphimatch_min,
1343  dphimatch_max,
1344  "#phi_{sc} - #phi_{tr} (rad)",
1345  "Events",
1346  "ELE_LOGY E1 P");
1348  "dPhiScVsEta_propVtx",
1349  "ele #phi_{sc} - #phi_{tr} vs eta, prop from vertex",
1350  eta2D_nbin,
1351  eta_min,
1352  eta_max,
1354  dphimatch_min,
1355  dphimatch_max);
1357  "dPhiScVsPhi_propVtx",
1358  "ele #phi_{sc} - #phi_{tr} vs phi, prop from vertex",
1359  phi2D_nbin,
1360  phi_min,
1361  phi_max,
1363  dphimatch_min,
1364  dphimatch_max);
1366  "dPhiScVsPt_propVtx",
1367  "ele #phi_{sc} - #phi_{tr} vs pt, prop from vertex",
1368  pt2D_nbin,
1369  0.,
1370  pt_max,
1372  dphimatch_min,
1373  dphimatch_max);
1375  "dEtaCl_propOut",
1376  "ele #eta_{cl} - #eta_{tr}, prop from outermost",
1378  detamatch_min,
1379  detamatch_max,
1380  "#eta_{seedcl} - #eta_{tr}",
1381  "Events",
1382  "ELE_LOGY E1 P");
1384  "dEtaCl_propOut_barrel",
1385  "ele #eta_{cl} - #eta_{tr}, prop from outermost, barrel",
1387  detamatch_min,
1388  detamatch_max,
1389  "#eta_{seedcl} - #eta_{tr}",
1390  "Events",
1391  "ELE_LOGY E1 P");
1393  "dEtaCl_propOut_endcaps",
1394  "ele #eta_{cl} - #eta_{tr}, prop from outermost, endcaps",
1396  detamatch_min,
1397  detamatch_max,
1398  "#eta_{seedcl} - #eta_{tr}",
1399  "Events",
1400  "ELE_LOGY E1 P");
1402  "dEtaClVsEta_propOut",
1403  "ele #eta_{cl} - #eta_{tr} vs eta, prop from out",
1404  eta2D_nbin,
1405  eta_min,
1406  eta_max,
1408  detamatch_min,
1409  detamatch_max);
1411  "dEtaClVsPhi_propOut",
1412  "ele #eta_{cl} - #eta_{tr} vs phi, prop from out",
1413  phi2D_nbin,
1414  phi_min,
1415  phi_max,
1417  detamatch_min,
1418  detamatch_max);
1420  "dEtaScVsPt_propOut",
1421  "ele #eta_{cl} - #eta_{tr} vs pt, prop from out",
1422  pt2D_nbin,
1423  0.,
1424  pt_max,
1426  detamatch_min,
1427  detamatch_max);
1429  "dPhiCl_propOut",
1430  "ele #phi_{cl} - #phi_{tr}, prop from outermost",
1432  dphimatch_min,
1433  dphimatch_max,
1434  "#phi_{seedcl} - #phi_{tr} (rad)",
1435  "Events",
1436  "ELE_LOGY E1 P");
1438  "dPhiCl_propOut_barrel",
1439  "ele #phi_{cl} - #phi_{tr}, prop from outermost, barrel",
1441  dphimatch_min,
1442  dphimatch_max,
1443  "#phi_{seedcl} - #phi_{tr} (rad)",
1444  "Events",
1445  "ELE_LOGY E1 P");
1447  "dPhiCl_propOut_endcaps",
1448  "ele #phi_{cl} - #phi_{tr}, prop from outermost, endcaps",
1450  dphimatch_min,
1451  dphimatch_max,
1452  "#phi_{seedcl} - #phi_{tr} (rad)",
1453  "Events",
1454  "ELE_LOGY E1 P");
1456  "dPhiClVsEta_propOut",
1457  "ele #phi_{cl} - #phi_{tr} vs eta, prop from out",
1458  eta2D_nbin,
1459  eta_min,
1460  eta_max,
1462  dphimatch_min,
1463  dphimatch_max);
1465  "dPhiClVsPhi_propOut",
1466  "ele #phi_{cl} - #phi_{tr} vs phi, prop from out",
1467  phi2D_nbin,
1468  phi_min,
1469  phi_max,
1471  dphimatch_min,
1472  dphimatch_max);
1474  "dPhiSClsPt_propOut",
1475  "ele #phi_{cl} - #phi_{tr} vs pt, prop from out",
1476  pt2D_nbin,
1477  0.,
1478  pt_max,
1480  dphimatch_min,
1481  dphimatch_max);
1483  "dEtaEleCl_propOut",
1484  "ele #eta_{EleCl} - #eta_{tr}, prop from outermost",
1486  detamatch_min,
1487  detamatch_max,
1488  "#eta_{elecl} - #eta_{tr}",
1489  "Events",
1490  "ELE_LOGY E1 P");
1492  "dEtaEleCl_propOut_barrel",
1493  "ele #eta_{EleCl} - #eta_{tr}, prop from outermost, barrel",
1495  detamatch_min,
1496  detamatch_max,
1497  "#eta_{elecl} - #eta_{tr}",
1498  "Events",
1499  "ELE_LOGY E1 P");
1501  "dEtaEleCl_propOut_endcaps",
1502  "ele #eta_{EleCl} - #eta_{tr}, prop from outermost, endcaps",
1504  detamatch_min,
1505  detamatch_max,
1506  "#eta_{elecl} - #eta_{tr}",
1507  "Events",
1508  "ELE_LOGY E1 P");
1510  "dEtaEleClVsEta_propOut",
1511  "ele #eta_{EleCl} - #eta_{tr} vs eta, prop from out",
1512  eta2D_nbin,
1513  eta_min,
1514  eta_max,
1516  detamatch_min,
1517  detamatch_max);
1519  "dEtaEleClVsPhi_propOut",
1520  "ele #eta_{EleCl} - #eta_{tr} vs phi, prop from out",
1521  phi2D_nbin,
1522  phi_min,
1523  phi_max,
1525  detamatch_min,
1526  detamatch_max);
1528  "dEtaScVsPt_propOut",
1529  "ele #eta_{EleCl} - #eta_{tr} vs pt, prop from out",
1530  pt2D_nbin,
1531  0.,
1532  pt_max,
1534  detamatch_min,
1535  detamatch_max);
1537  "dPhiEleCl_propOut",
1538  "ele #phi_{EleCl} - #phi_{tr}, prop from outermost",
1540  dphimatch_min,
1541  dphimatch_max,
1542  "#phi_{elecl} - #phi_{tr} (rad)",
1543  "Events",
1544  "ELE_LOGY E1 P");
1546  "dPhiEleCl_propOut_barrel",
1547  "ele #phi_{EleCl} - #phi_{tr}, prop from outermost, barrel",
1549  dphimatch_min,
1550  dphimatch_max,
1551  "#phi_{elecl} - #phi_{tr} (rad)",
1552  "Events",
1553  "ELE_LOGY E1 P");
1555  "dPhiEleCl_propOut_endcaps",
1556  "ele #phi_{EleCl} - #phi_{tr}, prop from outermost, endcaps",
1558  dphimatch_min,
1559  dphimatch_max,
1560  "#phi_{elecl} - #phi_{tr} (rad)",
1561  "Events",
1562  "ELE_LOGY E1 P");
1564  "dPhiEleClVsEta_propOut",
1565  "ele #phi_{EleCl} - #phi_{tr} vs eta, prop from out",
1566  eta2D_nbin,
1567  eta_min,
1568  eta_max,
1570  dphimatch_min,
1571  dphimatch_max);
1573  "dPhiEleClVsPhi_propOut",
1574  "ele #phi_{EleCl} - #phi_{tr} vs phi, prop from out",
1575  phi2D_nbin,
1576  phi_min,
1577  phi_max,
1579  dphimatch_min,
1580  dphimatch_max);
1582  "dPhiSEleClsPt_propOut",
1583  "ele #phi_{EleCl} - #phi_{tr} vs pt, prop from out",
1584  pt2D_nbin,
1585  0.,
1586  pt_max,
1588  dphimatch_min,
1589  dphimatch_max);
1591  iBooker, "HoE", "ele hadronic energy / em energy", hoe_nbin, hoe_min, hoe_max, "H/E", "Events", "ELE_LOGY E1 P");
1593  "HoE_barrel",
1594  "ele hadronic energy / em energy, barrel",
1595  hoe_nbin,
1596  hoe_min,
1597  hoe_max,
1598  "H/E",
1599  "Events",
1600  "ELE_LOGY E1 P");
1602  "HoE_endcaps",
1603  "ele hadronic energy / em energy, endcaps",
1604  hoe_nbin,
1605  hoe_min,
1606  hoe_max,
1607  "H/E",
1608  "Events",
1609  "ELE_LOGY E1 P");
1610  h1_ele_HoE_bc = bookH1withSumw2(iBooker,
1611  "HoE_bc",
1612  "ele hadronic energy / em energy behind cluster",
1613  hoe_nbin,
1614  hoe_min,
1615  hoe_max,
1616  "H/E",
1617  "Events",
1618  "ELE_LOGY E1 P");
1620  "HoE_bc_barrel",
1621  "ele hadronic energy / em energy, behind cluster barrel",
1622  hoe_nbin,
1623  hoe_min,
1624  hoe_max,
1625  "H/E",
1626  "Events",
1627  "ELE_LOGY E1 P");
1629  "HoE_bc_endcaps",
1630  "ele hadronic energy / em energy, behind cluster, endcaps",
1631  hoe_nbin,
1632  hoe_min,
1633  hoe_max,
1634  "H/E",
1635  "Events",
1636  "ELE_LOGY E1 P");
1638  "hcalDepth1OverEcalBc",
1639  "hcalDepth1OverEcalBc",
1640  hoe_nbin,
1641  hoe_min,
1642  hoe_max,
1643  "H/E",
1644  "Events",
1645  "ELE_LOGY E1 P");
1647  "hcalDepth1OverEcalBc_barrel",
1648  "hcalDepth1OverEcalBc_barrel",
1649  hoe_nbin,
1650  hoe_min,
1651  hoe_max,
1652  "H/E",
1653  "Events",
1654  "ELE_LOGY E1 P");
1656  "hcalDepth1OverEcalBc_endcaps",
1657  "hcalDepth1OverEcalBc_endcaps",
1658  hoe_nbin,
1659  hoe_min,
1660  hoe_max,
1661  "H/E",
1662  "Events",
1663  "ELE_LOGY E1 P");
1665  "hcalDepth2OverEcalBc",
1666  "hcalDepth2OverEcalBc",
1667  hoe_nbin,
1668  hoe_min,
1669  hoe_max,
1670  "H/E",
1671  "Events",
1672  "ELE_LOGY E1 P");
1674  "hcalDepth2OverEcalBc_barrel",
1675  "hcalDepth2OverEcalBc_barrel",
1676  hoe_nbin,
1677  hoe_min,
1678  hoe_max,
1679  "H/E",
1680  "Events",
1681  "ELE_LOGY E1 P");
1683  "hcalDepth2OverEcalBc_endcaps",
1684  "hcalDepth2OverEcalBc_endcaps",
1685  hoe_nbin,
1686  hoe_min,
1687  hoe_max,
1688  "H/E",
1689  "Events",
1690  "ELE_LOGY E1 P");
1692  "HoE_fiducial",
1693  "ele hadronic energy / em energy, fiducial region",
1694  hoe_nbin,
1695  hoe_min,
1696  hoe_max,
1697  "H/E",
1698  "Events",
1699  "ELE_LOGY E1 P");
1700  h2_ele_HoEVsEta = bookH2(iBooker,
1701  "HoEVsEta",
1702  "ele hadronic energy / em energy vs eta",
1703  eta_nbin,
1704  eta_min,
1705  eta_max,
1706  hoe_nbin,
1707  hoe_min,
1708  hoe_max);
1709  h2_ele_HoEVsPhi = bookH2(iBooker,
1710  "HoEVsPhi",
1711  "ele hadronic energy / em energy vs phi",
1712  phi2D_nbin,
1713  phi_min,
1714  phi_max,
1715  hoe_nbin,
1716  hoe_min,
1717  hoe_max);
1718  h2_ele_HoEVsE =
1719  bookH2(iBooker, "HoEVsE", "ele hadronic energy / em energy vs E", p_nbin, 0., 300., hoe_nbin, hoe_min, hoe_max);
1720  setBookPrefix("h_scl");
1722  "ESFrac_endcaps",
1723  "Preshower over SC raw energy , endcaps",
1724  100,
1725  0.,
1726  0.8,
1727  "E_{PS} / E^{raw}_{SC}",
1728  "Events",
1729  "ELE_LOGY E1 P");
1730 
1731  // seeds
1732  setBookPrefix("h_ele");
1734  bookH1withSumw2(iBooker, "seedSubdet2", "ele seed subdet 2nd layer", 11, -0.5, 10.5, "2nd hit subdet Id");
1735  h1_ele_seed_mask_ = bookH1withSumw2(iBooker, "seedMask", "ele seed hits mask", 13, -0.5, 12.5);
1737  bookH1withSumw2(iBooker, "seedMask_Bpix", "ele seed hits mask when subdet2 is bpix", 13, -0.5, 12.5);
1739  bookH1withSumw2(iBooker, "seedMask_Fpix", "ele seed hits mask when subdet2 is bpix", 13, -0.5, 12.5);
1741  bookH1withSumw2(iBooker, "seedMask_Tec", "ele seed hits mask when subdet2 is bpix", 13, -0.5, 12.5);
1743  iBooker, "seedDphi2", "ele seed dphi 2nd layer", 50, -0.003, +0.003, "#phi_{hit}-#phi_{pred} (rad)");
1745  iBooker, "seedDphi2_VsEta", "ele seed dphi 2nd layer vs eta", eta2D_nbin, eta_min, eta_max, 50, -0.003, +0.003);
1747  bookH2(iBooker, "seedDphi2_VsPt", "ele seed dphi 2nd layer vs pt", pt2D_nbin, 0., pt_max, 50, -0.003, +0.003);
1749  iBooker, "seedDphi2Pos", "ele seed dphi 2nd layer positron", 50, -0.003, +0.003, "#phi_{hit}-#phi_{pred} (rad)");
1751  "seedDphi2Pos_VsEta",
1752  "ele seed dphi 2nd layer positron vs eta",
1753  eta2D_nbin,
1754  eta_min,
1755  eta_max,
1756  50,
1757  -0.003,
1758  +0.003);
1760  iBooker, "seedDphi2Pos_VsPt", "ele seed dphi 2nd layer positron vs pt", pt2D_nbin, 0., pt_max, 50, -0.003, +0.003);
1762  iBooker, "seedDrz2", "ele seed dr (dz) 2nd layer", 50, -0.03, +0.03, "r(z)_{hit}-r(z)_{pred} (cm)");
1764  iBooker, "seedDrz2_VsEta", "ele seed dr/dz 2nd layer vs eta", eta2D_nbin, eta_min, eta_max, 50, -0.03, +0.03);
1766  bookH2(iBooker, "seedDrz2_VsPt", "ele seed dr/dz 2nd layer vs pt", pt2D_nbin, 0., pt_max, 50, -0.03, +0.03);
1768  iBooker, "seedDrz2Pos", "ele seed dr (dz) 2nd layer positron", 50, -0.03, +0.03, "r(z)_{hit}-r(z)_{pred} (cm)");
1770  "seedDrz2Pos_VsEta",
1771  "ele seed dr/dz 2nd layer positron vs eta",
1772  eta2D_nbin,
1773  eta_min,
1774  eta_max,
1775  50,
1776  -0.03,
1777  +0.03);
1779  iBooker, "seedDrz2Pos_VsPt", "ele seed dr/dz 2nd layer positron vs pt", pt2D_nbin, 0., pt_max, 50, -0.03, +0.03);
1780 
1781  // classes
1782  h1_ele_classes = bookH1withSumw2(iBooker, "classes", "ele classes", 20, 0.0, 20., "class Id");
1783  h1_ele_eta = bookH1withSumw2(iBooker, "eta", "ele electron eta", eta_nbin / 2, 0.0, eta_max);
1784  h1_ele_eta_golden = bookH1withSumw2(iBooker, "eta_golden", "ele electron eta golden", eta_nbin / 2, 0.0, eta_max);
1785  h1_ele_eta_bbrem = bookH1withSumw2(iBooker, "eta_bbrem", "ele electron eta bbrem", eta_nbin / 2, 0.0, eta_max);
1786  h1_ele_eta_shower = bookH1withSumw2(iBooker, "eta_shower", "ele electron eta showering", eta_nbin / 2, 0.0, eta_max);
1788  "PinVsPoutGolden_mode",
1789  "ele track inner p vs outer p vs eta, golden, mode of GSF components",
1790  p2D_nbin,
1791  0.,
1792  p_max,
1793  50,
1794  0.,
1795  p_max);
1797  "PinVsPoutShowering_mode",
1798  "ele track inner p vs outer p vs eta, showering, mode of GSF components",
1799  p2D_nbin,
1800  0.,
1801  p_max,
1802  50,
1803  0.,
1804  p_max);
1806  "PinVsPoutGolden_mean",
1807  "ele track inner p vs outer p vs eta, golden, mean of GSF components",
1808  p2D_nbin,
1809  0.,
1810  p_max,
1811  50,
1812  0.,
1813  p_max);
1815  "PinVsPoutShowering_mean",
1816  "ele track inner p vs outer p vs eta, showering, mean of GSF components",
1817  p2D_nbin,
1818  0.,
1819  p_max,
1820  50,
1821  0.,
1822  p_max);
1824  "PtinVsPtoutGolden_mode",
1825  "ele track inner pt vs outer pt vs eta, golden, mode of GSF components",
1826  pt2D_nbin,
1827  0.,
1828  pt_max,
1829  50,
1830  0.,
1831  pt_max);
1833  "PtinVsPtoutShowering_mode",
1834  "ele track inner pt vs outer pt vs eta, showering, mode of GSF components",
1835  pt2D_nbin,
1836  0.,
1837  pt_max,
1838  50,
1839  0.,
1840  pt_max);
1842  "PtinVsPtoutGolden_mean",
1843  "ele track inner pt vs outer pt vs eta, golden, mean of GSF components",
1844  pt2D_nbin,
1845  0.,
1846  pt_max,
1847  50,
1848  0.,
1849  pt_max);
1851  "PtinVsPtoutShowering_mean",
1852  "ele track inner pt vs outer pt vs eta, showering, mean of GSF components",
1853  pt2D_nbin,
1854  0.,
1855  pt_max,
1856  50,
1857  0.,
1858  pt_max);
1859  setBookPrefix("h_scl");
1861  "EoEmatchingObject_golden_barrel",
1862  "ele supercluster energy / gen energy, golden, barrel",
1865  popmatching_max);
1867  "EoEmatchingObject_golden_endcaps",
1868  "ele supercluster energy / gen energy, golden, endcaps",
1871  popmatching_max);
1873  "EoEmatchingObject_showering_barrel",
1874  "ele supercluster energy / gen energy, showering, barrel",
1877  popmatching_max);
1879  bookH1withSumw2(iBooker,
1880  "EoEmatchingObject_showering_endcaps",
1881  "ele supercluster energy / gen energy, showering, endcaps",
1884  popmatching_max);
1885  setBookPrefix("h_ele");
1886 
1887  // isolation
1889  "tkSumPt_dr03",
1890  "tk isolation sum, dR=0.3",
1891  100,
1892  0.0,
1893  20.,
1894  "TkIsoSum, cone 0.3 (GeV/c)",
1895  "Events",
1896  "ELE_LOGY E1 P");
1898  "tkSumPt_dr03_barrel",
1899  "tk isolation sum, dR=0.3, barrel",
1900  100,
1901  0.0,
1902  20.,
1903  "TkIsoSum, cone 0.3 (GeV/c)",
1904  "Events",
1905  "ELE_LOGY E1 P");
1907  "tkSumPt_dr03_endcaps",
1908  "tk isolation sum, dR=0.3, endcaps",
1909  100,
1910  0.0,
1911  20.,
1912  "TkIsoSum, cone 0.3 (GeV/c)",
1913  "Events",
1914  "ELE_LOGY E1 P");
1916  "ecalRecHitSumEt_dr03",
1917  "ecal isolation sum, dR=0.3",
1918  100,
1919  0.0,
1920  20.,
1921  "EcalIsoSum, cone 0.3 (GeV)",
1922  "Events",
1923  "ELE_LOGY E1 P");
1925  "ecalRecHitSumEt_dr03_barrel",
1926  "ecal isolation sum, dR=0.3, barrel",
1927  100,
1928  0.0,
1929  20.,
1930  "EcalIsoSum, cone 0.3 (GeV)",
1931  "Events",
1932  "ELE_LOGY E1 P");
1934  "ecalRecHitSumEt_dr03_endcaps",
1935  "ecal isolation sum, dR=0.3, endcaps",
1936  100,
1937  0.0,
1938  20.,
1939  "EcalIsoSum, cone 0.3 (GeV)",
1940  "Events",
1941  "ELE_LOGY E1 P");
1943  "hcalTowerSumEt_dr03_depth1",
1944  "hcal depth1 isolation sum, dR=0.3",
1945  100,
1946  0.0,
1947  20.,
1948  "Hcal1IsoSum, cone 0.3 (GeV)",
1949  "Events",
1950  "ELE_LOGY E1 P");
1952  "hcalTowerSumEt_dr03_depth1_barrel",
1953  "hcal depth1 isolation sum, dR=0.3, barrel",
1954  100,
1955  0.0,
1956  20.,
1957  "Hcal1IsoSum, cone 0.3 (GeV)",
1958  "Events",
1959  "ELE_LOGY E1 P");
1961  "hcalTowerSumEt_dr03_depth1_endcaps",
1962  "hcal depth1 isolation sum, dR=0.3, endcaps",
1963  100,
1964  0.0,
1965  20.,
1966  "Hcal1IsoSum, cone 0.3 (GeV)",
1967  "Events",
1968  "ELE_LOGY E1 P");
1970  "hcalTowerSumEt_dr03_depth2",
1971  "hcal depth2 isolation sum, dR=0.3",
1972  100,
1973  0.0,
1974  20.,
1975  "Hcal2IsoSum, cone 0.3 (GeV)",
1976  "Events",
1977  "ELE_LOGY E1 P");
1979  "tkSumPt_dr04",
1980  "tk isolation sum, dR=0.4",
1981  100,
1982  0.0,
1983  20.,
1984  "TkIsoSum, cone 0.4 (GeV/c)",
1985  "Events",
1986  "ELE_LOGY E1 P");
1988  "tkSumPt_dr04_barrel",
1989  "tk isolation sum, dR=0.4, barrel",
1990  100,
1991  0.0,
1992  20.,
1993  "TkIsoSum, cone 0.4 (GeV/c)",
1994  "Events",
1995  "ELE_LOGY E1 P");
1997  "tkSumPt_dr04_endcaps",
1998  "tk isolation sum, dR=0.4, endcaps",
1999  100,
2000  0.0,
2001  20.,
2002  "TkIsoSum, cone 0.4 (GeV/c)",
2003  "Events",
2004  "ELE_LOGY E1 P");
2006  "ecalRecHitSumEt_dr04",
2007  "ecal isolation sum, dR=0.4",
2008  100,
2009  0.0,
2010  20.,
2011  "EcalIsoSum, cone 0.4 (GeV)",
2012  "Events",
2013  "ELE_LOGY E1 P");
2015  "ecalRecHitSumEt_dr04_barrel",
2016  "ecal isolation sum, dR=0.4, barrel",
2017  100,
2018  0.0,
2019  20.,
2020  "EcalIsoSum, cone 0.4 (GeV)",
2021  "Events",
2022  "ELE_LOGY E1 P");
2024  "ecalRecHitSumEt_dr04_endcaps",
2025  "ecal isolation sum, dR=0.4, endcaps",
2026  100,
2027  0.0,
2028  20.,
2029  "EcalIsoSum, cone 0.4 (GeV)",
2030  "Events",
2031  "ELE_LOGY E1 P");
2033  "hcalTowerSumEt_dr04_depth1",
2034  "hcal depth1 isolation sum, dR=0.4",
2035  100,
2036  0.0,
2037  20.,
2038  "Hcal1IsoSum, cone 0.4 (GeV)",
2039  "Events",
2040  "ELE_LOGY E1 P");
2042  "hcalTowerSumEt_dr04_depth1_barrel",
2043  "hcal depth1 isolation sum, dR=0.4, barrel",
2044  100,
2045  0.0,
2046  20.,
2047  "Hcal1IsoSum, cone 0.4 (GeV)",
2048  "Events",
2049  "ELE_LOGY E1 P");
2051  "hcalTowerSumEt_dr04_depth1_endcaps",
2052  "hcal depth1 isolation sum, dR=0.4, endcaps",
2053  100,
2054  0.0,
2055  20.,
2056  "Hcal1IsoSum, cone 0.4 (GeV)",
2057  "Events",
2058  "ELE_LOGY E1 P");
2060  "hcalTowerSumEt_dr04_depth2",
2061  "hcal depth2 isolation sum, dR=0.4",
2062  100,
2063  0.0,
2064  20.,
2065  "Hcal2IsoSum, cone 0.4 (GeV)",
2066  "Events",
2067  "ELE_LOGY E1 P");
2068 
2069  // newHCAL
2070  // isolation new hcal
2072  "hcalTowerSumEtBc_dr03_depth1",
2073  "hcal depth1 isolation sum behind cluster, dR=0.3",
2074  100,
2075  0.0,
2076  20.,
2077  "Hcal1IsoSum, cone 0.3 (GeV)",
2078  "Events",
2079  "ELE_LOGY E1 P");
2081  bookH1withSumw2(iBooker,
2082  "hcalTowerSumEtBc_dr03_depth1_barrel",
2083  "hcal depth1 isolation sum behind cluster, dR=0.3, barrel",
2084  100,
2085  0.0,
2086  20.,
2087  "Hcal1IsoSum, cone 0.3 (GeV)",
2088  "Events",
2089  "ELE_LOGY E1 P");
2091  bookH1withSumw2(iBooker,
2092  "hcalTowerSumEtBc_dr03_depth1_endcaps",
2093  "hcal depth1 isolation sum behind cluster, dR=0.3, endcaps",
2094  100,
2095  0.0,
2096  20.,
2097  "Hcal1IsoSum, cone 0.3 (GeV)",
2098  "Events",
2099  "ELE_LOGY E1 P");
2100 
2102  "hcalTowerSumEtBc_dr04_depth1",
2103  "hcal depth1 isolation sum behind cluster, dR=0.4",
2104  100,
2105  0.0,
2106  20.,
2107  "Hcal1IsoSum, cone 0.4 (GeV)",
2108  "Events",
2109  "ELE_LOGY E1 P");
2111  bookH1withSumw2(iBooker,
2112  "hcalTowerSumEtBc_dr04_depth1_barrel",
2113  "hcal depth1 isolation sum behind cluster, dR=0.4, barrel",
2114  100,
2115  0.0,
2116  20.,
2117  "Hcal1IsoSum, cone 0.4 (GeV)",
2118  "Events",
2119  "ELE_LOGY E1 P");
2121  bookH1withSumw2(iBooker,
2122  "hcalTowerSumEtBc_dr04_depth1_endcaps",
2123  "hcal depth1 isolation sum behind cluster, dR=0.4, endcaps",
2124  100,
2125  0.0,
2126  20.,
2127  "Hcal1IsoSum, cone 0.4 (GeV)",
2128  "Events",
2129  "ELE_LOGY E1 P");
2130 
2132  "hcalTowerSumEtBc_dr03_depth2",
2133  "hcal depth2 isolation sum behind cluster, dR=0.3",
2134  100,
2135  0.0,
2136  20.,
2137  "Hcal1IsoSum, cone 0.3 (GeV)",
2138  "Events",
2139  "ELE_LOGY E1 P");
2141  bookH1withSumw2(iBooker,
2142  "hcalTowerSumEtBc_dr03_depth2_barrel",
2143  "hcal depth2 isolation sum behind cluster, dR=0.3, barrel",
2144  100,
2145  0.0,
2146  20.,
2147  "Hcal1IsoSum, cone 0.3 (GeV)",
2148  "Events",
2149  "ELE_LOGY E1 P");
2151  bookH1withSumw2(iBooker,
2152  "hcalTowerSumEtBc_dr03_depth2_endcaps",
2153  "hcal depth2 isolation sum behind cluster, dR=0.3, endcaps",
2154  100,
2155  0.0,
2156  20.,
2157  "Hcal1IsoSum, cone 0.3 (GeV)",
2158  "Events",
2159  "ELE_LOGY E1 P");
2160 
2162  "hcalTowerSumEtBc_dr04_depth2",
2163  "hcal depth2 isolation sum behind cluster, dR=0.4",
2164  100,
2165  0.0,
2166  20.,
2167  "Hcal1IsoSum, cone 0.4 (GeV)",
2168  "Events",
2169  "ELE_LOGY E1 P");
2171  bookH1withSumw2(iBooker,
2172  "hcalTowerSumEtBc_dr04_depth2_barrel",
2173  "hcal depth2 isolation sum behind cluster, dR=0.4, barrel",
2174  100,
2175  0.0,
2176  20.,
2177  "Hcal1IsoSum, cone 0.4 (GeV)",
2178  "Events",
2179  "ELE_LOGY E1 P");
2181  bookH1withSumw2(iBooker,
2182  "hcalTowerSumEtBc_dr04_depth2_endcaps",
2183  "hcal depth2 isolation sum behind cluster, dR=0.4, endcaps",
2184  100,
2185  0.0,
2186  20.,
2187  "Hcal1IsoSum, cone 0.4 (GeV)",
2188  "Events",
2189  "ELE_LOGY E1 P");
2190 
2191  // fbrem
2193  iBooker, "fbrem", "ele brem fraction, mode of GSF components", 100, 0., 1., "P_{in} - P_{out} / P_{in}");
2195  "fbrem_barrel",
2196  "ele brem fraction for barrel, mode of GSF components",
2197  100,
2198  0.,
2199  1.,
2200  "P_{in} - P_{out} / P_{in}");
2202  "fbrem_endcaps",
2203  "ele brem franction for endcaps, mode of GSF components",
2204  100,
2205  0.,
2206  1.,
2207  "P_{in} - P_{out} / P_{in}");
2208  p1_ele_fbremVsEta_mode = bookP1(iBooker,
2209  "fbremvsEtamode",
2210  "mean ele brem fraction vs eta, mode of GSF components",
2211  eta2D_nbin,
2212  eta_min,
2213  eta_max,
2214  0.,
2215  1.,
2216  "#eta",
2217  "<P_{in} - P_{out} / P_{in}>");
2218  p1_ele_fbremVsEta_mean = bookP1(iBooker,
2219  "fbremvsEtamean",
2220  "mean ele brem fraction vs eta, mean of GSF components",
2221  eta2D_nbin,
2222  eta_min,
2223  eta_max,
2224  0.,
2225  1.,
2226  "#eta",
2227  "<P_{in} - P_{out} / P_{in}>");
2229  bookH1withSumw2(iBooker, "superclusterfbrem", "supercluster brem fraction", 100, 0., 1., "1 - E_{ele} / E_{SC}");
2231  iBooker, "superclusterfbrem_barrel", "supercluster brem fraction for barrel", 100, 0., 1., "1 - E_{ele} / E_{SC}");
2233  "superclusterfbrem_endcaps",
2234  "supercluster brem franction for endcaps",
2235  100,
2236  0.,
2237  1.,
2238  "1 - E_{ele} / E_{SC}");
2239  // e/g et pflow electrons
2240  h1_ele_mva = bookH1withSumw2(iBooker, "mva", "ele identification mva", 100, -1., 1.);
2241  h1_ele_mva_barrel = bookH1withSumw2(iBooker, "mva_barrel", "ele identification mva barrel", 100, -1., 1.);
2242  h1_ele_mva_endcaps = bookH1withSumw2(iBooker, "mva_endcaps", "ele identification mva endcaps", 100, -1., 1.);
2243  h1_ele_mva_isolated = bookH1withSumw2(iBooker, "mva_isolated", "ele identification mva isolated", 100, -1., 1.);
2245  bookH1withSumw2(iBooker, "mva_isolated_barrel", "ele identification mva isolated barrel", 100, -1., 1.);
2247  bookH1withSumw2(iBooker, "mva_isolated_endcaps", "ele identification mva isolated endcaps", 100, -1., 1.);
2248  h1_ele_provenance = bookH1withSumw2(iBooker, "provenance", "ele provenance", 5, -2., 3.);
2249  h1_ele_provenance_barrel = bookH1withSumw2(iBooker, "provenance_barrel", "ele provenance barrel", 5, -2., 3.);
2250  h1_ele_provenance_endcaps = bookH1withSumw2(iBooker, "provenance_endcaps", "ele provenance endcaps", 5, -2., 3.);
2251 
2252  // pflow isolation variables
2254  iBooker, "chargedHadronIso", "chargedHadronIso", 100, 0.0, 20., "chargedHadronIso", "Events", "ELE_LOGY E1 P");
2256  "chargedHadronIso_barrel",
2257  "chargedHadronIso for barrel",
2258  100,
2259  0.0,
2260  20.,
2261  "chargedHadronIso_barrel",
2262  "Events",
2263  "ELE_LOGY E1 P");
2265  "chargedHadronIso_endcaps",
2266  "chargedHadronIso for endcaps",
2267  100,
2268  0.0,
2269  20.,
2270  "chargedHadronIso_endcaps",
2271  "Events",
2272  "ELE_LOGY E1 P");
2274  iBooker, "neutralHadronIso", "neutralHadronIso", 21, 0.0, 20., "neutralHadronIso", "Events", "ELE_LOGY E1 P");
2276  "neutralHadronIso_barrel",
2277  "neutralHadronIso for barrel",
2278  21,
2279  0.0,
2280  20.,
2281  "neutralHadronIso_barrel",
2282  "Events",
2283  "ELE_LOGY E1 P");
2285  "neutralHadronIso_endcaps",
2286  "neutralHadronIso for endcaps",
2287  21,
2288  0.0,
2289  20.,
2290  "neutralHadronIso_endcaps",
2291  "Events",
2292  "ELE_LOGY E1 P");
2294  bookH1withSumw2(iBooker, "photonIso", "photonIso", 100, 0.0, 20., "photonIso", "Events", "ELE_LOGY E1 P");
2296  iBooker, "photonIso_barrel", "photonIso for barrel", 100, 0.0, 20., "photonIso_barrel", "Events", "ELE_LOGY E1 P");
2298  "photonIso_endcaps",
2299  "photonIso for endcaps",
2300  100,
2301  0.0,
2302  20.,
2303  "photonIso_endcaps",
2304  "Events",
2305  "ELE_LOGY E1 P");
2306  // -- pflow over pT
2308  "chargedHadronRelativeIso",
2309  "chargedHadronRelativeIso",
2310  100,
2311  0.0,
2312  2.,
2313  "chargedHadronRelativeIso",
2314  "Events",
2315  "ELE_LOGY E1 P");
2317  "chargedHadronRelativeIso_barrel",
2318  "chargedHadronRelativeIso for barrel",
2319  100,
2320  0.0,
2321  2.,
2322  "chargedHadronRelativeIso_barrel",
2323  "Events",
2324  "ELE_LOGY E1 P");
2326  "chargedHadronRelativeIso_endcaps",
2327  "chargedHadronRelativeIso for endcaps",
2328  100,
2329  0.0,
2330  2.,
2331  "chargedHadronRelativeIso_endcaps",
2332  "Events",
2333  "ELE_LOGY E1 P");
2335  "neutralHadronRelativeIso",
2336  "neutralHadronRelativeIso",
2337  100,
2338  0.0,
2339  2.,
2340  "neutralHadronRelativeIso",
2341  "Events",
2342  "ELE_LOGY E1 P");
2344  "neutralHadronRelativeIso_barrel",
2345  "neutralHadronRelativeIso for barrel",
2346  100,
2347  0.0,
2348  2.,
2349  "neutralHadronRelativeIso_barrel",
2350  "Events",
2351  "ELE_LOGY E1 P");
2353  "neutralHadronRelativeIso_endcaps",
2354  "neutralHadronRelativeIso for endcaps",
2355  100,
2356  0.0,
2357  2.,
2358  "neutralHadronRelativeIso_endcaps",
2359  "Events",
2360  "ELE_LOGY E1 P");
2362  iBooker, "photonRelativeIso", "photonRelativeIso", 100, 0.0, 2., "photonRelativeIso", "Events", "ELE_LOGY E1 P");
2364  "photonRelativeIso_barrel",
2365  "photonRelativeIso for barrel",
2366  100,
2367  0.0,
2368  2.,
2369  "photonRelativeIso_barrel",
2370  "Events",
2371  "ELE_LOGY E1 P");
2373  "photonRelativeIso_endcaps",
2374  "photonRelativeIso for endcaps",
2375  100,
2376  0.0,
2377  2.,
2378  "photonRelativeIso_endcaps",
2379  "Events",
2380  "ELE_LOGY E1 P");
2381 
2382  // conversion rejection information
2383  h1_ele_convFlags = bookH1withSumw2(iBooker, "convFlags", "conversion rejection flag", 5, -2.5, 2.5);
2385  bookH1withSumw2(iBooker, "convFlags_all", "conversion rejection flag, all electrons", 5, -2.5, 2.5);
2386  h1_ele_convDist = bookH1withSumw2(iBooker, "convDist", "distance to the conversion partner", 100, -15., 15.);
2388  bookH1withSumw2(iBooker, "convDist_all", "distance to the conversion partner, all electrons", 100, -15., 15.);
2390  iBooker, "convDcot", "difference of cot(angle) with the conversion partner", 100, -CLHEP::pi / 2., CLHEP::pi / 2.);
2392  "convDcot_all",
2393  "difference of cot(angle) with the conversion partner, all electrons",
2394  100,
2395  -CLHEP::pi / 2.,
2396  CLHEP::pi / 2.);
2397  h1_ele_convRadius = bookH1withSumw2(iBooker, "convRadius", "signed conversion radius", 100, 0., 130.);
2399  bookH1withSumw2(iBooker, "convRadius_all", "signed conversion radius, all electrons", 100, 0., 130.);
2400 }
2401 
2403 
2404 //=========================================================================
2405 // Main methods
2406 //=========================================================================
2407 
2409  // get reco electrons
2410  auto gsfElectrons = iEvent.getHandle(electronCollection_);
2411  auto gsfElectronsEndcaps = iEvent.getHandle(electronCollectionEndcaps_);
2412  auto gsfElectronCores = iEvent.getHandle(electronCoreCollection_);
2413  auto gsfElectronTracks = iEvent.getHandle(electronTrackCollection_);
2414  auto gsfElectronSeeds = iEvent.getHandle(electronSeedCollection_);
2415 
2416  // get gen jets
2417  auto genJets = iEvent.getHandle(matchingObjectCollection_);
2418 
2419  // get the beamspot from the Event:
2420  auto recoBeamSpotHandle = iEvent.getHandle(beamSpotTag_);
2421  const BeamSpot bs = *recoBeamSpotHandle;
2422 
2423  auto isoFromDepsTk03Handle = iEvent.getHandle(isoFromDepsTk03Tag_);
2424  auto isoFromDepsTk04Handle = iEvent.getHandle(isoFromDepsTk04Tag_);
2425  auto isoFromDepsEcalFull03Handle = iEvent.getHandle(isoFromDepsEcalFull03Tag_);
2426  auto isoFromDepsEcalFull04Handle = iEvent.getHandle(isoFromDepsEcalFull04Tag_);
2427  auto isoFromDepsEcalReduced03Handle = iEvent.getHandle(isoFromDepsEcalReduced03Tag_);
2428  auto isoFromDepsEcalReduced04Handle = iEvent.getHandle(isoFromDepsEcalReduced04Tag_);
2429  auto isoFromDepsHcal03Handle = iEvent.getHandle(isoFromDepsHcal03Tag_);
2430  auto isoFromDepsHcal04Handle = iEvent.getHandle(isoFromDepsHcal04Tag_);
2431 
2432  auto vertexCollectionHandle = iEvent.getHandle(offlineVerticesCollection_);
2433  if (!vertexCollectionHandle.isValid()) {
2434  edm::LogInfo("ElectronMcFakeValidator::analyze") << "vertexCollectionHandle KO";
2435  } else {
2436  edm::LogInfo("ElectronMcFakeValidator::analyze") << "vertexCollectionHandle OK";
2437  }
2438 
2439  edm::LogInfo("ElectronMcFakeValidator::analyze")
2440  << "Treating event " << iEvent.id() << " with " << gsfElectrons.product()->size() << " electrons";
2441  edm::LogInfo("ElectronMcSignalValidator::analyze")
2442  << "Treating event " << iEvent.id() << " with " << gsfElectronsEndcaps.product()->size() << " electrons";
2443 
2444  h1_recEleNum_->Fill((*gsfElectrons).size());
2445  h1_recCoreNum_->Fill((*gsfElectronCores).size());
2446  h1_recTrackNum_->Fill((*gsfElectronTracks).size());
2447  h1_recSeedNum_->Fill((*gsfElectronSeeds).size());
2448  h1_recOfflineVertices_->Fill((*vertexCollectionHandle).size());
2449 
2450  reco::GsfElectronCollection::const_iterator gsfIter;
2451  std::vector<reco::GsfElectron>::const_iterator gsfIter3;
2452  std::vector<reco::GsfElectron>::const_iterator gsfIter4;
2453 
2454  //===============================================
2455  // get a vector with EB & EE
2456  //===============================================
2457  std::vector<reco::GsfElectron> localCollection;
2458  int iBarrels = 0;
2459  int iEndcaps = 0;
2460 
2461  // looking for EB
2462  for (gsfIter = gsfElectrons->begin(); gsfIter != gsfElectrons->end(); gsfIter++) {
2463  if (gsfIter->isEB()) {
2464  localCollection.push_back(*gsfIter);
2465  iBarrels += 1;
2466  }
2467  }
2468 
2469  // looking for EE
2470  for (gsfIter = gsfElectronsEndcaps->begin(); gsfIter != gsfElectronsEndcaps->end(); gsfIter++) {
2471  if (gsfIter->isEE()) {
2472  localCollection.push_back(*gsfIter);
2473  iEndcaps += 1;
2474  }
2475  }
2476 
2477  // all rec electrons
2478  for (gsfIter3 = localCollection.begin(); gsfIter3 != localCollection.end(); gsfIter3++) {
2479  // preselect electrons
2480  if (gsfIter3->pt() > maxPt_ || std::abs(gsfIter3->eta()) > maxAbsEta_)
2481  continue;
2482 
2483  h1_ele_EoverP_all->Fill(gsfIter3->eSuperClusterOverP());
2484  h1_ele_EseedOP_all->Fill(gsfIter3->eSeedClusterOverP());
2485  h1_ele_EoPout_all->Fill(gsfIter3->eSeedClusterOverPout());
2486  h1_ele_EeleOPout_all->Fill(gsfIter3->eEleClusterOverPout());
2487  h1_ele_dEtaSc_propVtx_all->Fill(gsfIter3->deltaEtaSuperClusterTrackAtVtx());
2488  h1_ele_dPhiSc_propVtx_all->Fill(gsfIter3->deltaPhiSuperClusterTrackAtVtx());
2489  h1_ele_dEtaCl_propOut_all->Fill(gsfIter3->deltaEtaSeedClusterTrackAtCalo());
2490  h1_ele_dPhiCl_propOut_all->Fill(gsfIter3->deltaPhiSeedClusterTrackAtCalo());
2491  h1_ele_HoE_all->Fill(gsfIter3->hadronicOverEm());
2492  h1_ele_HoE_bc_all->Fill(gsfIter3->hcalOverEcalBc());
2493  double d = gsfIter3->vertex().x() * gsfIter3->vertex().x() + gsfIter3->vertex().y() * gsfIter3->vertex().y();
2494  h1_ele_TIP_all->Fill(sqrt(d));
2495  h1_ele_vertexEta_all->Fill(gsfIter3->eta());
2496  h1_ele_vertexPt_all->Fill(gsfIter3->pt());
2497  float enrj1 = gsfIter3->ecalEnergy();
2498 
2499  // mee
2500  for (gsfIter4 = gsfIter3 + 1; gsfIter4 != localCollection.end(); gsfIter4++) {
2501  math::XYZTLorentzVector p12 = (*gsfIter3).p4() + (*gsfIter4).p4();
2502  float mee2 = p12.Dot(p12);
2503  h1_ele_mee_all->Fill(sqrt(mee2));
2504  float enrj2 = gsfIter4->ecalEnergy();
2505  h2_ele_E2mnE1vsMee_all->Fill(sqrt(mee2), enrj2 - enrj1);
2506  if (gsfIter3->ecalDrivenSeed() && gsfIter4->ecalDrivenSeed()) {
2507  h2_ele_E2mnE1vsMee_egeg_all->Fill(sqrt(mee2), enrj2 - enrj1);
2508  }
2509  if (gsfIter3->charge() * gsfIter4->charge() < 0.) {
2510  h1_ele_mee_os->Fill(sqrt(mee2));
2511  }
2512  }
2513 
2514  // conversion rejection
2515  int flags = gsfIter3->convFlags();
2516  if (flags == -9999) {
2517  flags = -1;
2518  }
2519  h1_ele_convFlags_all->Fill(flags);
2520  if (flags >= 0.) {
2521  h1_ele_convDist_all->Fill(gsfIter3->convDist());
2522  h1_ele_convDcot_all->Fill(gsfIter3->convDcot());
2523  h1_ele_convRadius_all->Fill(gsfIter3->convRadius());
2524  }
2525  }
2526 
2527  // association matching object-reco electrons
2528  int matchingObjectNum = 0;
2529  reco::GenJetCollection::const_iterator moIter;
2530  for (moIter = genJets->begin(); moIter != genJets->end(); ++moIter) {
2531  // number of matching objects
2532  matchingObjectNum++;
2533 
2534  if (moIter->energy() / cosh(moIter->eta()) > maxPt_ || std::abs(moIter->eta()) > maxAbsEta_) {
2535  continue;
2536  }
2537 
2538  h1_matchingObjectEta->Fill(moIter->eta());
2539  h1_matchingObjectAbsEta->Fill(std::abs(moIter->eta()));
2540  h1_matchingObjectP->Fill(moIter->energy());
2541  h1_matchingObjectPt->Fill(moIter->energy() / cosh(moIter->eta()));
2542  h1_matchingObjectPhi->Fill(moIter->phi());
2543  h1_matchingObjectZ->Fill(moIter->vz());
2544 
2545  // looking for the best matching gsf electron
2546  bool okGsfFound = false;
2547  double gsfOkRatio = 999999.;
2548  bool isEBflag = false;
2549  bool isEEflag = false;
2550 
2551  // find best matched electron
2552  reco::GsfElectron bestGsfElectron;
2553 
2554  for (gsfIter3 = localCollection.begin(); gsfIter3 != localCollection.end(); gsfIter3++) {
2555  double dphi = gsfIter3->phi() - moIter->phi();
2556  if (std::abs(dphi) > CLHEP::pi) {
2557  dphi = dphi < 0 ? (CLHEP::twopi) + dphi : dphi - CLHEP::twopi;
2558  }
2559  double deltaR2 = (gsfIter3->eta() - moIter->eta()) * (gsfIter3->eta() - moIter->eta()) + dphi * dphi;
2560  if (deltaR2 < deltaR2_) {
2561  double tmpGsfRatio = gsfIter3->p() / moIter->energy();
2562  if (std::abs(tmpGsfRatio - 1) < std::abs(gsfOkRatio - 1)) {
2563  gsfOkRatio = tmpGsfRatio;
2564  bestGsfElectron = *gsfIter3;
2565  okGsfFound = true;
2566  }
2567  }
2568  } // loop over rec ele to look for the best one
2569 
2570  // analysis when the matching object is matched by a rec electron
2571  if (okGsfFound) {
2572  isEBflag = bestGsfElectron.isEB();
2573  isEEflag = bestGsfElectron.isEE();
2574  // electron related distributions
2575  h1_ele_charge->Fill(bestGsfElectron.charge());
2576  h2_ele_chargeVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.charge());
2577  h2_ele_chargeVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.charge());
2578  h2_ele_chargeVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.charge());
2579  h1_ele_vertexP->Fill(bestGsfElectron.p());
2580  h1_ele_vertexPt->Fill(bestGsfElectron.pt());
2581  h2_ele_vertexPtVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.pt());
2582  h2_ele_vertexPtVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.pt());
2583  h1_ele_vertexEta->Fill(bestGsfElectron.eta());
2584  // generated distributions for matched electrons
2585  h1_ele_matchingObjectPt_matched->Fill(moIter->energy() / cosh(moIter->eta()));
2586  h1_ele_matchingObjectPhi_matched->Fill(moIter->phi());
2588  h1_ele_matchingObjectEta_matched->Fill(moIter->eta());
2589  h2_ele_vertexEtaVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eta());
2590  h1_ele_vertexPhi->Fill(bestGsfElectron.phi());
2591  h1_ele_vertexX->Fill(bestGsfElectron.vertex().x());
2592  h1_ele_vertexY->Fill(bestGsfElectron.vertex().y());
2593  h1_ele_vertexZ->Fill(bestGsfElectron.vertex().z());
2594  h1_ele_matchingObjectZ_matched->Fill(moIter->vz());
2595  double d =
2596  (bestGsfElectron.vertex().x() - bs.position().x()) * (bestGsfElectron.vertex().x() - bs.position().x()) +
2597  (bestGsfElectron.vertex().y() - bs.position().y()) * (bestGsfElectron.vertex().y() - bs.position().y());
2598  d = sqrt(d);
2599  h1_ele_vertexTIP->Fill(d);
2600  h2_ele_vertexTIPVsEta->Fill(bestGsfElectron.eta(), d);
2601  h2_ele_vertexTIPVsPhi->Fill(bestGsfElectron.phi(), d);
2602  h2_ele_vertexTIPVsPt->Fill(bestGsfElectron.pt(), d);
2603  h1_ele_EtaMnEtamatchingObject->Fill(bestGsfElectron.eta() - moIter->eta());
2604  h2_ele_EtaMnEtamatchingObjectVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eta() - moIter->eta());
2605  h2_ele_EtaMnEtamatchingObjectVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eta() - moIter->eta());
2606  h2_ele_EtaMnEtamatchingObjectVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.eta() - moIter->eta());
2607  h1_ele_PhiMnPhimatchingObject->Fill(bestGsfElectron.phi() - moIter->phi());
2608  h1_ele_PhiMnPhimatchingObject2->Fill(bestGsfElectron.phi() - moIter->phi());
2609  h2_ele_PhiMnPhimatchingObjectVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.phi() - moIter->phi());
2610  h2_ele_PhiMnPhimatchingObjectVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.phi() - moIter->phi());
2611  h2_ele_PhiMnPhimatchingObjectVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.phi() - moIter->phi());
2612  h1_ele_PoPmatchingObject->Fill(bestGsfElectron.p() / moIter->energy());
2613  h2_ele_PoPmatchingObjectVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.p() / moIter->energy());
2614  h2_ele_PoPmatchingObjectVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.p() / moIter->energy());
2615  h2_ele_PoPmatchingObjectVsPt->Fill(bestGsfElectron.py(), bestGsfElectron.p() / moIter->energy());
2616  if (isEBflag)
2617  h1_ele_PoPmatchingObject_barrel->Fill(bestGsfElectron.p() / moIter->energy());
2618  if (isEEflag)
2619  h1_ele_PoPmatchingObject_endcaps->Fill(bestGsfElectron.p() / moIter->energy());
2620 
2621  // supercluster related distributions
2622  reco::SuperClusterRef sclRef = bestGsfElectron.superCluster();
2623  if (!bestGsfElectron.ecalDrivenSeed() && bestGsfElectron.trackerDrivenSeed())
2624  sclRef = bestGsfElectron.parentSuperCluster();
2625  if (sclRef.isNonnull()) {
2626  h1_scl_En_->Fill(sclRef->energy());
2627  double R = TMath::Sqrt(sclRef->x() * sclRef->x() + sclRef->y() * sclRef->y() + sclRef->z() * sclRef->z());
2628  double Rt = TMath::Sqrt(sclRef->x() * sclRef->x() + sclRef->y() * sclRef->y());
2629  h1_scl_Et_->Fill(sclRef->energy() * (Rt / R));
2630  h2_scl_EtVsEta_->Fill(sclRef->eta(), sclRef->energy() * (Rt / R));
2631  h2_scl_EtVsPhi_->Fill(sclRef->phi(), sclRef->energy() * (Rt / R));
2632  if (isEBflag)
2633  h1_scl_EoEmatchingObject_barrel->Fill(sclRef->energy() / moIter->energy());
2634  if (isEEflag)
2635  h1_scl_EoEmatchingObject_endcaps->Fill(sclRef->energy() / moIter->energy());
2636  h1_scl_Eta_->Fill(sclRef->eta());
2637  h2_scl_EtaVsPhi_->Fill(sclRef->phi(), sclRef->eta());
2638  h1_scl_Phi_->Fill(sclRef->phi());
2639  if (isEEflag)
2640  h1_scl_ESFrac_endcaps->Fill(sclRef->preshowerEnergy() / sclRef->rawEnergy());
2641  }
2642  h1_scl_SigIEtaIEta_->Fill(bestGsfElectron.scSigmaIEtaIEta());
2643  if (isEBflag)
2644  h1_scl_SigIEtaIEta_barrel_->Fill(bestGsfElectron.scSigmaIEtaIEta());
2645  if (isEEflag)
2646  h1_scl_SigIEtaIEta_endcaps_->Fill(bestGsfElectron.scSigmaIEtaIEta());
2648  if (isEBflag)
2650  if (isEEflag)
2652  h1_scl_E1x5_->Fill(bestGsfElectron.scE1x5());
2653  if (isEBflag)
2654  h1_scl_E1x5_barrel_->Fill(bestGsfElectron.scE1x5());
2655  if (isEEflag)
2656  h1_scl_E1x5_endcaps_->Fill(bestGsfElectron.scE1x5());
2657  h1_scl_E2x5max_->Fill(bestGsfElectron.scE2x5Max());
2658  if (isEBflag)
2659  h1_scl_E2x5max_barrel_->Fill(bestGsfElectron.scE2x5Max());
2660  if (isEEflag)
2661  h1_scl_E2x5max_endcaps_->Fill(bestGsfElectron.scE2x5Max());
2662  h1_scl_E5x5_->Fill(bestGsfElectron.scE5x5());
2663  if (isEBflag)
2664  h1_scl_E5x5_barrel_->Fill(bestGsfElectron.scE5x5());
2665  if (isEEflag)
2666  h1_scl_E5x5_endcaps_->Fill(bestGsfElectron.scE5x5());
2667 
2668  // track related distributions
2670  h2_ele_ambiguousTracksVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.ambiguousGsfTracksSize());
2671  h2_ele_ambiguousTracksVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.ambiguousGsfTracksSize());
2672  h2_ele_ambiguousTracksVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.ambiguousGsfTracksSize());
2673  if (!readAOD_) { // track extra does not exist in AOD
2674  h1_ele_foundHits->Fill(bestGsfElectron.gsfTrack()->numberOfValidHits());
2675  h2_ele_foundHitsVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.gsfTrack()->numberOfValidHits());
2676  h2_ele_foundHitsVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.gsfTrack()->numberOfValidHits());
2677  h2_ele_foundHitsVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.gsfTrack()->numberOfValidHits());
2678  h1_ele_lostHits->Fill(bestGsfElectron.gsfTrack()->numberOfLostHits());
2679  h2_ele_lostHitsVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.gsfTrack()->numberOfLostHits());
2680  h2_ele_lostHitsVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.gsfTrack()->numberOfLostHits());
2681  h2_ele_lostHitsVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.gsfTrack()->numberOfLostHits());
2682  h1_ele_chi2->Fill(bestGsfElectron.gsfTrack()->normalizedChi2());
2683  h2_ele_chi2VsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.gsfTrack()->normalizedChi2());
2684  h2_ele_chi2VsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.gsfTrack()->normalizedChi2());
2685  h2_ele_chi2VsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.gsfTrack()->normalizedChi2());
2686  }
2687  // from gsf track interface, hence using mean
2688  if (!readAOD_) { // track extra does not exist in AOD
2689  h1_ele_PinMnPout->Fill(bestGsfElectron.gsfTrack()->innerMomentum().R() -
2690  bestGsfElectron.gsfTrack()->outerMomentum().R());
2691  h1_ele_outerP->Fill(bestGsfElectron.gsfTrack()->outerMomentum().R());
2692  h1_ele_outerPt->Fill(bestGsfElectron.gsfTrack()->outerMomentum().Rho());
2693  }
2694  // from electron interface, hence using mode
2695  h1_ele_PinMnPout_mode->Fill(bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2697  bestGsfElectron.eta(), bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2699  bestGsfElectron.phi(), bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2701  bestGsfElectron.pt(), bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2702  h2_ele_PinMnPoutVsE_mode->Fill(bestGsfElectron.caloEnergy(),
2703  bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2704  if (!readAOD_) // track extra does not exist in AOD
2706  bestGsfElectron.gsfTrack()->normalizedChi2(),
2707  bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2708  h1_ele_outerP_mode->Fill(bestGsfElectron.trackMomentumOut().R());
2709  h2_ele_outerPVsEta_mode->Fill(bestGsfElectron.eta(), bestGsfElectron.trackMomentumOut().R());
2710  h1_ele_outerPt_mode->Fill(bestGsfElectron.trackMomentumOut().Rho());
2711  h2_ele_outerPtVsEta_mode->Fill(bestGsfElectron.eta(), bestGsfElectron.trackMomentumOut().Rho());
2712  h2_ele_outerPtVsPhi_mode->Fill(bestGsfElectron.phi(), bestGsfElectron.trackMomentumOut().Rho());
2713  h2_ele_outerPtVsPt_mode->Fill(bestGsfElectron.pt(), bestGsfElectron.trackMomentumOut().Rho());
2714 
2715  if (!readAOD_) { // track extra does not exist in AOD
2716  edm::RefToBase<TrajectorySeed> seed = bestGsfElectron.gsfTrack()->extra()->seedRef();
2717  ElectronSeedRef elseed = seed.castTo<ElectronSeedRef>();
2718  h1_ele_seed_subdet2_->Fill(elseed->subDet(1));
2719  h1_ele_seed_mask_->Fill(elseed->hitsMask());
2720  if (elseed->subDet(1) == 1) {
2721  h1_ele_seed_mask_bpix_->Fill(elseed->hitsMask());
2722  } else if (elseed->subDet(1) == 2) {
2723  h1_ele_seed_mask_fpix_->Fill(elseed->hitsMask());
2724  } else if (elseed->subDet(1) == 6) {
2725  h1_ele_seed_mask_tec_->Fill(elseed->hitsMask());
2726  }
2727 
2728  if (elseed->dPhiNeg(1) != std::numeric_limits<float>::infinity()) {
2729  h1_ele_seed_dphi2_->Fill(elseed->dPhiNeg(1));
2730  h2_ele_seed_dphi2VsEta_->Fill(bestGsfElectron.eta(), elseed->dPhiNeg(1));
2731  h2_ele_seed_dphi2VsPt_->Fill(bestGsfElectron.pt(), elseed->dPhiNeg(1));
2732  }
2733  if (elseed->dPhiPos(1) != std::numeric_limits<float>::infinity()) {
2734  h1_ele_seed_dphi2pos_->Fill(elseed->dPhiPos(1));
2735  h2_ele_seed_dphi2posVsEta_->Fill(bestGsfElectron.eta(), elseed->dPhiPos(1));
2736  h2_ele_seed_dphi2posVsPt_->Fill(bestGsfElectron.pt(), elseed->dPhiPos(1));
2737  }
2738  if (elseed->dRZNeg(1) != std::numeric_limits<float>::infinity()) {
2739  h1_ele_seed_drz2_->Fill(elseed->dRZNeg(1));
2740  h2_ele_seed_drz2VsEta_->Fill(bestGsfElectron.eta(), elseed->dRZNeg(1));
2741  h2_ele_seed_drz2VsPt_->Fill(bestGsfElectron.pt(), elseed->dRZNeg(1));
2742  }
2743  if (elseed->dRZPos(1) != std::numeric_limits<float>::infinity()) {
2744  h1_ele_seed_drz2pos_->Fill(elseed->dRZPos(1));
2745  h2_ele_seed_drz2posVsEta_->Fill(bestGsfElectron.eta(), elseed->dRZPos(1));
2746  h2_ele_seed_drz2posVsPt_->Fill(bestGsfElectron.pt(), elseed->dRZPos(1));
2747  }
2748  }
2749  // match distributions
2750  h1_ele_EoP->Fill(bestGsfElectron.eSuperClusterOverP());
2751  if (isEBflag)
2752  h1_ele_EoP_barrel->Fill(bestGsfElectron.eSuperClusterOverP());
2753  if (isEEflag)
2754  h1_ele_EoP_endcaps->Fill(bestGsfElectron.eSuperClusterOverP());
2755  h2_ele_EoPVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eSuperClusterOverP());
2756  h2_ele_EoPVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eSuperClusterOverP());
2757  h2_ele_EoPVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eSuperClusterOverP());
2758  h1_ele_EseedOP->Fill(bestGsfElectron.eSeedClusterOverP());
2759  if (isEBflag)
2760  h1_ele_EseedOP_barrel->Fill(bestGsfElectron.eSeedClusterOverP());
2761  if (isEEflag)
2762  h1_ele_EseedOP_endcaps->Fill(bestGsfElectron.eSeedClusterOverP());
2763  h2_ele_EseedOPVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eSeedClusterOverP());
2764  h2_ele_EseedOPVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eSeedClusterOverP());
2765  h2_ele_EseedOPVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eSeedClusterOverP());
2766  h1_ele_EoPout->Fill(bestGsfElectron.eSeedClusterOverPout());
2767  if (isEBflag)
2768  h1_ele_EoPout_barrel->Fill(bestGsfElectron.eSeedClusterOverPout());
2769  if (isEEflag)
2770  h1_ele_EoPout_endcaps->Fill(bestGsfElectron.eSeedClusterOverPout());
2771  h2_ele_EoPoutVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eSeedClusterOverPout());
2772  h2_ele_EoPoutVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eSeedClusterOverPout());
2773  h2_ele_EoPoutVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eSeedClusterOverPout());
2774  h1_ele_EeleOPout->Fill(bestGsfElectron.eEleClusterOverPout());
2775  if (isEBflag)
2776  h1_ele_EeleOPout_barrel->Fill(bestGsfElectron.eEleClusterOverPout());
2777  if (isEEflag)
2779  h2_ele_EeleOPoutVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eEleClusterOverPout());
2780  h2_ele_EeleOPoutVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eEleClusterOverPout());
2781  h2_ele_EeleOPoutVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eEleClusterOverPout());
2783  if (isEBflag)
2785  if (isEEflag)
2787  h2_ele_dEtaScVsEta_propVtx->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaEtaSuperClusterTrackAtVtx());
2788  h2_ele_dEtaScVsPhi_propVtx->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaEtaSuperClusterTrackAtVtx());
2789  h2_ele_dEtaScVsPt_propVtx->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaEtaSuperClusterTrackAtVtx());
2791  if (isEBflag)
2793  if (isEEflag)
2795  h2_ele_dPhiScVsEta_propVtx->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaPhiSuperClusterTrackAtVtx());
2796  h2_ele_dPhiScVsPhi_propVtx->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaPhiSuperClusterTrackAtVtx());
2797  h2_ele_dPhiScVsPt_propVtx->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaPhiSuperClusterTrackAtVtx());
2799  if (isEBflag)
2801  if (isEEflag)
2803  h2_ele_dEtaClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaEtaSeedClusterTrackAtCalo());
2804  h2_ele_dEtaClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaEtaSeedClusterTrackAtCalo());
2805  h2_ele_dEtaClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaEtaSeedClusterTrackAtCalo());
2807  if (isEBflag)
2809  if (isEEflag)
2811  h2_ele_dPhiClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaPhiSeedClusterTrackAtCalo());
2812  h2_ele_dPhiClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaPhiSeedClusterTrackAtCalo());
2813  h2_ele_dPhiClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaPhiSeedClusterTrackAtCalo());
2815  if (isEBflag)
2817  if (isEEflag)
2819  h2_ele_dEtaEleClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaEtaEleClusterTrackAtCalo());
2820  h2_ele_dEtaEleClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaEtaEleClusterTrackAtCalo());
2821  h2_ele_dEtaEleClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaEtaEleClusterTrackAtCalo());
2823  if (isEBflag)
2825  if (isEEflag)
2827  h2_ele_dPhiEleClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaPhiEleClusterTrackAtCalo());
2828  h2_ele_dPhiEleClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaPhiEleClusterTrackAtCalo());
2829  h2_ele_dPhiEleClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaPhiEleClusterTrackAtCalo());
2830  h1_ele_HoE->Fill(bestGsfElectron.hadronicOverEm());
2831  h1_ele_HoE_bc->Fill(bestGsfElectron.hcalOverEcalBc());
2832  if (isEBflag)
2833  h1_ele_HoE_bc_barrel->Fill(bestGsfElectron.hcalOverEcalBc());
2834  if (isEEflag)
2835  h1_ele_HoE_bc_endcaps->Fill(bestGsfElectron.hcalOverEcalBc());
2836  if (isEBflag)
2837  h1_ele_HoE_barrel->Fill(bestGsfElectron.hadronicOverEm());
2838  if (isEEflag)
2839  h1_ele_HoE_endcaps->Fill(bestGsfElectron.hadronicOverEm());
2840  if (!bestGsfElectron.isEBEtaGap() && !bestGsfElectron.isEBPhiGap() && !bestGsfElectron.isEBEEGap() &&
2841  !bestGsfElectron.isEERingGap() && !bestGsfElectron.isEEDeeGap())
2842  h1_ele_HoE_fiducial->Fill(bestGsfElectron.hadronicOverEm());
2843  h2_ele_HoEVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.hadronicOverEm());
2844  h2_ele_HoEVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.hadronicOverEm());
2845  h2_ele_HoEVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.hadronicOverEm());
2846 
2847  //classes
2848  int eleClass = bestGsfElectron.classification();
2849  if (isEEflag)
2850  eleClass += 10;
2851  h1_ele_classes->Fill(eleClass);
2852 
2853  h1_ele_eta->Fill(std::abs(bestGsfElectron.eta()));
2854  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2855  h1_ele_eta_golden->Fill(std::abs(bestGsfElectron.eta()));
2856  if (bestGsfElectron.classification() == GsfElectron::BIGBREM)
2857  h1_ele_eta_bbrem->Fill(std::abs(bestGsfElectron.eta()));
2858  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2859  h1_ele_eta_shower->Fill(std::abs(bestGsfElectron.eta()));
2860 
2861  // fbrem
2862 
2863  double fbrem_mode = bestGsfElectron.fbrem();
2864  h1_ele_fbrem->Fill(fbrem_mode);
2865  p1_ele_fbremVsEta_mode->Fill(bestGsfElectron.eta(), fbrem_mode);
2866 
2867  if (isEBflag) {
2868  double fbrem_mode_barrel = bestGsfElectron.fbrem();
2869  h1_ele_fbrem_barrel->Fill(fbrem_mode_barrel);
2870  }
2871 
2872  if (isEEflag) {
2873  double fbrem_mode_endcaps = bestGsfElectron.fbrem();
2874  h1_ele_fbrem_endcaps->Fill(fbrem_mode_endcaps);
2875  }
2876 
2877  double superclusterfbrem_mode = bestGsfElectron.superClusterFbrem();
2878  h1_ele_superclusterfbrem->Fill(superclusterfbrem_mode);
2879 
2880  if (isEBflag) {
2881  double superclusterfbrem_mode_barrel = bestGsfElectron.superClusterFbrem();
2882  h1_ele_superclusterfbrem_barrel->Fill(superclusterfbrem_mode_barrel);
2883  }
2884 
2885  if (isEEflag) {
2886  double superclusterfbrem_mode_endcaps = bestGsfElectron.superClusterFbrem();
2887  h1_ele_superclusterfbrem_endcaps->Fill(superclusterfbrem_mode_endcaps);
2888  }
2889 
2890  if (!readAOD_) // track extra does not exist in AOD
2891  {
2892  double fbrem_mean =
2893  1. - bestGsfElectron.gsfTrack()->outerMomentum().R() / bestGsfElectron.gsfTrack()->innerMomentum().R();
2894  p1_ele_fbremVsEta_mean->Fill(bestGsfElectron.eta(), fbrem_mean);
2895  }
2896 
2897  //
2898 
2899  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2900  h2_ele_PinVsPoutGolden_mode->Fill(bestGsfElectron.trackMomentumOut().R(),
2901  bestGsfElectron.trackMomentumAtVtx().R());
2902  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2903  h2_ele_PinVsPoutShowering_mode->Fill(bestGsfElectron.trackMomentumOut().R(),
2904  bestGsfElectron.trackMomentumAtVtx().R());
2905  if (!readAOD_) // track extra does not exist in AOD
2906  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2907  h2_ele_PinVsPoutGolden_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().R(),
2908  bestGsfElectron.gsfTrack()->innerMomentum().R());
2909  if (!readAOD_) // track extra does not exist in AOD
2910  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2911  h2_ele_PinVsPoutShowering_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().R(),
2912  bestGsfElectron.gsfTrack()->innerMomentum().R());
2913  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2914  h2_ele_PtinVsPtoutGolden_mode->Fill(bestGsfElectron.trackMomentumOut().Rho(),
2915  bestGsfElectron.trackMomentumAtVtx().Rho());
2916  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2917  h2_ele_PtinVsPtoutShowering_mode->Fill(bestGsfElectron.trackMomentumOut().Rho(),
2918  bestGsfElectron.trackMomentumAtVtx().Rho());
2919  if (!readAOD_) // track extra does not exist in AOD
2920  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2921  h2_ele_PtinVsPtoutGolden_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().Rho(),
2922  bestGsfElectron.gsfTrack()->innerMomentum().Rho());
2923  if (!readAOD_) // track extra does not exist in AOD
2924  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2925  h2_ele_PtinVsPtoutShowering_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().Rho(),
2926  bestGsfElectron.gsfTrack()->innerMomentum().Rho());
2927 
2928  h1_ele_mva->Fill(bestGsfElectron.mva_e_pi());
2929  if (isEBflag)
2930  h1_ele_mva_barrel->Fill(bestGsfElectron.mva_e_pi());
2931  if (isEEflag)
2932  h1_ele_mva_endcaps->Fill(bestGsfElectron.mva_e_pi());
2933  h1_ele_mva_isolated->Fill(bestGsfElectron.mva_Isolated());
2934  if (isEBflag)
2935  h1_ele_mva_barrel_isolated->Fill(bestGsfElectron.mva_Isolated());
2936  if (isEEflag)
2937  h1_ele_mva_endcaps_isolated->Fill(bestGsfElectron.mva_Isolated());
2938  if (bestGsfElectron.ecalDrivenSeed())
2939  h1_ele_provenance->Fill(1.);
2940  if (bestGsfElectron.trackerDrivenSeed())
2941  h1_ele_provenance->Fill(-1.);
2942  if (bestGsfElectron.trackerDrivenSeed() || bestGsfElectron.ecalDrivenSeed())
2943  h1_ele_provenance->Fill(0.);
2944  if (bestGsfElectron.trackerDrivenSeed() && !bestGsfElectron.ecalDrivenSeed())
2945  h1_ele_provenance->Fill(-2.);
2946  if (!bestGsfElectron.trackerDrivenSeed() && bestGsfElectron.ecalDrivenSeed())
2947  h1_ele_provenance->Fill(2.);
2948  if (bestGsfElectron.ecalDrivenSeed() && isEBflag)
2950  if (bestGsfElectron.trackerDrivenSeed() && isEBflag)
2952  if ((bestGsfElectron.trackerDrivenSeed() || bestGsfElectron.ecalDrivenSeed()) && isEBflag)
2954  if (bestGsfElectron.trackerDrivenSeed() && !bestGsfElectron.ecalDrivenSeed() && isEBflag)
2956  if (!bestGsfElectron.trackerDrivenSeed() && bestGsfElectron.ecalDrivenSeed() && isEBflag)
2958  if (bestGsfElectron.ecalDrivenSeed() && isEEflag)
2960  if (bestGsfElectron.trackerDrivenSeed() && isEEflag)
2962  if ((bestGsfElectron.trackerDrivenSeed() || bestGsfElectron.ecalDrivenSeed()) && isEEflag)
2964  if (bestGsfElectron.trackerDrivenSeed() && !bestGsfElectron.ecalDrivenSeed() && isEEflag)
2966  if (!bestGsfElectron.trackerDrivenSeed() && bestGsfElectron.ecalDrivenSeed() && isEEflag)
2968 
2969  // Pflow isolation
2971  if (isEBflag)
2973  if (isEEflag)
2975 
2977  if (isEBflag)
2979  if (isEEflag)
2981 
2983  if (isEBflag)
2985  if (isEEflag)
2987 
2988  // -- pflow over pT
2990  bestGsfElectron.pt());
2991  if (isEBflag)
2993  bestGsfElectron.pt());
2994  if (isEEflag)
2996  bestGsfElectron.pt());
2997 
2999  bestGsfElectron.pt());
3000  if (isEBflag)
3002  bestGsfElectron.pt());
3003  if (isEEflag)
3005  bestGsfElectron.pt());
3006 
3007  h1_ele_photonRelativeIso->Fill(bestGsfElectron.pfIsolationVariables().sumPhotonEt / bestGsfElectron.pt());
3008  if (isEBflag)
3010  bestGsfElectron.pt());
3011  if (isEEflag)
3013  bestGsfElectron.pt());
3014 
3015  // isolation
3016  h1_ele_tkSumPt_dr03->Fill(bestGsfElectron.dr03TkSumPt());
3017  if (isEBflag)
3018  h1_ele_tkSumPt_dr03_barrel->Fill(bestGsfElectron.dr03TkSumPt());
3019  if (isEEflag)
3020  h1_ele_tkSumPt_dr03_endcaps->Fill(bestGsfElectron.dr03TkSumPt());
3022  if (isEBflag)
3024  if (isEEflag)
3027  if (isEBflag)
3029  if (isEEflag)
3033  if (isEBflag)
3035  if (isEEflag)
3038  if (isEBflag)
3040  if (isEEflag)
3042  h1_ele_tkSumPt_dr04->Fill(bestGsfElectron.dr04TkSumPt());
3043  if (isEBflag)
3044  h1_ele_tkSumPt_dr04_barrel->Fill(bestGsfElectron.dr04TkSumPt());
3045  if (isEEflag)
3046  h1_ele_tkSumPt_dr04_endcaps->Fill(bestGsfElectron.dr04TkSumPt());
3048  if (isEBflag)
3050  if (isEEflag)
3053  if (isEBflag)
3055  if (isEEflag)
3059  if (isEBflag)
3061  if (isEEflag)
3064  if (isEBflag)
3066  if (isEEflag)
3068 
3069  h1_ele_hcalDepth1OverEcalBc->Fill(bestGsfElectron.hcalOverEcalBc(1));
3070  if (isEBflag)
3072  if (isEEflag)
3074  h1_ele_hcalDepth2OverEcalBc->Fill(bestGsfElectron.hcalOverEcalBc(2));
3075  if (isEBflag)
3077  if (isEEflag)
3079 
3080  // conversion rejection
3081  int flags = bestGsfElectron.convFlags();
3082  if (flags == -9999) {
3083  flags = -1;
3084  }
3085  h1_ele_convFlags->Fill(flags);
3086  if (flags >= 0.) {
3087  h1_ele_convDist->Fill(bestGsfElectron.convDist());
3088  h1_ele_convDcot->Fill(bestGsfElectron.convDcot());
3089  h1_ele_convRadius->Fill(bestGsfElectron.convRadius());
3090  }
3091 
3092  } // gsf electron found
3093 
3094  } // loop overmatching object
3095 
3096  h1_matchingObjectNum->Fill(matchingObjectNum);
3097 }
const PflowIsolationVariables & pfIsolationVariables() const
Definition: GsfElectron.h:729
MonitorElement * h2_ele_ambiguousTracksVsPhi
float dr03HcalTowerSumEtBc(int depth=0) const
Definition: GsfElectron.h:593
MonitorElement * h1_ele_matchingObjectPt_matched
MonitorElement * h2_ele_foundHitsVsEta
MonitorElement * h2_ele_EtaMnEtamatchingObjectVsEta
MonitorElement * h2_ele_seed_dphi2posVsPt_
MonitorElement * h1_ele_dEtaSc_propVtx
MonitorElement * h1_ele_provenance_endcaps
MonitorElement * h1_ele_dEtaEleCl_propOut_barrel
MonitorElement * h1_ele_dEtaCl_propOut_endcaps
MonitorElement * h1_ele_hcalDepth1OverEcalBc_endcaps
bool isNonnull() const
Checks for non-null.
Definition: Ref.h:238
MonitorElement * h1_ele_ecalRecHitSumEt_dr04_barrel
MonitorElement * h1_scl_E2x5max_barrel_
MonitorElement * h1_ele_seed_mask_bpix_
MonitorElement * h1_scl_EoEmatchingObjectGolden_barrel
ElectronMcFakeValidator(const edm::ParameterSet &conf)
MonitorElement * h1_ele_PhiMnPhimatchingObject2
bool isEBEtaGap() const
Definition: GsfElectron.h:333
virtual SuperClusterRef parentSuperCluster() const
Definition: GsfElectron.h:160
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth2
MonitorElement * h1_ele_hcalTowerSumEtBc_dr04_depth2_endcaps
MonitorElement * h1_ele_matchingObjectAbsEta_matched
double pt() const final
transverse momentum
float eSuperClusterOverP() const
Definition: GsfElectron.h:221
MonitorElement * h1_scl_EoEmatchingObjectGolden_endcaps
MonitorElement * h1_ele_ecalRecHitSumEt_dr03
MonitorElement * h2_ele_EtaMnEtamatchingObjectVsPt
edm::EDGetTokenT< reco::ElectronSeedCollection > electronSeedCollection_
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
MonitorElement * h2_ele_PoPmatchingObjectVsPhi
bool isEBEEGap() const
Definition: GsfElectron.h:331
MonitorElement * h1_ele_photonIso_barrel
MonitorElement * h1_ele_ecalRecHitSumEt_dr03_barrel
MonitorElement * h1_ele_tkSumPt_dr03_endcaps
MonitorElement * h1_ele_dPhiCl_propOut_all
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsEcalReduced04Tag_
MonitorElement * h2_ele_ambiguousTracksVsPt
MonitorElement * h1_ele_hcalTowerSumEtBc_dr04_depth1_endcaps
MonitorElement * h2_ele_PtinVsPtoutGolden_mode
MonitorElement * h1_ele_EseedOP_endcaps
MonitorElement * h1_ele_hcalDepth2OverEcalBc
math::XYZVectorF trackMomentumAtVtx() const
Definition: GsfElectron.h:268
MonitorElement * h1_ele_photonIso_endcaps
MonitorElement * p1_ele_fbremVsEta_mode
MonitorElement * h1_ele_chargedHadronIso_endcaps
MonitorElement * h1_scl_EoEmatchingObjectShowering_barrel
MonitorElement * h1_ele_neutralHadronIso_endcaps
MonitorElement * h1_matchingObjectAbsEta
MonitorElement * p1_ele_fbremVsEta_mean
MonitorElement * h1_ele_mva_endcaps_isolated
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsEcalFull03Tag_
float dr03HcalTowerSumEt(int depth=0) const
Definition: GsfElectron.h:576
MonitorElement * h2_ele_PinVsPoutShowering_mode
MonitorElement * h1_ele_hcalTowerSumEt_dr03_depth1_barrel
edm::EDGetTokenT< reco::GenJetCollection > matchingObjectCollection_
float dr04TkSumPt() const
Definition: GsfElectron.h:597
MonitorElement * h1_ele_tkSumPt_dr03_barrel
MonitorElement * h2_ele_vertexTIPVsPhi
edm::EDGetTokenT< reco::GsfTrackCollection > electronTrackCollection_
MonitorElement * h1_ele_foundHits_endcaps
bool isEERingGap() const
Definition: GsfElectron.h:337
const Point & vertex() const override
vertex position (overwritten by PF...)
MonitorElement * h1_ele_lostHits_endcaps
MonitorElement * h1_ele_dEtaSc_propVtx_all
float fbrem() const
Definition: GsfElectron.h:809
float scE2x5Max() const
Definition: GsfElectron.h:498
MonitorElement * h1_ele_hcalTowerSumEtBc_dr04_depth1_barrel
MonitorElement * h1_ele_hcalDepth1OverEcalBc_barrel
MonitorElement * h1_ele_dPhiSc_propVtx_all
MonitorElement * h2_ele_dPhiScVsPhi_propVtx
MonitorElement * h2_ele_dPhiScVsEta_propVtx
MonitorElement * h2_ele_dPhiEleClVsPhi_propOut
float convDist() const
Definition: GsfElectron.h:645
MonitorElement * h1_ele_dEtaCl_propOut_all
MonitorElement * h2_ele_PinVsPoutShowering_mean
float convRadius() const
Definition: GsfElectron.h:647
MonitorElement * h2_ele_E2mnE1vsMee_all
MonitorElement * h2_ele_seed_drz2VsPt_
bool isEEDeeGap() const
Definition: GsfElectron.h:336
MonitorElement * h1_ele_HoE_bc_endcaps
MonitorElement * h1_ele_superclusterfbrem_endcaps
MonitorElement * h1_ele_neutralHadronRelativeIso_endcaps
MonitorElement * h1_scl_full5x5_sigmaIetaIeta_endcaps_
float superClusterFbrem() const
Definition: GsfElectron.h:803
MonitorElement * h2_ele_ambiguousTracksVsEta
MonitorElement * h2_ele_outerPtVsPt_mode
bool isEE() const
Definition: GsfElectron.h:329
bool isEB() const
Definition: GsfElectron.h:328
MonitorElement * h2_ele_E2mnE1vsMee_egeg_all
MonitorElement * h2_ele_PtinVsPtoutShowering_mean
MonitorElement * h2_ele_PhiMnPhimatchingObjectVsPt
const Double_t pi
MonitorElement * h2_ele_dEtaEleClVsEta_propOut
MonitorElement * h2_ele_PinMnPoutVsChi2_mode
float convDcot() const
Definition: GsfElectron.h:646
float full5x5_sigmaIetaIeta() const
Definition: GsfElectron.h:471
void Fill(long long x)
MonitorElement * h1_ele_matchingObjectEta_matched
XYZTLorentzVectorD XYZTLorentzVector
Lorentz vector with cylindrical internal representation using pseudorapidity.
Definition: LorentzVector.h:29
tuple d
Definition: ztail.py:151
MonitorElement * h1_scl_E2x5max_endcaps_
MonitorElement * bookH1(DQMStore::IBooker &, const std::string &name, const std::string &title, int nchX, double lowX, double highX, const std::string &titleX="", const std::string &titleY="Events", Option_t *option="E1 P")
float hcalOverEcalBc(const ShowerShape &ss, int depth) const
Definition: GsfElectron.h:442
MonitorElement * h2_ele_EeleOPoutVsEta
MonitorElement * h2_ele_PinMnPoutVsPt_mode
GsfTrackRef gsfTrack() const override
reference to a GsfTrack
Definition: GsfElectron.h:156
Handle< PROD > getHandle(EDGetTokenT< PROD > token) const
Definition: Event.h:563
MonitorElement * h1_ele_dEtaCl_propOut
float deltaEtaSuperClusterTrackAtVtx() const
Definition: GsfElectron.h:225
int iEvent
Definition: GenABIO.cc:224
MonitorElement * h2_ele_dEtaScVsEta_propVtx
void analyze(const edm::Event &e, const edm::EventSetup &c) override
MonitorElement * h1_ele_hcalTowerSumEtBc_dr04_depth1
MonitorElement * h2_ele_foundHitsVsPhi
double p() const final
magnitude of momentum vector
float hadronicOverEm() const
Definition: GsfElectron.h:500
MonitorElement * h1_ele_chargedHadronRelativeIso_barrel
MonitorElement * h2_ele_dEtaScVsPt_propVtx
float eSeedClusterOverP() const
Definition: GsfElectron.h:222
MonitorElement * h2_ele_PtinVsPtoutShowering_mode
MonitorElement * h2_ele_dEtaClVsPt_propOut
MonitorElement * h1_ele_PhiMnPhimatchingObject
float dr04EcalRecHitSumEt() const
Definition: GsfElectron.h:599
MonitorElement * h1_ele_dPhiCl_propOut
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsHcal04Tag_
MonitorElement * h1_recOfflineVertices_
MonitorElement * h1_scl_EoEmatchingObject_barrel
MonitorElement * h1_ele_hcalTowerSumEt_dr03_depth2
MonitorElement * h2_ele_PoPmatchingObjectVsEta
float deltaPhiSeedClusterTrackAtCalo() const
Definition: GsfElectron.h:229
MonitorElement * h2_ele_dPhiClVsPt_propOut
MonitorElement * h1_ele_chargedHadronIso_barrel
T sqrt(T t)
Definition: SSEVec.h:19
MonitorElement * bookP1(DQMStore::IBooker &, const std::string &name, const std::string &title, int nchX, double lowX, double highX, double lowY, double highY, const std::string &titleX="", const std::string &titleY="", Option_t *option="E1 P")
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsTk04Tag_
math::XYZVectorF trackMomentumOut() const
Definition: GsfElectron.h:270
MonitorElement * h2_ele_dPhiEleClVsPt_propOut
MonitorElement * h1_ele_tkSumPt_dr04_endcaps
float sumPhotonEt
sum pt of PF photons // old float photonIso ;
Definition: GsfElectron.h:665
float deltaPhiSuperClusterTrackAtVtx() const
Definition: GsfElectron.h:228
MonitorElement * h1_ele_hcalDepth1OverEcalBc
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsTk03Tag_
MonitorElement * h2_ele_dEtaEleClVsPhi_propOut
MonitorElement * h1_ele_dEtaEleCl_propOut_endcaps
MonitorElement * h1_ele_PoPmatchingObject
const double infinity
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth1
float dr03TkSumPt() const
Definition: GsfElectron.h:557
MonitorElement * h1_ele_convRadius_all
MonitorElement * h2_ele_PinMnPoutVsEta_mode
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
MonitorElement * h1_ele_lostHits_barrel
MonitorElement * h1_ele_hcalTowerSumEtBc_dr04_depth2
MonitorElement * h1_ele_neutralHadronIso_barrel
MonitorElement * h1_ele_photonRelativeIso_endcaps
float eEleClusterOverPout() const
Definition: GsfElectron.h:224
void setBookPrefix(const std::string &)
edm::EDGetTokenT< reco::VertexCollection > offlineVerticesCollection_
float sumNeutralHadronEt
sum pt of neutral hadrons // old float neutralHadronIso ;
Definition: GsfElectron.h:664
float eSeedClusterOverPout() const
Definition: GsfElectron.h:223
MonitorElement * h2_ele_vertexEtaVsPhi
MonitorElement * h1_ele_seed_mask_tec_
MonitorElement * h2_ele_outerPtVsPhi_mode
MonitorElement * h1_ele_dPhiCl_propOut_endcaps
MonitorElement * h1_ele_hcalTowerSumEt_dr03_depth1_endcaps
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsEcalReduced03Tag_
MonitorElement * h2_ele_seed_drz2posVsEta_
double py() const final
y coordinate of momentum vector
MonitorElement * h1_ele_superclusterfbrem_barrel
MonitorElement * h2_ele_vertexTIPVsEta
MonitorElement * h1_ele_chargedHadronRelativeIso
MonitorElement * h1_ele_hcalTowerSumEt_dr03_depth1
MonitorElement * h2_ele_PinMnPoutVsE_mode
MonitorElement * h2_ele_PinMnPoutVsPhi_mode
MonitorElement * h2_ele_dEtaEleClVsPt_propOut
float scSigmaIEtaIEta() const
Definition: GsfElectron.h:496
MonitorElement * h1_ele_foundHits_barrel
float deltaPhiEleClusterTrackAtCalo() const
Definition: GsfElectron.h:230
MonitorElement * h2_ele_PoPmatchingObjectVsPt
MonitorElement * h1_ele_seed_dphi2pos_
void setBookEfficiencyFlag(const bool &)
MonitorElement * h1_ele_neutralHadronRelativeIso_barrel
edm::EDGetTokenT< reco::GsfElectronCollection > electronCollection_
edm::EDGetTokenT< reco::GsfElectronCollection > electronCollectionEndcaps_
MonitorElement * h2_ele_dEtaClVsEta_propOut
MonitorElement * h1_ele_mva_barrel_isolated
MonitorElement * h1_ele_superclusterfbrem
MonitorElement * h1_scl_EoEmatchingObject_endcaps
Log< level::Info, false > LogInfo
MonitorElement * h2_ele_PinVsPoutGolden_mode
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
MonitorElement * h1_ele_tkSumPt_dr04_barrel
MonitorElement * h1_ele_ecalRecHitSumEt_dr04
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:16
MonitorElement * h1_scl_full5x5_sigmaIetaIeta_
MonitorElement * h1_ele_photonRelativeIso
MonitorElement * h2_ele_seed_dphi2VsPt_
MonitorElement * h1_ele_hcalTowerSumEt_dr04_depth1_endcaps
MonitorElement * h2_ele_dEtaClVsPhi_propOut
MonitorElement * h2_ele_seed_drz2VsEta_
edm::EDGetTokenT< reco::BeamSpot > beamSpotTag_
float deltaEtaEleClusterTrackAtCalo() const
Definition: GsfElectron.h:227
MonitorElement * h1_ele_PoPmatchingObject_endcaps
MonitorElement * h1_ele_dEtaSc_propVtx_barrel
Classification classification() const
Definition: GsfElectron.h:805
MonitorElement * h2_ele_outerPtVsEta_mode
REF castTo() const
Definition: RefToBase.h:257
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth1_barrel
MonitorElement * h1_ele_seed_mask_fpix_
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
MonitorElement * h1_ele_hcalTowerSumEt_dr04_depth1_barrel
GsfTrackRefVector::size_type ambiguousGsfTracksSize() const
Definition: GsfElectron.h:766
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth1_endcaps
MonitorElement * h2_ele_PinVsPoutGolden_mean
MonitorElement * h1_ele_EeleOPout_barrel
MonitorElement * h2_ele_EeleOPoutVsPhi
MonitorElement * h1_ele_dPhiSc_propVtx
MonitorElement * h1_ele_hcalTowerSumEt_dr04_depth2
MonitorElement * h1_scl_SigIEtaIEta_barrel_
MonitorElement * h1_ele_photonRelativeIso_barrel
float mva_Isolated() const
Definition: GsfElectron.h:743
MonitorElement * h1_ele_neutralHadronIso
float dr03EcalRecHitSumEt() const
Definition: GsfElectron.h:559
float mva_e_pi() const
Definition: GsfElectron.h:744
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsHcal03Tag_
MonitorElement * h2_ele_dPhiClVsPhi_propOut
MonitorElement * h2_ele_seed_dphi2posVsEta_
MonitorElement * h1_ele_EoPout_endcaps
edm::EventID id() const
Definition: EventBase.h:59
float deltaEtaSeedClusterTrackAtCalo() const
Definition: GsfElectron.h:226
MonitorElement * h2_ele_PhiMnPhimatchingObjectVsEta
MonitorElement * h2_ele_EtaMnEtamatchingObjectVsPhi
MonitorElement * h1_ele_matchingObjectPhi_matched
MonitorElement * bookH2(DQMStore::IBooker &, const std::string &name, const std::string &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, const std::string &titleX="", const std::string &titleY="", Option_t *option="COLZ")
MonitorElement * bookH1withSumw2(DQMStore::IBooker &, const std::string &name, const std::string &title, int nchX, double lowX, double highX, const std::string &titleX="", const std::string &titleY="Events", Option_t *option="E1 P")
MonitorElement * h1_ele_ecalRecHitSumEt_dr03_endcaps
MonitorElement * h1_scl_SigIEtaIEta_endcaps_
MonitorElement * h1_ele_EtaMnEtamatchingObject
int convFlags() const
Definition: GsfElectron.h:643
float dr04HcalTowerSumEtBc(int depth=0) const
Definition: GsfElectron.h:601
MonitorElement * h1_ele_dPhiEleCl_propOut_endcaps
MonitorElement * h2_ele_dEtaScVsPhi_propVtx
MonitorElement * h2_ele_PhiMnPhimatchingObjectVsPhi
MonitorElement * h1_ele_hcalDepth2OverEcalBc_barrel
bool isEBPhiGap() const
Definition: GsfElectron.h:334
MonitorElement * h1_ele_dPhiEleCl_propOut
MonitorElement * h1_ele_EseedOP_barrel
MonitorElement * h1_scl_ESFrac_endcaps
bool trackerDrivenSeed() const
Definition: GsfElectron.h:159
MonitorElement * h1_ele_dEtaEleCl_propOut
MonitorElement * h2_ele_seed_drz2posVsPt_
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth2_endcaps
const Point & position() const
position
Definition: BeamSpot.h:59
float scE5x5() const
Definition: GsfElectron.h:499
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsEcalFull04Tag_
MonitorElement * h1_ele_dPhiSc_propVtx_endcaps
MonitorElement * h1_scl_EoEmatchingObjectShowering_endcaps
MonitorElement * h1_ele_dEtaSc_propVtx_endcaps
MonitorElement * h2_ele_seed_dphi2VsEta_
MonitorElement * h1_ele_hcalTowerSumEtBc_dr04_depth2_barrel
MonitorElement * h2_ele_dPhiClVsEta_propOut
MonitorElement * h1_ele_dEtaCl_propOut_barrel
MonitorElement * h2_ele_dPhiScVsPt_propVtx
MonitorElement * h1_ele_dPhiSc_propVtx_barrel
MonitorElement * h1_ele_hcalTowerSumEt_dr04_depth1
float dr04HcalTowerSumEt(int depth=0) const
Definition: GsfElectron.h:600
MonitorElement * h1_ele_hcalDepth2OverEcalBc_endcaps
double phi() const final
momentum azimuthal angle
void setBookStatOverflowFlag(const bool &)
float sumChargedHadronPt
sum-pt of charged Hadron // old float chargedHadronIso ;
Definition: GsfElectron.h:663
MonitorElement * h1_ele_dPhiCl_propOut_barrel
float caloEnergy() const
Definition: GsfElectron.h:899
MonitorElement * h1_ele_chargedHadronIso
MonitorElement * h1_ele_matchingObjectZ_matched
MonitorElement * h2_ele_PtinVsPtoutGolden_mean
MonitorElement * h1_ele_dPhiEleCl_propOut_barrel
edm::EDGetTokenT< reco::GsfElectronCoreCollection > electronCoreCollection_
MonitorElement * h1_ele_neutralHadronRelativeIso
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth2_barrel
MonitorElement * h1_ele_provenance_barrel
MonitorElement * h1_ele_PinMnPout_mode
SuperClusterRef superCluster() const override
reference to a SuperCluster
Definition: GsfElectron.h:155
MonitorElement * h2_ele_outerPVsEta_mode
Definition: Run.h:45
MonitorElement * h1_ele_PoPmatchingObject_barrel
int charge() const final
electric charge
float scE1x5() const
Definition: GsfElectron.h:497
MonitorElement * h1_scl_full5x5_sigmaIetaIeta_barrel_
MonitorElement * h2_ele_dPhiEleClVsEta_propOut
MonitorElement * h1_ele_ambiguousTracks
bool ecalDrivenSeed() const
Definition: GsfElectron.h:158
MonitorElement * h1_ele_ecalRecHitSumEt_dr04_endcaps
double eta() const final
momentum pseudorapidity
MonitorElement * h1_ele_EeleOPout_endcaps
MonitorElement * h1_ele_chargedHadronRelativeIso_endcaps