CMS 3D CMS Logo

ElectronMcFakeValidator.cc
Go to the documentation of this file.
1 
2 // user include files
4 
6 
8 
19 
22 
25 
30 
31 #include "CLHEP/Units/GlobalPhysicalConstants.h"
32 #include "TMath.h"
33 #include "TFile.h"
34 #include "TH1F.h"
35 #include "TH1I.h"
36 #include "TH2F.h"
37 #include "TProfile.h"
38 #include "TTree.h"
39 #include <vector>
40 #include <iostream>
41 
42 using namespace reco;
43 
45  electronCollection_ = consumes<reco::GsfElectronCollection>(conf.getParameter<edm::InputTag>("electronCollection"));
47  consumes<reco::GsfElectronCollection>(conf.getParameter<edm::InputTag>("electronCollectionEndcaps"));
49  consumes<reco::GsfElectronCoreCollection>(conf.getParameter<edm::InputTag>("electronCoreCollection"));
51  consumes<reco::GsfTrackCollection>(conf.getParameter<edm::InputTag>("electronTrackCollection"));
53  consumes<reco::ElectronSeedCollection>(conf.getParameter<edm::InputTag>("electronSeedCollection"));
55  consumes<reco::GenJetCollection>(conf.getParameter<edm::InputTag>("matchingObjectCollection"));
57  consumes<reco::VertexCollection>(conf.getParameter<edm::InputTag>("offlinePrimaryVertices"));
58 
59  beamSpotTag_ = consumes<reco::BeamSpot>(conf.getParameter<edm::InputTag>("beamSpot"));
60  readAOD_ = conf.getParameter<bool>("readAOD");
61 
62  isoFromDepsTk03Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsTk03"));
63  isoFromDepsTk04Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsTk04"));
65  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalFull03"));
67  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalFull04"));
69  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalReduced03"));
71  consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsEcalReduced04"));
72  isoFromDepsHcal03Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsHcal03"));
73  isoFromDepsHcal04Tag_ = consumes<edm::ValueMap<double>>(conf.getParameter<edm::InputTag>("isoFromDepsHcal04"));
74 
75  maxPt_ = conf.getParameter<double>("MaxPt");
76  maxAbsEta_ = conf.getParameter<double>("MaxAbsEta");
77  maxAbsEtaExtended_ = conf.getParameter<double>("MaxAbsEtaExtended");
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  eta_nbin_extended = histosSet.getParameter<int>("NbinetaExtended");
116  eta2D_nbin_extended = histosSet.getParameter<int>("Nbineta2DExtended");
117  eta_min_extended = histosSet.getParameter<double>("EtaminExtended");
118  eta_max_extended = histosSet.getParameter<double>("EtamaxExtended");
119 
120  deta_nbin = histosSet.getParameter<int>("Nbindeta");
121  deta_min = histosSet.getParameter<double>("Detamin");
122  deta_max = histosSet.getParameter<double>("Detamax");
123 
124  detamatch_nbin = histosSet.getParameter<int>("Nbindetamatch");
125  detamatch2D_nbin = histosSet.getParameter<int>("Nbindetamatch2D");
126  detamatch_min = histosSet.getParameter<double>("Detamatchmin");
127  detamatch_max = histosSet.getParameter<double>("Detamatchmax");
128 
129  phi_nbin = histosSet.getParameter<int>("Nbinphi");
130  phi2D_nbin = histosSet.getParameter<int>("Nbinphi2D");
131  phi_min = histosSet.getParameter<double>("Phimin");
132  phi_max = histosSet.getParameter<double>("Phimax");
133 
134  dphi_nbin = histosSet.getParameter<int>("Nbindphi");
135  dphi_min = histosSet.getParameter<double>("Dphimin");
136  dphi_max = histosSet.getParameter<double>("Dphimax");
137 
138  dphimatch_nbin = histosSet.getParameter<int>("Nbindphimatch");
139  dphimatch2D_nbin = histosSet.getParameter<int>("Nbindphimatch2D");
140  dphimatch_min = histosSet.getParameter<double>("Dphimatchmin");
141  dphimatch_max = histosSet.getParameter<double>("Dphimatchmax");
142 
143  mee_nbin = histosSet.getParameter<int>("Nbinmee");
144  mee_min = histosSet.getParameter<double>("Meemin");
145  mee_max = histosSet.getParameter<double>("Meemax");
146 
147  hoe_nbin = histosSet.getParameter<int>("Nbinhoe");
148  hoe_min = histosSet.getParameter<double>("Hoemin");
149  hoe_max = histosSet.getParameter<double>("Hoemax");
150 
151  popmatching_nbin = histosSet.getParameter<int>("Nbinpopmatching");
152  popmatching_min = histosSet.getParameter<double>("Popmatchingmin");
153  popmatching_max = histosSet.getParameter<double>("Popmatchingmax");
154 
155  set_EfficiencyFlag = histosSet.getParameter<bool>("EfficiencyFlag");
156  set_StatOverflowFlag = histosSet.getParameter<bool>("StatOverflowFlag");
157 
158  opv_nbin = histosSet.getParameter<int>("NbinOPV");
159  opv_min = histosSet.getParameter<double>("OPV_min");
160  opv_max = histosSet.getParameter<double>("OPV_max");
161 
162  ele_nbin = histosSet.getParameter<int>("NbinELE");
163  ele_min = histosSet.getParameter<double>("ELE_min");
164  ele_max = histosSet.getParameter<double>("ELE_max");
165 
166  core_nbin = histosSet.getParameter<int>("NbinCORE");
167  core_min = histosSet.getParameter<double>("CORE_min");
168  core_max = histosSet.getParameter<double>("CORE_max");
169 
170  track_nbin = histosSet.getParameter<int>("NbinTRACK");
171  track_min = histosSet.getParameter<double>("TRACK_min");
172  track_max = histosSet.getParameter<double>("TRACK_max");
173 
174  seed_nbin = histosSet.getParameter<int>("NbinSEED");
175  seed_min = histosSet.getParameter<double>("SEED_min");
176  seed_max = histosSet.getParameter<double>("SEED_max");
177 
178  // so to please coverity
179  h1_matchingObjectNum = nullptr;
180  h1_recEleNum_ = nullptr;
181  h1_recCoreNum_ = nullptr;
182  h1_recTrackNum_ = nullptr;
183  h1_recSeedNum_ = nullptr;
184  h1_recOfflineVertices_ = nullptr;
185 
186  h1_matchingObjectEta = nullptr;
188  h1_matchingObjectAbsEta = nullptr;
190  h1_matchingObjectP = nullptr;
191  h1_matchingObjectPt = nullptr;
192  h1_matchingObjectPhi = nullptr;
193  h1_matchingObjectZ = nullptr;
194 
195  h1_ele_EoverP_all = nullptr;
196  h1_ele_EseedOP_all = nullptr;
197  h1_ele_EoPout_all = nullptr;
198  h1_ele_EeleOPout_all = nullptr;
199  h1_ele_dEtaSc_propVtx_all = nullptr;
200  h1_ele_dPhiSc_propVtx_all = nullptr;
201  h1_ele_dEtaCl_propOut_all = nullptr;
202  h1_ele_dPhiCl_propOut_all = nullptr;
203  h1_ele_TIP_all = nullptr;
204  h1_ele_HoE_all = nullptr;
205  h1_ele_vertexEta_all = nullptr;
206  h1_ele_vertexPt_all = nullptr;
207  h1_ele_mee_all = nullptr;
208  h1_ele_mee_os = nullptr;
209 
210  h2_ele_E2mnE1vsMee_all = nullptr;
211  h2_ele_E2mnE1vsMee_egeg_all = nullptr;
212 
220 
221  h1_ele_charge = nullptr;
222  h2_ele_chargeVsEta = nullptr;
223  h2_ele_chargeVsPhi = nullptr;
224  h2_ele_chargeVsPt = nullptr;
225  h1_ele_vertexP = nullptr;
226  h1_ele_vertexPt = nullptr;
227  h2_ele_vertexPtVsEta = nullptr;
228  h2_ele_vertexPtVsPhi = nullptr;
229  h1_ele_vertexEta = nullptr;
230  h2_ele_vertexEtaVsPhi = nullptr;
231  h1_ele_vertexAbsEta = nullptr;
232  h1_ele_vertexPhi = nullptr;
233  h1_ele_vertexX = nullptr;
234  h1_ele_vertexY = nullptr;
235  h1_ele_vertexZ = nullptr;
236  h1_ele_vertexTIP = nullptr;
237  h2_ele_vertexTIPVsEta = nullptr;
238  h2_ele_vertexTIPVsPhi = nullptr;
239  h2_ele_vertexTIPVsPt = nullptr;
240 
241  h1_ele_PoPmatchingObject = nullptr;
247 
257 
258  h1_scl_En_ = nullptr;
261  h1_scl_Et_ = nullptr;
262  h2_scl_EtVsEta_ = nullptr;
263  h2_scl_EtVsPhi_ = nullptr;
264  h2_scl_EtaVsPhi_ = nullptr;
265  h1_scl_Eta_ = nullptr;
266  h1_scl_Phi_ = nullptr;
267 
268  h1_scl_SigIEtaIEta_ = nullptr;
269  h1_scl_SigIEtaIEta_barrel_ = nullptr;
270  h1_scl_SigIEtaIEta_endcaps_ = nullptr;
275  h1_scl_E1x5_ = nullptr;
276  h1_scl_E1x5_barrel_ = nullptr;
277  h1_scl_E1x5_endcaps_ = nullptr;
278  h1_scl_E2x5max_ = nullptr;
279  h1_scl_E2x5max_barrel_ = nullptr;
280  h1_scl_E2x5max_endcaps_ = nullptr;
281  h1_scl_E5x5_ = nullptr;
282  h1_scl_E5x5_barrel_ = nullptr;
283  h1_scl_E5x5_endcaps_ = nullptr;
284 
285  h1_ele_ambiguousTracks = nullptr;
286  h2_ele_ambiguousTracksVsEta = nullptr;
287  h2_ele_ambiguousTracksVsPhi = nullptr;
288  h2_ele_ambiguousTracksVsPt = nullptr;
289  h1_ele_foundHits = nullptr;
290  h1_ele_foundHits_barrel = nullptr;
291  h1_ele_foundHits_endcaps = nullptr;
293  h2_ele_foundHitsVsPhi = nullptr;
294  h2_ele_foundHitsVsPt = nullptr;
295  h1_ele_lostHits = nullptr;
296  h1_ele_lostHits_barrel = nullptr;
297  h1_ele_lostHits_endcaps = nullptr;
298  h2_ele_lostHitsVsEta = nullptr;
299  h2_ele_lostHitsVsPhi = nullptr;
300  h2_ele_lostHitsVsPt = nullptr;
301  h1_ele_chi2 = nullptr;
302  h1_ele_chi2_barrel = nullptr;
303  h1_ele_chi2_endcaps = nullptr;
304  h2_ele_chi2VsEta = nullptr;
305  h2_ele_chi2VsPhi = nullptr;
306  h2_ele_chi2VsPt = nullptr;
307 
308  h1_ele_PinMnPout = nullptr;
309  h1_ele_PinMnPout_mode = nullptr;
310  h2_ele_PinMnPoutVsEta_mode = nullptr;
311  h2_ele_PinMnPoutVsPhi_mode = nullptr;
312  h2_ele_PinMnPoutVsPt_mode = nullptr;
313  h2_ele_PinMnPoutVsE_mode = nullptr;
314  h2_ele_PinMnPoutVsChi2_mode = nullptr;
315 
316  h1_ele_outerP = nullptr;
317  h1_ele_outerP_mode = nullptr;
318  h2_ele_outerPVsEta_mode = nullptr;
319  h1_ele_outerPt = nullptr;
320  h1_ele_outerPt_mode = nullptr;
321  h2_ele_outerPtVsEta_mode = nullptr;
322  h2_ele_outerPtVsPhi_mode = nullptr;
323  h2_ele_outerPtVsPt_mode = nullptr;
324  h1_ele_EoP = nullptr;
325  h1_ele_EoP_barrel = nullptr;
326  h1_ele_EoP_endcaps = nullptr;
327  h2_ele_EoPVsEta_Extended = nullptr;
328  h2_ele_EoPVsPhi = nullptr;
329  h2_ele_EoPVsE = nullptr;
330  h1_ele_EseedOP = nullptr;
331  h1_ele_EseedOP_barrel = nullptr;
332  h1_ele_EseedOP_endcaps = nullptr;
333  h2_ele_EseedOPVsEta = nullptr;
334  h2_ele_EseedOPVsPhi = nullptr;
335  h2_ele_EseedOPVsE = nullptr;
336  h1_ele_EoPout = nullptr;
337  h1_ele_EoPout_barrel = nullptr;
338  h1_ele_EoPout_endcaps = nullptr;
339  h2_ele_EoPoutVsEta = nullptr;
340  h2_ele_EoPoutVsPhi = nullptr;
341  h2_ele_EoPoutVsE = nullptr;
342  h1_ele_EeleOPout = nullptr;
343  h1_ele_EeleOPout_barrel = nullptr;
344  h1_ele_EeleOPout_endcaps = nullptr;
345  h2_ele_EeleOPoutVsEta = nullptr;
346  h2_ele_EeleOPoutVsPhi = nullptr;
347  h2_ele_EeleOPoutVsE = nullptr;
348 
349  h1_ele_dEtaSc_propVtx = nullptr;
353  h2_ele_dEtaScVsEta_propVtx = nullptr;
354  h2_ele_dEtaScVsPhi_propVtx = nullptr;
355  h2_ele_dEtaScVsPt_propVtx = nullptr;
356  h1_ele_dPhiSc_propVtx = nullptr;
360  h2_ele_dPhiScVsEta_propVtx = nullptr;
361  h2_ele_dPhiScVsPhi_propVtx = nullptr;
362  h2_ele_dPhiScVsPt_propVtx = nullptr;
363  h1_ele_dEtaCl_propOut = nullptr;
366  h2_ele_dEtaClVsEta_propOut = nullptr;
367  h2_ele_dEtaClVsPhi_propOut = nullptr;
368  h2_ele_dEtaClVsPt_propOut = nullptr;
369  h1_ele_dPhiCl_propOut = nullptr;
372  h2_ele_dPhiClVsEta_propOut = nullptr;
373  h2_ele_dPhiClVsPhi_propOut = nullptr;
374  h2_ele_dPhiClVsPt_propOut = nullptr;
375  h1_ele_dEtaEleCl_propOut = nullptr;
381  h1_ele_dPhiEleCl_propOut = nullptr;
387 
388  h1_ele_seed_subdet2_ = nullptr;
389  h1_ele_seed_mask_ = nullptr;
390  h1_ele_seed_mask_bpix_ = nullptr;
391  h1_ele_seed_mask_fpix_ = nullptr;
392  h1_ele_seed_mask_tec_ = nullptr;
393  h1_ele_seed_dphi2_ = nullptr;
394  h2_ele_seed_dphi2VsEta_ = nullptr;
395  h2_ele_seed_dphi2VsPt_ = nullptr;
396  h1_ele_seed_dphi2pos_ = nullptr;
397  h2_ele_seed_dphi2posVsEta_ = nullptr;
398  h2_ele_seed_dphi2posVsPt_ = nullptr;
399  h1_ele_seed_drz2_ = nullptr;
400  h2_ele_seed_drz2VsEta_ = nullptr;
401  h2_ele_seed_drz2VsPt_ = nullptr;
402  h1_ele_seed_drz2pos_ = nullptr;
403  h2_ele_seed_drz2posVsEta_ = nullptr;
404  h2_ele_seed_drz2posVsPt_ = nullptr;
405 
406  h1_ele_classes = nullptr;
407  h1_ele_eta = nullptr;
408  h1_ele_eta_golden = nullptr;
409  h1_ele_eta_bbrem = nullptr;
410  h1_ele_eta_narrow = nullptr;
411  h1_ele_eta_shower = nullptr;
412 
413  h1_ele_HoE = nullptr;
414  h1_ele_HoE_Extended = nullptr;
415  h1_ele_HoE_barrel = nullptr;
416  h1_ele_HoE_endcaps = nullptr;
417  h1_ele_HoE_fiducial = nullptr;
418  h2_ele_HoEVsEta = nullptr;
419  h2_ele_HoEVsPhi = nullptr;
420  h2_ele_HoEVsE = nullptr;
421  h1_scl_ESFrac_endcaps = nullptr;
422 
423  h1_ele_fbrem = nullptr;
424  h1_ele_fbrem_Extended = nullptr;
425  p1_ele_fbremVsEta_mode = nullptr;
426  p1_ele_fbremVsEta_mean = nullptr;
427  h1_ele_superclusterfbrem = nullptr;
430  h2_ele_PinVsPoutGolden_mode = nullptr;
432  h2_ele_PinVsPoutGolden_mean = nullptr;
442 
443  h1_ele_mva = nullptr;
444  h1_ele_mva_isolated = nullptr;
445  h1_ele_provenance = nullptr;
446  h1_ele_provenance_Extended = nullptr;
447 
456  h1_ele_photonRelativeIso = nullptr;
460 
461  h1_ele_tkSumPt_dr03 = nullptr;
462  h1_ele_tkSumPt_dr03_barrel = nullptr;
463  h1_ele_tkSumPt_dr03_endcaps = nullptr;
464  h1_ele_ecalRecHitSumEt_dr03 = nullptr;
471 
472  h1_ele_ecalPFClusterIso = nullptr;
473  h1_ele_hcalPFClusterIso = nullptr;
480 
481  h1_ele_convFlags = nullptr;
482  h1_ele_convFlags_all = nullptr;
483  h1_ele_convDist = nullptr;
484  h1_ele_convDist_all = nullptr;
485  h1_ele_convDcot = nullptr;
486  h1_ele_convDcot_all = nullptr;
487  h1_ele_convRadius = nullptr;
488  h1_ele_convRadius_all = nullptr;
489 }
490 
493 
494  setBookIndex(-1);
495  setBookPrefix("h");
498 
499  // matching object type
500  std::string matchingObjectType;
501  matchingObjectType = "GenJet";
502 
503  std::string htitle = "# " + matchingObjectType + "s", xtitle = "N_{" + matchingObjectType + "}";
504  h1_matchingObjectNum = bookH1withSumw2(iBooker, "matchingObjectNum", htitle, fhits_nbin, 0., fhits_max, xtitle);
505 
506  // rec event collections sizes
507  h1_recEleNum_ = bookH1(iBooker, "recEleNum", "# rec electrons", ele_nbin, ele_min, ele_max, "N_{ele}");
508  h1_recCoreNum_ = bookH1(iBooker, "recCoreNum", "# rec electron cores", core_nbin, core_min, core_max, "N_{core}");
509  h1_recTrackNum_ = bookH1(iBooker, "recTrackNum", "# rec gsf tracks", track_nbin, track_min, track_max, "N_{track}");
510  h1_recSeedNum_ = bookH1(iBooker, "recSeedNum", "# rec electron seeds", seed_nbin, seed_min, seed_max, "N_{seed}");
512  iBooker, "recOfflineVertices", "# rec Offline Primary Vertices", opv_nbin, opv_min, opv_max, "N_{Vertices}");
513 
514  // mc
516  bookH1withSumw2(iBooker, "matchingObject_eta", matchingObjectType + " #eta", eta_nbin, eta_min, eta_max, "#eta");
518  "matchingObject_eta_Extended",
519  matchingObjectType + " #eta",
523  "#eta");
525  bookH1withSumw2(iBooker, "matchingObject_abseta", matchingObjectType + " |#eta|", eta_nbin / 2, 0., eta_max);
527  "matchingObject_abseta_Extended",
528  matchingObjectType + " |#eta|",
529  eta_nbin_extended / 2,
530  0.,
533  bookH1withSumw2(iBooker, "matchingObject_P", matchingObjectType + " p", p_nbin, 0., p_max, "p (GeV/c)");
535  bookH1withSumw2(iBooker, "matchingObject_Pt", matchingObjectType + " pt", pteff_nbin, 5., pt_max);
537  bookH1withSumw2(iBooker, "matchingObject_phi", matchingObjectType + " phi", phi_nbin, phi_min, phi_max);
538  h1_matchingObjectZ = bookH1withSumw2(iBooker, "matchingObject_z", matchingObjectType + " z", xyz_nbin, -25, 25);
539 
540  setBookPrefix("h_ele");
541 
542  // all electrons
544  "EoverP_all",
545  "ele E/P_{vertex}, all reco electrons",
546  eop_nbin,
547  0.,
548  eop_max,
549  "E/P_{vertex}",
550  "Events",
551  "ELE_LOGY E1 P");
553  "EseedOP_all",
554  "ele E_{seed}/P_{vertex}, all reco electrons",
555  eop_nbin,
556  0.,
557  eop_max,
558  "E_{seed}/P_{vertex}",
559  "Events",
560  "ELE_LOGY E1 P");
562  "EoPout_all",
563  "ele E_{seed}/P_{out}, all reco electrons",
564  eop_nbin,
565  0.,
566  eop_max,
567  "E_{seed}/P_{out}",
568  "Events",
569  "ELE_LOGY E1 P");
571  "EeleOPout_all",
572  "ele E_{ele}/P_{out}, all reco electrons",
573  eop_nbin,
574  0.,
575  eop_max,
576  "E_{ele}/P_{out}",
577  "Events",
578  "ELE_LOGY E1 P");
580  "dEtaSc_propVtx_all",
581  "ele #eta_{sc} - #eta_{tr}, prop from vertex, all reco electrons",
585  "#eta_{sc} - #eta_{tr}",
586  "Events",
587  "ELE_LOGY E1 P");
589  "dPhiSc_propVtx_all",
590  "ele #phi_{sc} - #phi_{tr}, prop from vertex, all reco electrons",
594  "#phi_{sc} - #phi_{tr} (rad)",
595  "Events",
596  "ELE_LOGY E1 P");
598  "dEtaCl_propOut_all",
599  "ele #eta_{cl} - #eta_{tr}, prop from outermost, all reco electrons",
603  "#eta_{sc} - #eta_{tr}",
604  "Events",
605  "ELE_LOGY E1 P");
607  "dPhiCl_propOut_all",
608  "ele #phi_{cl} - #phi_{tr}, prop from outermost, all reco electrons",
612  "#phi_{sc} - #phi_{tr} (rad)",
613  "Events",
614  "ELE_LOGY E1 P");
616  "TIP_all",
617  "ele vertex transverse radius, all reco electrons",
618  100,
619  0.,
620  0.2,
621  "r_{T} (cm)",
622  "Events",
623  "ELE_LOGY E1 P");
625  "HoE_all",
626  "ele hadronic energy / em energy, all reco electrons",
627  hoe_nbin,
628  hoe_min,
629  hoe_max,
630  "H/E",
631  "Events",
632  "ELE_LOGY E1 P");
634  "HoE_bc_all",
635  "ele hadronic energy / em energy, all reco electrons, behind cluster",
636  hoe_nbin,
637  hoe_min,
638  hoe_max,
639  "H/E",
640  "Events",
641  "ELE_LOGY E1 P");
643  iBooker, "vertexEta_all", "ele eta, all reco electrons", eta_nbin, eta_min, eta_max, "", "Events");
645  bookH1withSumw2(iBooker, "vertexPt_all", "ele p_{T}, all reco electrons", pteff_nbin, 5., pt_max, "", "Events");
647  "mee_all",
648  "ele pairs invariant mass, all reco electrons",
649  mee_nbin,
650  mee_min,
651  mee_max,
652  "m_{ee} (GeV/c^{2})");
653  h1_ele_mee_os = bookH1withSumw2(iBooker,
654  "mee_os",
655  "ele pairs invariant mass, opp. sign",
656  mee_nbin,
657  mee_min,
658  mee_max,
659  "m_{e^{+}e^{-}} (GeV/c^{2})");
660 
661  // duplicates
662  h2_ele_E2mnE1vsMee_all = bookH2(iBooker,
663  "E2mnE1vsMee_all",
664  "E2 - E1 vs ele pairs invariant mass, all electrons",
665  mee_nbin,
666  mee_min,
667  mee_max,
668  100,
669  -50.,
670  50.,
671  "m_{e^{+}e^{-}} (GeV/c^{2})",
672  "E2 - E1 (GeV)");
674  "E2mnE1vsMee_egeg_all",
675  "E2 - E1 vs ele pairs invariant mass, ecal driven pairs, all electrons",
676  mee_nbin,
677  mee_min,
678  mee_max,
679  100,
680  -50.,
681  50.,
682  "m_{e^{+}e^{-}} (GeV/c^{2})",
683  "E2 - E1 (GeV)");
684 
685  // matched electrons
686 
687  htitle = "Efficiency vs matching " + matchingObjectType + " ";
689  bookH1withSumw2(iBooker, "matchingObjectEta_matched", htitle + "#eta", eta_nbin, eta_min, eta_max);
691  "matchingObjectEta_Extended_matched",
692  htitle + "#eta",
697  bookH1withSumw2(iBooker, "matchingObjectAbsEta_matched", htitle + "|#eta|", eta_nbin / 2, 0., eta_max);
699  iBooker, "matchingObjectAbsEta_Extended_matched", htitle + "|#eta|", eta_nbin_extended / 2, 0., eta_max_extended);
701  bookH1(iBooker, "matchingObjectPt_matched", htitle + "p_{T}", pteff_nbin, 5., pt_max);
703  bookH1withSumw2(iBooker, "matchingObjectPhi_matched", htitle + "phi", phi_nbin, phi_min, phi_max);
704  h1_ele_matchingObjectZ_matched = bookH1withSumw2(iBooker, "matchingObjectZ_matched", htitle + "z", xyz_nbin, -25, 25);
705 
706  h1_ele_charge = bookH1withSumw2(iBooker, "charge", "ele charge", 5, -2.5, 2.5, "charge");
707  h2_ele_chargeVsEta = bookH2(iBooker, "chargeVsEta", "ele charge vs eta", eta2D_nbin, eta_min, eta_max, 5, -2., 2.);
708  h2_ele_chargeVsPhi = bookH2(iBooker, "chargeVsPhi", "ele charge vs phi", phi2D_nbin, phi_min, phi_max, 5, -2., 2.);
709  h2_ele_chargeVsPt = bookH2(iBooker, "chargeVsPt", "ele charge vs pt", pt_nbin, 0., 100., 5, -2., 2.);
710  h1_ele_vertexP = bookH1withSumw2(iBooker, "vertexP", "ele momentum", p_nbin, 0., p_max, "p_{vertex} (GeV/c)");
712  bookH1withSumw2(iBooker, "vertexPt", "ele transverse momentum", pt_nbin, 0., pt_max, "p_{T vertex} (GeV/c)");
714  iBooker, "vertexPtVsEta", "ele transverse momentum vs eta", eta2D_nbin, eta_min, eta_max, pt2D_nbin, 0., pt_max);
716  iBooker, "vertexPtVsPhi", "ele transverse momentum vs phi", phi2D_nbin, phi_min, phi_max, pt2D_nbin, 0., pt_max);
717  h1_ele_vertexEta = bookH1withSumw2(iBooker, "vertexEta", "ele momentum eta", eta_nbin, eta_min, eta_max, "#eta");
719  iBooker, "vertexEtaVsPhi", "ele momentum eta vs phi", eta2D_nbin, eta_min, eta_max, phi2D_nbin, phi_min, phi_max);
721  bookH1withSumw2(iBooker, "vertexPhi", "ele momentum #phi", phi_nbin, phi_min, phi_max, "#phi (rad)");
722  h1_ele_vertexX = bookH1withSumw2(iBooker, "vertexX", "ele vertex x", xyz_nbin, -0.6, 0.6, "x (cm)");
723  h1_ele_vertexY = bookH1withSumw2(iBooker, "vertexY", "ele vertex y", xyz_nbin, -0.6, 0.6, "y (cm)");
724  h1_ele_vertexZ = bookH1withSumw2(iBooker, "vertexZ", "ele vertex z", xyz_nbin, -25, 25, "z (cm)");
726  "vertexTIP",
727  "ele transverse impact parameter (wrt gen vtx)",
728  90,
729  0.,
730  0.15,
731  "TIP (cm)",
732  "Events",
733  "ELE_LOGY E1 P");
734  h2_ele_vertexTIPVsEta = bookH2(iBooker,
735  "vertexTIPVsEta",
736  "ele transverse impact parameter (wrt gen vtx) vs eta",
737  eta2D_nbin,
738  eta_min,
739  eta_max,
740  45,
741  0.,
742  0.15,
743  "#eta",
744  "TIP (cm)");
745  h2_ele_vertexTIPVsPhi = bookH2(iBooker,
746  "vertexTIPVsPhi",
747  "ele transverse impact parameter (wrt gen vtx) vs phi",
748  phi2D_nbin,
749  phi_min,
750  phi_max,
751  45,
752  0.,
753  0.15,
754  "#phi (rad)",
755  "TIP (cm)");
756  h2_ele_vertexTIPVsPt = bookH2(iBooker,
757  "vertexTIPVsPt",
758  "ele transverse impact parameter (wrt gen vtx) vs transverse momentum",
759  pt2D_nbin,
760  0.,
761  pt_max,
762  45,
763  0.,
764  0.15,
765  "p_{T} (GeV/c)",
766  "TIP (cm)");
767 
768  htitle = "Electron / Matching " + matchingObjectType + ", momemtum";
769  xtitle = "P / P_{" + matchingObjectType + "}";
771  bookH1withSumw2(iBooker, "PoPmatchingObject", htitle, popmatching_nbin, popmatching_min, popmatching_max, xtitle);
773  "PoPmatchingObjectVsEta",
774  htitle + ",vs eta",
775  eta2D_nbin,
776  eta_min,
777  eta_max,
778  50,
782  "PoPmatchingObjectVsPhi",
783  htitle + ",vs phi",
784  phi2D_nbin,
785  phi_min,
786  phi_max,
787  50,
791  iBooker, "PoPmatchingObjectVsPt", htitle + ",vs eta", pt2D_nbin, 0., pt_max, 50, popmatching_min, popmatching_max);
793  "PoPmatchingObject_barrel",
794  htitle + ", barrel",
798  xtitle);
800  "PoPmatchingObject_endcaps",
801  htitle + ", endcaps",
805  xtitle);
806  htitle = "Ele - " + matchingObjectType + ", ";
807  xtitle = "#eta - #eta_{" + matchingObjectType + "}";
809  bookH1withSumw2(iBooker, "EtamatchingObjectEtaTrue", htitle + "eta", deta_nbin, deta_min, deta_max, xtitle);
811  "EtaMnEtamatchingObjectVsEta",
812  htitle + "eta, vs eta",
813  eta2D_nbin,
814  eta_min,
815  eta_max,
816  deta_nbin / 2,
817  deta_min,
818  deta_max);
820  "EtaMnEtamatchingObjectVsPhi",
821  htitle + "eta, vs phi",
822  phi2D_nbin,
823  phi_min,
824  phi_max,
825  deta_nbin / 2,
826  deta_min,
827  deta_max);
829  "EtaMnEtamatchingObjectVsPt",
830  htitle + "eta,, vs pt",
831  pt_nbin,
832  0.,
833  pt_max,
834  deta_nbin / 2,
835  deta_min,
836  deta_max);
837  xtitle = "#phi - #phi_{" + matchingObjectType + "} (rad)";
839  bookH1withSumw2(iBooker, "PhiMnPhimatchingObject", htitle + "phi", dphi_nbin, dphi_min, dphi_max, xtitle);
841  bookH1(iBooker, "PhiMnPhimatchingObject2", htitle + "phi", dphimatch2D_nbin, dphimatch_min, dphimatch_max);
843  "PhiMnPhimatchingObjectVsEta",
844  htitle + "phi, vs eta",
845  eta2D_nbin,
846  eta_min,
847  eta_max,
848  dphi_nbin / 2,
849  dphi_min,
850  dphi_max);
852  "PhiMnPhimatchingObjectVsPhi",
853  htitle + "phi, vs phi",
854  phi2D_nbin,
855  phi_min,
856  phi_max,
857  dphi_nbin / 2,
858  dphi_min,
859  dphi_max);
861  "PhiMnPhimatchingObjectVsPt",
862  htitle + "phi, vs pt",
863  pt2D_nbin,
864  0.,
865  pt_max,
866  dphi_nbin / 2,
867  dphi_min,
868  dphi_max);
869 
870  // matched electron, superclusters
871 
872  setBookPrefix("h_scl");
873 
874  h1_scl_En_ = bookH1withSumw2(iBooker, "energy", "ele supercluster energy", p_nbin, 0., p_max);
875  htitle = "Ele supercluster / " + matchingObjectType + ", energy";
876  xtitle = "E/E_{" + matchingObjectType + "}";
878  bookH1withSumw2(iBooker, "EoEmatchingObject_barrel", htitle + ", barrel", 50, 0.2, 1.2, xtitle);
880  bookH1withSumw2(iBooker, "EoEmatchingObject_endcaps", htitle + ", endcaps", 50, 0.2, 1.2, xtitle);
881  h1_scl_Et_ = bookH1withSumw2(iBooker, "et", "ele supercluster transverse energy", pt_nbin, 0., pt_max);
882  h2_scl_EtVsEta_ = bookH2(iBooker,
883  "etVsEta",
884  "ele supercluster transverse energy vs eta",
885  eta2D_nbin,
886  eta_min,
887  eta_max,
888  pt_nbin,
889  0.,
890  pt_max);
891  h2_scl_EtVsPhi_ = bookH2(iBooker,
892  "etVsPhi",
893  "ele supercluster transverse energy vs phi",
894  phi2D_nbin,
895  phi_min,
896  phi_max,
897  pt_nbin,
898  0.,
899  pt_max);
901  iBooker, "etaVsPhi", "ele supercluster eta vs phi", phi2D_nbin, phi_min, phi_max, eta2D_nbin, eta_min, eta_max);
902  h1_scl_Eta_ = bookH1withSumw2(iBooker, "eta", "ele supercluster eta", eta_nbin, eta_min, eta_max);
903  h1_scl_Phi_ = bookH1withSumw2(iBooker, "phi", "ele supercluster phi", phi_nbin, phi_min, phi_max);
905  "sigietaieta",
906  "ele supercluster sigma ieta ieta",
907  100,
908  0.,
909  0.05,
910  "#sigma_{i#eta i#eta}",
911  "Events",
912  "ELE_LOGY E1 P");
914  "sigietaieta_barrel",
915  "ele supercluster sigma ieta ieta, barrel",
916  100,
917  0.,
918  0.05,
919  "#sigma_{i#eta i#eta}",
920  "Events",
921  "ELE_LOGY E1 P");
923  "sigietaieta_endcaps",
924  "ele supercluster sigma ieta ieta, endcaps",
925  100,
926  0.,
927  0.05,
928  "#sigma_{i#eta i#eta}",
929  "Events",
930  "ELE_LOGY E1 P");
932  "full5x5_sigietaieta",
933  "ele supercluster full5x5 sigma ieta ieta",
934  100,
935  0.,
936  0.05,
937  "#sigma_{i#eta i#eta}",
938  "Events",
939  "ELE_LOGY E1 P");
941  "full5x5_sigietaieta_Extended",
942  "ele supercluster full5x5 sigma ieta ieta, 2.5<|eta|<3",
943  100,
944  0.,
945  0.05,
946  "#sigma_{i#eta i#eta}",
947  "Events",
948  "ELE_LOGY E1 P");
950  "full5x5_sigietaieta_barrel",
951  "ele supercluster full5x5 sigma ieta ieta, barrel",
952  100,
953  0.,
954  0.05,
955  "#sigma_{i#eta i#eta}",
956  "Events",
957  "ELE_LOGY E1 P");
959  "full5x5_sigietaieta_endcaps",
960  "ele supercluster full5x5 sigma ieta ieta, endcaps",
961  100,
962  0.,
963  0.05,
964  "#sigma_{i#eta i#eta}",
965  "Events",
966  "ELE_LOGY E1 P");
968  iBooker, "E1x5", "ele supercluster energy in 1x5", p_nbin, 0., p_max, "E1x5 (GeV)", "Events", "ELE_LOGY E1 P");
970  "E1x5_barrel",
971  "ele supercluster energy in 1x5 barrel",
972  p_nbin,
973  0.,
974  p_max,
975  "E1x5 (GeV)",
976  "Events",
977  "ELE_LOGY E1 P");
979  "E1x5_endcaps",
980  "ele supercluster energy in 1x5 endcaps",
981  p_nbin,
982  0.,
983  p_max,
984  "E1x5 (GeV)",
985  "Events",
986  "ELE_LOGY E1 P");
988  "E2x5max",
989  "ele supercluster energy in 2x5 max",
990  p_nbin,
991  0.,
992  p_max,
993  "E2x5 (GeV)",
994  "Events",
995  "ELE_LOGY E1 P");
997  "E2x5max_barrel",
998  "ele supercluster energy in 2x5 _max barrel",
999  p_nbin,
1000  0.,
1001  p_max,
1002  "E2x5 (GeV)",
1003  "Events",
1004  "ELE_LOGY E1 P");
1006  "E2x5max_endcaps",
1007  "ele supercluster energy in 2x5 _max endcaps",
1008  p_nbin,
1009  0.,
1010  p_max,
1011  "E2x5 (GeV)",
1012  "Events",
1013  "ELE_LOGY E1 P");
1015  iBooker, "E5x5", "ele supercluster energy in 5x5", p_nbin, 0., p_max, "E5x5 (GeV)", "Events", "ELE_LOGY E1 P");
1017  "E5x5_barrel",
1018  "ele supercluster energy in 5x5 barrel",
1019  p_nbin,
1020  0.,
1021  p_max,
1022  "E5x5 (GeV)",
1023  "Events",
1024  "ELE_LOGY E1 P");
1026  "E5x5_endcaps",
1027  "ele supercluster energy in 5x5 endcaps",
1028  p_nbin,
1029  0.,
1030  p_max,
1031  "E5x5 (GeV)",
1032  "Events",
1033  "ELE_LOGY E1 P");
1034 
1035  // matched electron, gsf tracks
1036 
1037  setBookPrefix("h_ele");
1038 
1040  "ambiguousTracks",
1041  "ele # ambiguous tracks",
1042  5,
1043  0.,
1044  5.,
1045  "N_{ambiguous tracks}",
1046  "Events",
1047  "ELE_LOGY E1 P");
1049  iBooker, "ambiguousTracksVsEta", "ele # ambiguous tracks vs eta", eta2D_nbin, eta_min, eta_max, 5, 0., 5.);
1051  iBooker, "ambiguousTracksVsPhi", "ele # ambiguous tracks vs phi", phi2D_nbin, phi_min, phi_max, 5, 0., 5.);
1053  bookH2(iBooker, "ambiguousTracksVsPt", "ele # ambiguous tracks vs pt", pt2D_nbin, 0., pt_max, 5, 0., 5.);
1055  bookH1withSumw2(iBooker, "foundHits", "ele track # found hits", fhits_nbin, 0., fhits_max, "N_{hits}");
1057  "foundHitsVsEta_Extended",
1058  "ele track # found hits vs eta",
1062  fhits_nbin,
1063  0.,
1064  fhits_max);
1065  h2_ele_foundHitsVsPhi = bookH2(iBooker,
1066  "foundHitsVsPhi",
1067  "ele track # found hits vs phi",
1068  phi2D_nbin,
1069  phi_min,
1070  phi_max,
1071  fhits_nbin,
1072  0.,
1073  fhits_max);
1075  iBooker, "foundHitsVsPt", "ele track # found hits vs pt", pt2D_nbin, 0., pt_max, fhits_nbin, 0., fhits_max);
1076  h1_ele_lostHits = bookH1withSumw2(iBooker, "lostHits", "ele track # lost hits", 5, 0., 5., "N_{lost hits}");
1078  iBooker, "lostHitsVsEta", "ele track # lost hits vs eta", eta2D_nbin, eta_min, eta_max, lhits_nbin, 0., lhits_max);
1080  iBooker, "lostHitsVsPhi", "ele track # lost hits vs eta", phi2D_nbin, phi_min, phi_max, lhits_nbin, 0., lhits_max);
1082  bookH2(iBooker, "lostHitsVsPt", "ele track # lost hits vs eta", pt2D_nbin, 0., pt_max, lhits_nbin, 0., lhits_max);
1083  h1_ele_chi2 =
1084  bookH1withSumw2(iBooker, "chi2", "ele track #chi^{2}", 100, 0., 15., "#Chi^{2}", "Events", "ELE_LOGY E1 P");
1086  bookH2(iBooker, "chi2VsEta", "ele track #chi^{2} vs eta", eta2D_nbin, eta_min, eta_max, 50, 0., 15.);
1088  bookH2(iBooker, "chi2VsPhi", "ele track #chi^{2} vs phi", phi2D_nbin, phi_min, phi_max, 50, 0., 15.);
1089  h2_ele_chi2VsPt = bookH2(iBooker, "chi2VsPt", "ele track #chi^{2} vs pt", pt2D_nbin, 0., pt_max, 50, 0., 15.);
1091  "PinMnPout",
1092  "ele track inner p - outer p, mean of GSF components",
1093  p_nbin,
1094  0.,
1095  200.,
1096  "P_{vertex} - P_{out} (GeV/c)");
1098  "PinMnPout_mode",
1099  "ele track inner p - outer p, mode of GSF components",
1100  p_nbin,
1101  0.,
1102  100.,
1103  "P_{vertex} - P_{out}, mode of GSF components (GeV/c)");
1105  "PinMnPoutVsEta_mode",
1106  "ele track inner p - outer p vs eta, mode of GSF components",
1107  eta2D_nbin,
1108  eta_min,
1109  eta_max,
1110  p2D_nbin,
1111  0.,
1112  100.);
1114  "PinMnPoutVsPhi_mode",
1115  "ele track inner p - outer p vs phi, mode of GSF components",
1116  phi2D_nbin,
1117  phi_min,
1118  phi_max,
1119  p2D_nbin,
1120  0.,
1121  100.);
1123  "PinMnPoutVsPt_mode",
1124  "ele track inner p - outer p vs pt, mode of GSF components",
1125  pt2D_nbin,
1126  0.,
1127  pt_max,
1128  p2D_nbin,
1129  0.,
1130  100.);
1131  h2_ele_PinMnPoutVsE_mode = bookH2(iBooker,
1132  "PinMnPoutVsE_mode",
1133  "ele track inner p - outer p vs E, mode of GSF components",
1134  p2D_nbin,
1135  0.,
1136  200.,
1137  p2D_nbin,
1138  0.,
1139  100.);
1141  "PinMnPoutVsChi2_mode",
1142  "ele track inner p - outer p vs track chi2, mode of GSF components",
1143  50,
1144  0.,
1145  20.,
1146  p2D_nbin,
1147  0.,
1148  100.);
1150  iBooker, "outerP", "ele track outer p, mean of GSF components", p_nbin, 0., p_max, "P_{out} (GeV/c)");
1152  iBooker, "outerP_mode", "ele track outer p, mode of GSF components", p_nbin, 0., p_max, "P_{out} (GeV/c)");
1154  bookH2(iBooker, "outerPVsEta_mode", "ele track outer p vs eta mode", eta2D_nbin, eta_min, eta_max, 50, 0., p_max);
1156  iBooker, "outerPt", "ele track outer p_{T}, mean of GSF components", pt_nbin, 0., pt_max, "P_{T out} (GeV/c)");
1158  "outerPt_mode",
1159  "ele track outer p_{T}, mode of GSF components",
1160  pt_nbin,
1161  0.,
1162  pt_max,
1163  "P_{T out} (GeV/c)");
1164  h2_ele_outerPtVsEta_mode = bookH2(iBooker,
1165  "outerPtVsEta_mode",
1166  "ele track outer p_{T} vs eta, mode of GSF components",
1167  eta2D_nbin,
1168  eta_min,
1169  eta_max,
1170  pt2D_nbin,
1171  0.,
1172  pt_max);
1173  h2_ele_outerPtVsPhi_mode = bookH2(iBooker,
1174  "outerPtVsPhi_mode",
1175  "ele track outer p_{T} vs phi, mode of GSF components",
1176  phi2D_nbin,
1177  phi_min,
1178  phi_max,
1179  pt2D_nbin,
1180  0.,
1181  pt_max);
1182  h2_ele_outerPtVsPt_mode = bookH2(iBooker,
1183  "outerPtVsPt_mode",
1184  "ele track outer p_{T} vs pt, mode of GSF components",
1185  pt2D_nbin,
1186  0.,
1187  100.,
1188  pt2D_nbin,
1189  0.,
1190  pt_max);
1191 
1192  // matched electrons, matching
1194  iBooker, "EoP", "ele E/P_{vertex}", eop_nbin, 0., eop_max, "E/P_{vertex}", "Events", "ELE_LOGY E1 P");
1196  "EoP_barrel",
1197  "ele E/P_{vertex} barrel",
1198  eop_nbin,
1199  0.,
1200  eop_max,
1201  "E/P_{vertex}",
1202  "Events",
1203  "ELE_LOGY E1 P");
1205  "EoP_endcaps",
1206  "ele E/P_{vertex} endcaps",
1207  eop_nbin,
1208  0.,
1209  eop_max,
1210  "E/P_{vertex}",
1211  "Events",
1212  "ELE_LOGY E1 P");
1213  h2_ele_EoPVsEta_Extended = bookH2(iBooker,
1214  "EoPVsEta_Extended",
1215  "ele E/P_{vertex} vs eta",
1219  eop2D_nbin,
1220  0.,
1221  eopmaxsht);
1222  h2_ele_EoPVsPhi =
1223  bookH2(iBooker, "EoPVsPhi", "ele E/P_{vertex} vs phi", phi2D_nbin, phi_min, phi_max, eop2D_nbin, 0., eopmaxsht);
1224  h2_ele_EoPVsE = bookH2(iBooker, "EoPVsE", "ele E/P_{vertex} vs E", 50, 0., p_max, 50, 0., 5.);
1225  h1_ele_EseedOP = bookH1withSumw2(iBooker,
1226  "EseedOP",
1227  "ele E_{seed}/P_{vertex}",
1228  eop_nbin,
1229  0.,
1230  eop_max,
1231  "E_{seed}/P_{vertex}",
1232  "Events",
1233  "ELE_LOGY E1 P");
1235  "EseedOP_barrel",
1236  "ele E_{seed}/P_{vertex} barrel",
1237  eop_nbin,
1238  0.,
1239  eop_max,
1240  "E_{seed}/P_{vertex}",
1241  "Events",
1242  "ELE_LOGY E1 P");
1244  "EseedOP_endcaps",
1245  "ele E_{seed}/P_{vertex} endcaps",
1246  eop_nbin,
1247  0.,
1248  eop_max,
1249  "E_{seed}/P_{vertex}",
1250  "Events",
1251  "ELE_LOGY E1 P");
1252  h2_ele_EseedOPVsEta = bookH2(iBooker,
1253  "EseedOPVsEta",
1254  "ele E_{seed}/P_{vertex} vs eta",
1255  eta2D_nbin,
1256  eta_min,
1257  eta_max,
1258  eop2D_nbin,
1259  0.,
1260  eopmaxsht);
1261  h2_ele_EseedOPVsPhi = bookH2(iBooker,
1262  "EseedOPVsPhi",
1263  "ele E_{seed}/P_{vertex} vs phi",
1264  phi2D_nbin,
1265  phi_min,
1266  phi_max,
1267  eop2D_nbin,
1268  0.,
1269  eopmaxsht);
1270  h2_ele_EseedOPVsE = bookH2(iBooker, "EseedOPVsE", "ele E_{seed}/P_{vertex} vs E", 50, 0., p_max, 50, 0., 5.);
1272  iBooker, "EoPout", "ele E_{seed}/P_{out}", eop_nbin, 0., eop_max, "E_{seed}/P_{out}", "Events", "ELE_LOGY E1 P");
1274  "EoPout_barrel",
1275  "ele E_{seed}/P_{out} barrel",
1276  eop_nbin,
1277  0.,
1278  eop_max,
1279  "E_{seed}/P_{out}",
1280  "Events",
1281  "ELE_LOGY E1 P");
1283  "EoPout_endcaps",
1284  "ele E_{seed}/P_{out} endcaps",
1285  eop_nbin,
1286  0.,
1287  eop_max,
1288  "E_{seed}/P_{out}",
1289  "Events",
1290  "ELE_LOGY E1 P");
1292  iBooker, "EoPoutVsEta", "ele E_{seed}/P_{out} vs eta", eta2D_nbin, eta_min, eta_max, eop2D_nbin, 0., eopmaxsht);
1294  iBooker, "EoPoutVsPhi", "ele E_{seed}/P_{out} vs phi", phi2D_nbin, phi_min, phi_max, eop2D_nbin, 0., eopmaxsht);
1296  bookH2(iBooker, "EoPoutVsE", "ele E_{seed}/P_{out} vs E", p2D_nbin, 0., p_max, eop2D_nbin, 0., eopmaxsht);
1298  iBooker, "EeleOPout", "ele E_{ele}/P_{out}", eop_nbin, 0., eop_max, "E_{ele}/P_{out}", "Events", "ELE_LOGY E1 P");
1300  "EeleOPout_barrel",
1301  "ele E_{ele}/P_{out} barrel",
1302  eop_nbin,
1303  0.,
1304  eop_max,
1305  "E_{ele}/P_{out}",
1306  "Events",
1307  "ELE_LOGY E1 P");
1309  "EeleOPout_endcaps",
1310  "ele E_{ele}/P_{out} endcaps",
1311  eop_nbin,
1312  0.,
1313  eop_max,
1314  "E_{ele}/P_{out}",
1315  "Events",
1316  "ELE_LOGY E1 P");
1318  iBooker, "EeleOPoutVsEta", "ele E_{ele}/P_{out} vs eta", eta2D_nbin, eta_min, eta_max, eop2D_nbin, 0., eopmaxsht);
1320  iBooker, "EeleOPoutVsPhi", "ele E_{ele}/P_{out} vs phi", phi2D_nbin, phi_min, phi_max, eop2D_nbin, 0., eopmaxsht);
1322  bookH2(iBooker, "EeleOPoutVsE", "ele E_{ele}/P_{out} vs E", p2D_nbin, 0., p_max, eop2D_nbin, 0., eopmaxsht);
1324  "dEtaSc_propVtx",
1325  "ele #eta_{sc} - #eta_{tr}, prop from vertex",
1327  detamatch_min,
1328  detamatch_max,
1329  "#eta_{sc} - #eta_{tr}",
1330  "Events",
1331  "ELE_LOGY E1 P");
1333  "dEtaSc_propVtx_Extended",
1334  "ele #eta_{sc} - #eta_{tr}, prop from vertex, 2.5<|eta|<3",
1336  detamatch_min,
1337  detamatch_max,
1338  "#eta_{sc} - #eta_{tr}",
1339  "Events",
1340  "ELE_LOGY E1 P");
1342  "dEtaSc_propVtx_barrel",
1343  "ele #eta_{sc} - #eta_{tr}, prop from vertex, barrel",
1345  detamatch_min,
1346  detamatch_max,
1347  "#eta_{sc} - #eta_{tr}",
1348  "Events",
1349  "ELE_LOGY E1 P");
1351  "dEtaSc_propVtx_endcaps",
1352  "ele #eta_{sc} - #eta_{tr}, prop from vertex, endcaps",
1354  detamatch_min,
1355  detamatch_max,
1356  "#eta_{sc} - #eta_{tr}",
1357  "Events",
1358  "ELE_LOGY E1 P");
1360  "dEtaScVsEta_propVtx",
1361  "ele #eta_{sc} - #eta_{tr} vs eta, prop from vertex",
1362  eta2D_nbin,
1363  eta_min,
1364  eta_max,
1366  detamatch_min,
1367  detamatch_max);
1369  "dEtaScVsPhi_propVtx",
1370  "ele #eta_{sc} - #eta_{tr} vs phi, prop from vertex",
1371  phi2D_nbin,
1372  phi_min,
1373  phi_max,
1375  detamatch_min,
1376  detamatch_max);
1378  "dEtaScVsPt_propVtx",
1379  "ele #eta_{sc} - #eta_{tr} vs pt, prop from vertex",
1380  pt2D_nbin,
1381  0.,
1382  pt_max,
1384  detamatch_min,
1385  detamatch_max);
1387  "dPhiSc_propVtx",
1388  "ele #phi_{sc} - #phi_{tr}, prop from vertex",
1390  dphimatch_min,
1391  dphimatch_max,
1392  "#phi_{sc} - #phi_{tr} (rad)",
1393  "Events",
1394  "ELE_LOGY E1 P");
1396  "dPhiSc_propVtx_Extended",
1397  "ele #phi_{sc} - #phi_{tr}, prop from vertex, 2.5<|eta|<3",
1399  dphimatch_min,
1400  dphimatch_max,
1401  "#phi_{sc} - #phi_{tr} (rad)",
1402  "Events",
1403  "ELE_LOGY E1 P");
1405  "dPhiSc_propVtx_barrel",
1406  "ele #phi_{sc} - #phi_{tr}, prop from vertex, barrel",
1408  dphimatch_min,
1409  dphimatch_max,
1410  "#phi_{sc} - #phi_{tr} (rad)",
1411  "Events",
1412  "ELE_LOGY E1 P");
1414  "dPhiSc_propVtx_endcaps",
1415  "ele #phi_{sc} - #phi_{tr}, prop from vertex, endcaps",
1417  dphimatch_min,
1418  dphimatch_max,
1419  "#phi_{sc} - #phi_{tr} (rad)",
1420  "Events",
1421  "ELE_LOGY E1 P");
1423  "dPhiScVsEta_propVtx",
1424  "ele #phi_{sc} - #phi_{tr} vs eta, prop from vertex",
1425  eta2D_nbin,
1426  eta_min,
1427  eta_max,
1429  dphimatch_min,
1430  dphimatch_max);
1432  "dPhiScVsPhi_propVtx",
1433  "ele #phi_{sc} - #phi_{tr} vs phi, prop from vertex",
1434  phi2D_nbin,
1435  phi_min,
1436  phi_max,
1438  dphimatch_min,
1439  dphimatch_max);
1441  "dPhiScVsPt_propVtx",
1442  "ele #phi_{sc} - #phi_{tr} vs pt, prop from vertex",
1443  pt2D_nbin,
1444  0.,
1445  pt_max,
1447  dphimatch_min,
1448  dphimatch_max);
1450  "dEtaCl_propOut",
1451  "ele #eta_{cl} - #eta_{tr}, prop from outermost",
1453  detamatch_min,
1454  detamatch_max,
1455  "#eta_{seedcl} - #eta_{tr}",
1456  "Events",
1457  "ELE_LOGY E1 P");
1459  "dEtaCl_propOut_barrel",
1460  "ele #eta_{cl} - #eta_{tr}, prop from outermost, barrel",
1462  detamatch_min,
1463  detamatch_max,
1464  "#eta_{seedcl} - #eta_{tr}",
1465  "Events",
1466  "ELE_LOGY E1 P");
1468  "dEtaCl_propOut_endcaps",
1469  "ele #eta_{cl} - #eta_{tr}, prop from outermost, endcaps",
1471  detamatch_min,
1472  detamatch_max,
1473  "#eta_{seedcl} - #eta_{tr}",
1474  "Events",
1475  "ELE_LOGY E1 P");
1477  "dEtaClVsEta_propOut",
1478  "ele #eta_{cl} - #eta_{tr} vs eta, prop from out",
1479  eta2D_nbin,
1480  eta_min,
1481  eta_max,
1483  detamatch_min,
1484  detamatch_max);
1486  "dEtaClVsPhi_propOut",
1487  "ele #eta_{cl} - #eta_{tr} vs phi, prop from out",
1488  phi2D_nbin,
1489  phi_min,
1490  phi_max,
1492  detamatch_min,
1493  detamatch_max);
1495  "dEtaScVsPt_propOut",
1496  "ele #eta_{cl} - #eta_{tr} vs pt, prop from out",
1497  pt2D_nbin,
1498  0.,
1499  pt_max,
1501  detamatch_min,
1502  detamatch_max);
1504  "dPhiCl_propOut",
1505  "ele #phi_{cl} - #phi_{tr}, prop from outermost",
1507  dphimatch_min,
1508  dphimatch_max,
1509  "#phi_{seedcl} - #phi_{tr} (rad)",
1510  "Events",
1511  "ELE_LOGY E1 P");
1513  "dPhiCl_propOut_barrel",
1514  "ele #phi_{cl} - #phi_{tr}, prop from outermost, barrel",
1516  dphimatch_min,
1517  dphimatch_max,
1518  "#phi_{seedcl} - #phi_{tr} (rad)",
1519  "Events",
1520  "ELE_LOGY E1 P");
1522  "dPhiCl_propOut_endcaps",
1523  "ele #phi_{cl} - #phi_{tr}, prop from outermost, endcaps",
1525  dphimatch_min,
1526  dphimatch_max,
1527  "#phi_{seedcl} - #phi_{tr} (rad)",
1528  "Events",
1529  "ELE_LOGY E1 P");
1531  "dPhiClVsEta_propOut",
1532  "ele #phi_{cl} - #phi_{tr} vs eta, prop from out",
1533  eta2D_nbin,
1534  eta_min,
1535  eta_max,
1537  dphimatch_min,
1538  dphimatch_max);
1540  "dPhiClVsPhi_propOut",
1541  "ele #phi_{cl} - #phi_{tr} vs phi, prop from out",
1542  phi2D_nbin,
1543  phi_min,
1544  phi_max,
1546  dphimatch_min,
1547  dphimatch_max);
1549  "dPhiSClsPt_propOut",
1550  "ele #phi_{cl} - #phi_{tr} vs pt, prop from out",
1551  pt2D_nbin,
1552  0.,
1553  pt_max,
1555  dphimatch_min,
1556  dphimatch_max);
1558  "dEtaEleCl_propOut",
1559  "ele #eta_{EleCl} - #eta_{tr}, prop from outermost",
1561  detamatch_min,
1562  detamatch_max,
1563  "#eta_{elecl} - #eta_{tr}",
1564  "Events",
1565  "ELE_LOGY E1 P");
1567  "dEtaEleCl_propOut_barrel",
1568  "ele #eta_{EleCl} - #eta_{tr}, prop from outermost, barrel",
1570  detamatch_min,
1571  detamatch_max,
1572  "#eta_{elecl} - #eta_{tr}",
1573  "Events",
1574  "ELE_LOGY E1 P");
1576  "dEtaEleCl_propOut_endcaps",
1577  "ele #eta_{EleCl} - #eta_{tr}, prop from outermost, endcaps",
1579  detamatch_min,
1580  detamatch_max,
1581  "#eta_{elecl} - #eta_{tr}",
1582  "Events",
1583  "ELE_LOGY E1 P");
1585  "dEtaEleClVsEta_propOut",
1586  "ele #eta_{EleCl} - #eta_{tr} vs eta, prop from out",
1587  eta2D_nbin,
1588  eta_min,
1589  eta_max,
1591  detamatch_min,
1592  detamatch_max);
1594  "dEtaEleClVsPhi_propOut",
1595  "ele #eta_{EleCl} - #eta_{tr} vs phi, prop from out",
1596  phi2D_nbin,
1597  phi_min,
1598  phi_max,
1600  detamatch_min,
1601  detamatch_max);
1603  "dEtaScVsPt_propOut",
1604  "ele #eta_{EleCl} - #eta_{tr} vs pt, prop from out",
1605  pt2D_nbin,
1606  0.,
1607  pt_max,
1609  detamatch_min,
1610  detamatch_max);
1612  "dPhiEleCl_propOut",
1613  "ele #phi_{EleCl} - #phi_{tr}, prop from outermost",
1615  dphimatch_min,
1616  dphimatch_max,
1617  "#phi_{elecl} - #phi_{tr} (rad)",
1618  "Events",
1619  "ELE_LOGY E1 P");
1621  "dPhiEleCl_propOut_barrel",
1622  "ele #phi_{EleCl} - #phi_{tr}, prop from outermost, barrel",
1624  dphimatch_min,
1625  dphimatch_max,
1626  "#phi_{elecl} - #phi_{tr} (rad)",
1627  "Events",
1628  "ELE_LOGY E1 P");
1630  "dPhiEleCl_propOut_endcaps",
1631  "ele #phi_{EleCl} - #phi_{tr}, prop from outermost, endcaps",
1633  dphimatch_min,
1634  dphimatch_max,
1635  "#phi_{elecl} - #phi_{tr} (rad)",
1636  "Events",
1637  "ELE_LOGY E1 P");
1639  "dPhiEleClVsEta_propOut",
1640  "ele #phi_{EleCl} - #phi_{tr} vs eta, prop from out",
1641  eta2D_nbin,
1642  eta_min,
1643  eta_max,
1645  dphimatch_min,
1646  dphimatch_max);
1648  "dPhiEleClVsPhi_propOut",
1649  "ele #phi_{EleCl} - #phi_{tr} vs phi, prop from out",
1650  phi2D_nbin,
1651  phi_min,
1652  phi_max,
1654  dphimatch_min,
1655  dphimatch_max);
1657  "dPhiSEleClsPt_propOut",
1658  "ele #phi_{EleCl} - #phi_{tr} vs pt, prop from out",
1659  pt2D_nbin,
1660  0.,
1661  pt_max,
1663  dphimatch_min,
1664  dphimatch_max);
1666  iBooker, "HoE", "ele hadronic energy / em energy", hoe_nbin, hoe_min, hoe_max, "H/E", "Events", "ELE_LOGY E1 P");
1668  "HoE_Extended",
1669  "ele hadronic energy / em energy, 2.5<|eta|<3",
1670  hoe_nbin,
1671  hoe_min,
1672  hoe_max,
1673  "H/E",
1674  "Events",
1675  "ELE_LOGY E1 P");
1677  "HoE_barrel",
1678  "ele hadronic energy / em energy, barrel",
1679  hoe_nbin,
1680  hoe_min,
1681  hoe_max,
1682  "H/E",
1683  "Events",
1684  "ELE_LOGY E1 P");
1686  "HoE_endcaps",
1687  "ele hadronic energy / em energy, endcaps",
1688  hoe_nbin,
1689  hoe_min,
1690  hoe_max,
1691  "H/E",
1692  "Events",
1693  "ELE_LOGY E1 P");
1694  h1_ele_HoE_bc = bookH1withSumw2(iBooker,
1695  "HoE_bc",
1696  "ele hadronic energy / em energy behind cluster",
1697  hoe_nbin,
1698  hoe_min,
1699  hoe_max,
1700  "H/E",
1701  "Events",
1702  "ELE_LOGY E1 P");
1704  "HoE_bc_barrel",
1705  "ele hadronic energy / em energy, behind cluster barrel",
1706  hoe_nbin,
1707  hoe_min,
1708  hoe_max,
1709  "H/E",
1710  "Events",
1711  "ELE_LOGY E1 P");
1713  "HoE_bc_endcaps",
1714  "ele hadronic energy / em energy, behind cluster, endcaps",
1715  hoe_nbin,
1716  hoe_min,
1717  hoe_max,
1718  "H/E",
1719  "Events",
1720  "ELE_LOGY E1 P");
1722  "hcalDepth1OverEcalBc",
1723  "hcalDepth1OverEcalBc",
1724  hoe_nbin,
1725  hoe_min,
1726  hoe_max,
1727  "H/E",
1728  "Events",
1729  "ELE_LOGY E1 P");
1731  "hcalDepth1OverEcalBc_barrel",
1732  "hcalDepth1OverEcalBc_barrel",
1733  hoe_nbin,
1734  hoe_min,
1735  hoe_max,
1736  "H/E",
1737  "Events",
1738  "ELE_LOGY E1 P");
1740  "hcalDepth1OverEcalBc_endcaps",
1741  "hcalDepth1OverEcalBc_endcaps",
1742  hoe_nbin,
1743  hoe_min,
1744  hoe_max,
1745  "H/E",
1746  "Events",
1747  "ELE_LOGY E1 P");
1749  "hcalDepth2OverEcalBc",
1750  "hcalDepth2OverEcalBc",
1751  hoe_nbin,
1752  hoe_min,
1753  hoe_max,
1754  "H/E",
1755  "Events",
1756  "ELE_LOGY E1 P");
1758  "hcalDepth2OverEcalBc_barrel",
1759  "hcalDepth2OverEcalBc_barrel",
1760  hoe_nbin,
1761  hoe_min,
1762  hoe_max,
1763  "H/E",
1764  "Events",
1765  "ELE_LOGY E1 P");
1767  "hcalDepth2OverEcalBc_endcaps",
1768  "hcalDepth2OverEcalBc_endcaps",
1769  hoe_nbin,
1770  hoe_min,
1771  hoe_max,
1772  "H/E",
1773  "Events",
1774  "ELE_LOGY E1 P");
1776  "HoE_fiducial",
1777  "ele hadronic energy / em energy, fiducial region",
1778  hoe_nbin,
1779  hoe_min,
1780  hoe_max,
1781  "H/E",
1782  "Events",
1783  "ELE_LOGY E1 P");
1784  h2_ele_HoEVsEta = bookH2(iBooker,
1785  "HoEVsEta",
1786  "ele hadronic energy / em energy vs eta",
1787  eta_nbin,
1788  eta_min,
1789  eta_max,
1790  hoe_nbin,
1791  hoe_min,
1792  hoe_max);
1793  h2_ele_HoEVsPhi = bookH2(iBooker,
1794  "HoEVsPhi",
1795  "ele hadronic energy / em energy vs phi",
1796  phi2D_nbin,
1797  phi_min,
1798  phi_max,
1799  hoe_nbin,
1800  hoe_min,
1801  hoe_max);
1802  h2_ele_HoEVsE =
1803  bookH2(iBooker, "HoEVsE", "ele hadronic energy / em energy vs E", p_nbin, 0., 300., hoe_nbin, hoe_min, hoe_max);
1804  setBookPrefix("h_scl");
1806  "ESFrac_endcaps",
1807  "Preshower over SC raw energy , endcaps",
1808  100,
1809  0.,
1810  0.8,
1811  "E_{PS} / E^{raw}_{SC}",
1812  "Events",
1813  "ELE_LOGY E1 P");
1814 
1815  // seeds
1816  setBookPrefix("h_ele");
1818  bookH1withSumw2(iBooker, "seedSubdet2", "ele seed subdet 2nd layer", 11, -0.5, 10.5, "2nd hit subdet Id");
1819  h1_ele_seed_mask_ = bookH1withSumw2(iBooker, "seedMask", "ele seed hits mask", 13, -0.5, 12.5);
1821  bookH1withSumw2(iBooker, "seedMask_Bpix", "ele seed hits mask when subdet2 is bpix", 13, -0.5, 12.5);
1823  bookH1withSumw2(iBooker, "seedMask_Fpix", "ele seed hits mask when subdet2 is bpix", 13, -0.5, 12.5);
1825  bookH1withSumw2(iBooker, "seedMask_Tec", "ele seed hits mask when subdet2 is bpix", 13, -0.5, 12.5);
1827  iBooker, "seedDphi2", "ele seed dphi 2nd layer", 50, -0.003, +0.003, "#phi_{hit}-#phi_{pred} (rad)");
1829  iBooker, "seedDphi2_VsEta", "ele seed dphi 2nd layer vs eta", eta2D_nbin, eta_min, eta_max, 50, -0.003, +0.003);
1831  bookH2(iBooker, "seedDphi2_VsPt", "ele seed dphi 2nd layer vs pt", pt2D_nbin, 0., pt_max, 50, -0.003, +0.003);
1833  iBooker, "seedDphi2Pos", "ele seed dphi 2nd layer positron", 50, -0.003, +0.003, "#phi_{hit}-#phi_{pred} (rad)");
1835  "seedDphi2Pos_VsEta",
1836  "ele seed dphi 2nd layer positron vs eta",
1837  eta2D_nbin,
1838  eta_min,
1839  eta_max,
1840  50,
1841  -0.003,
1842  +0.003);
1844  iBooker, "seedDphi2Pos_VsPt", "ele seed dphi 2nd layer positron vs pt", pt2D_nbin, 0., pt_max, 50, -0.003, +0.003);
1846  iBooker, "seedDrz2", "ele seed dr (dz) 2nd layer", 50, -0.03, +0.03, "r(z)_{hit}-r(z)_{pred} (cm)");
1848  iBooker, "seedDrz2_VsEta", "ele seed dr/dz 2nd layer vs eta", eta2D_nbin, eta_min, eta_max, 50, -0.03, +0.03);
1850  bookH2(iBooker, "seedDrz2_VsPt", "ele seed dr/dz 2nd layer vs pt", pt2D_nbin, 0., pt_max, 50, -0.03, +0.03);
1852  iBooker, "seedDrz2Pos", "ele seed dr (dz) 2nd layer positron", 50, -0.03, +0.03, "r(z)_{hit}-r(z)_{pred} (cm)");
1854  "seedDrz2Pos_VsEta",
1855  "ele seed dr/dz 2nd layer positron vs eta",
1856  eta2D_nbin,
1857  eta_min,
1858  eta_max,
1859  50,
1860  -0.03,
1861  +0.03);
1863  iBooker, "seedDrz2Pos_VsPt", "ele seed dr/dz 2nd layer positron vs pt", pt2D_nbin, 0., pt_max, 50, -0.03, +0.03);
1864 
1865  // classes
1866  h1_ele_classes = bookH1withSumw2(iBooker, "classes", "ele classes", 20, 0.0, 20., "class Id");
1867  h1_ele_eta = bookH1withSumw2(iBooker, "eta", "ele electron eta", eta_nbin / 2, 0.0, eta_max);
1868  h1_ele_eta_golden = bookH1withSumw2(iBooker, "eta_golden", "ele electron eta golden", eta_nbin / 2, 0.0, eta_max);
1869  h1_ele_eta_bbrem = bookH1withSumw2(iBooker, "eta_bbrem", "ele electron eta bbrem", eta_nbin / 2, 0.0, eta_max);
1870  h1_ele_eta_shower = bookH1withSumw2(iBooker, "eta_shower", "ele electron eta showering", eta_nbin / 2, 0.0, eta_max);
1872  "PinVsPoutGolden_mode",
1873  "ele track inner p vs outer p vs eta, golden, mode of GSF components",
1874  p2D_nbin,
1875  0.,
1876  p_max,
1877  50,
1878  0.,
1879  p_max);
1881  "PinVsPoutShowering_mode",
1882  "ele track inner p vs outer p vs eta, showering, mode of GSF components",
1883  p2D_nbin,
1884  0.,
1885  p_max,
1886  50,
1887  0.,
1888  p_max);
1890  "PinVsPoutGolden_mean",
1891  "ele track inner p vs outer p vs eta, golden, mean of GSF components",
1892  p2D_nbin,
1893  0.,
1894  p_max,
1895  50,
1896  0.,
1897  p_max);
1899  "PinVsPoutShowering_mean",
1900  "ele track inner p vs outer p vs eta, showering, mean of GSF components",
1901  p2D_nbin,
1902  0.,
1903  p_max,
1904  50,
1905  0.,
1906  p_max);
1908  "PtinVsPtoutGolden_mode",
1909  "ele track inner pt vs outer pt vs eta, golden, mode of GSF components",
1910  pt2D_nbin,
1911  0.,
1912  pt_max,
1913  50,
1914  0.,
1915  pt_max);
1917  "PtinVsPtoutShowering_mode",
1918  "ele track inner pt vs outer pt vs eta, showering, mode of GSF components",
1919  pt2D_nbin,
1920  0.,
1921  pt_max,
1922  50,
1923  0.,
1924  pt_max);
1926  "PtinVsPtoutGolden_mean",
1927  "ele track inner pt vs outer pt vs eta, golden, mean of GSF components",
1928  pt2D_nbin,
1929  0.,
1930  pt_max,
1931  50,
1932  0.,
1933  pt_max);
1935  "PtinVsPtoutShowering_mean",
1936  "ele track inner pt vs outer pt vs eta, showering, mean of GSF components",
1937  pt2D_nbin,
1938  0.,
1939  pt_max,
1940  50,
1941  0.,
1942  pt_max);
1943  setBookPrefix("h_scl");
1945  "EoEmatchingObject_golden_barrel",
1946  "ele supercluster energy / gen energy, golden, barrel",
1949  popmatching_max);
1951  "EoEmatchingObject_golden_endcaps",
1952  "ele supercluster energy / gen energy, golden, endcaps",
1955  popmatching_max);
1957  "EoEmatchingObject_showering_barrel",
1958  "ele supercluster energy / gen energy, showering, barrel",
1961  popmatching_max);
1963  bookH1withSumw2(iBooker,
1964  "EoEmatchingObject_showering_endcaps",
1965  "ele supercluster energy / gen energy, showering, endcaps",
1968  popmatching_max);
1969  setBookPrefix("h_ele");
1970 
1971  // isolation
1973  "tkSumPt_dr03",
1974  "tk isolation sum, dR=0.3",
1975  100,
1976  0.0,
1977  20.,
1978  "TkIsoSum, cone 0.3 (GeV/c)",
1979  "Events",
1980  "ELE_LOGY E1 P");
1982  "tkSumPt_dr03_barrel",
1983  "tk isolation sum, dR=0.3, barrel",
1984  100,
1985  0.0,
1986  20.,
1987  "TkIsoSum, cone 0.3 (GeV/c)",
1988  "Events",
1989  "ELE_LOGY E1 P");
1991  "tkSumPt_dr03_endcaps",
1992  "tk isolation sum, dR=0.3, endcaps",
1993  100,
1994  0.0,
1995  20.,
1996  "TkIsoSum, cone 0.3 (GeV/c)",
1997  "Events",
1998  "ELE_LOGY E1 P");
2000  "ecalRecHitSumEt_dr03",
2001  "ecal isolation sum, dR=0.3",
2002  100,
2003  0.0,
2004  20.,
2005  "EcalIsoSum, cone 0.3 (GeV)",
2006  "Events",
2007  "ELE_LOGY E1 P");
2009  "ecalRecHitSumEt_dr03_barrel",
2010  "ecal isolation sum, dR=0.3, barrel",
2011  100,
2012  0.0,
2013  20.,
2014  "EcalIsoSum, cone 0.3 (GeV)",
2015  "Events",
2016  "ELE_LOGY E1 P");
2018  "ecalRecHitSumEt_dr03_endcaps",
2019  "ecal isolation sum, dR=0.3, endcaps",
2020  100,
2021  0.0,
2022  20.,
2023  "EcalIsoSum, cone 0.3 (GeV)",
2024  "Events",
2025  "ELE_LOGY E1 P");
2027  "hcalTowerSumEt_dr03_depth1",
2028  "hcal depth1 isolation sum, dR=0.3",
2029  100,
2030  0.0,
2031  20.,
2032  "Hcal1IsoSum, cone 0.3 (GeV)",
2033  "Events",
2034  "ELE_LOGY E1 P");
2036  "hcalTowerSumEt_dr03_depth1_barrel",
2037  "hcal depth1 isolation sum, dR=0.3, barrel",
2038  100,
2039  0.0,
2040  20.,
2041  "Hcal1IsoSum, cone 0.3 (GeV)",
2042  "Events",
2043  "ELE_LOGY E1 P");
2045  "hcalTowerSumEt_dr03_depth1_endcaps",
2046  "hcal depth1 isolation sum, dR=0.3, endcaps",
2047  100,
2048  0.0,
2049  20.,
2050  "Hcal1IsoSum, cone 0.3 (GeV)",
2051  "Events",
2052  "ELE_LOGY E1 P");
2054  "hcalTowerSumEt_dr03_depth2",
2055  "hcal depth2 isolation sum, dR=0.3",
2056  100,
2057  0.0,
2058  20.,
2059  "Hcal2IsoSum, cone 0.3 (GeV)",
2060  "Events",
2061  "ELE_LOGY E1 P");
2062 
2063  // newHCAL
2064  // isolation new hcal
2066  "hcalTowerSumEtBc_dr03_depth1",
2067  "hcal depth1 isolation sum behind cluster, dR=0.3",
2068  100,
2069  0.0,
2070  20.,
2071  "Hcal1IsoSum, cone 0.3 (GeV)",
2072  "Events",
2073  "ELE_LOGY E1 P");
2075  bookH1withSumw2(iBooker,
2076  "hcalTowerSumEtBc_dr03_depth1_barrel",
2077  "hcal depth1 isolation sum behind cluster, dR=0.3, barrel",
2078  100,
2079  0.0,
2080  20.,
2081  "Hcal1IsoSum, cone 0.3 (GeV)",
2082  "Events",
2083  "ELE_LOGY E1 P");
2085  bookH1withSumw2(iBooker,
2086  "hcalTowerSumEtBc_dr03_depth1_endcaps",
2087  "hcal depth1 isolation sum behind cluster, dR=0.3, endcaps",
2088  100,
2089  0.0,
2090  20.,
2091  "Hcal1IsoSum, cone 0.3 (GeV)",
2092  "Events",
2093  "ELE_LOGY E1 P");
2094 
2096  "hcalTowerSumEtBc_dr03_depth2",
2097  "hcal depth2 isolation sum behind cluster, dR=0.3",
2098  100,
2099  0.0,
2100  20.,
2101  "Hcal1IsoSum, cone 0.3 (GeV)",
2102  "Events",
2103  "ELE_LOGY E1 P");
2105  bookH1withSumw2(iBooker,
2106  "hcalTowerSumEtBc_dr03_depth2_barrel",
2107  "hcal depth2 isolation sum behind cluster, dR=0.3, barrel",
2108  100,
2109  0.0,
2110  20.,
2111  "Hcal1IsoSum, cone 0.3 (GeV)",
2112  "Events",
2113  "ELE_LOGY E1 P");
2115  bookH1withSumw2(iBooker,
2116  "hcalTowerSumEtBc_dr03_depth2_endcaps",
2117  "hcal depth2 isolation sum behind cluster, dR=0.3, endcaps",
2118  100,
2119  0.0,
2120  20.,
2121  "Hcal1IsoSum, cone 0.3 (GeV)",
2122  "Events",
2123  "ELE_LOGY E1 P");
2124 
2126  "ecalPFClusterIso",
2127  "ecal PF Cluster Iso",
2128  100,
2129  0.0,
2130  100.,
2131  "hcal PF Cluser Iso",
2132  "Events",
2133  "ELE_LOGY E1 P");
2135  "ecalPFClusterIso_barrel",
2136  "ecal PF Cluster Iso barrel",
2137  100,
2138  0.0,
2139  100.,
2140  "hcal PF Cluser Iso",
2141  "Events",
2142  "ELE_LOGY E1 P");
2144  "ecalPFClusterIso_endcaps",
2145  "ecal PF Cluster Iso endcaps",
2146  100,
2147  0.0,
2148  100.,
2149  "hcal PF Cluser Iso",
2150  "Events",
2151  "ELE_LOGY E1 P");
2153  "hcalPFClusterIso",
2154  "hcal PF Cluster Iso",
2155  100,
2156  0.0,
2157  100.,
2158  "hcal PF Cluser Iso",
2159  "Events",
2160  "ELE_LOGY E1 P");
2162  "hcalPFClusterIso_barrel",
2163  "hcal PF Cluster Iso barrel",
2164  100,
2165  0.0,
2166  100.,
2167  "hcal PF Cluser Iso",
2168  "Events",
2169  "ELE_LOGY E1 P");
2171  "hcalPFClusterIso_endcaps",
2172  "hcal PF Cluster Iso endcaps",
2173  100,
2174  0.0,
2175  100.,
2176  "hcal PF Cluser Iso",
2177  "Events",
2178  "ELE_LOGY E1 P");
2180  "ecalPFClusterIso_Extended",
2181  "ecal PF Cluster Iso Extended",
2182  100,
2183  0.0,
2184  100.,
2185  "hcal PF Cluser Iso Extended, 2.5<|eta|<3",
2186  "Events",
2187  "ELE_LOGY E1 P");
2189  "hcalPFClusterIso_Extended",
2190  "hcal PF Cluster Iso Extended",
2191  100,
2192  0.0,
2193  100.,
2194  "hcal PF Cluser Iso Extended, 2.5<|eta|<3",
2195  "Events",
2196  "ELE_LOGY E1 P");
2197 
2198  // fbrem
2200  iBooker, "fbrem", "ele brem fraction, mode of GSF components", 100, 0., 1., "P_{in} - P_{out} / P_{in}");
2202  "fbrem_Extended",
2203  "ele brem fraction, mode of GSF components, 2.5<|eta|<3",
2204  100,
2205  0.,
2206  1.,
2207  "P_{in} - P_{out} / P_{in}");
2209  "fbrem_barrel",
2210  "ele brem fraction for barrel, mode of GSF components",
2211  100,
2212  0.,
2213  1.,
2214  "P_{in} - P_{out} / P_{in}");
2216  "fbrem_endcaps",
2217  "ele brem franction for endcaps, mode of GSF components",
2218  100,
2219  0.,
2220  1.,
2221  "P_{in} - P_{out} / P_{in}");
2222  p1_ele_fbremVsEta_mode = bookP1(iBooker,
2223  "fbremvsEtamode",
2224  "mean ele brem fraction vs eta, mode of GSF components",
2225  eta2D_nbin,
2226  eta_min,
2227  eta_max,
2228  0.,
2229  1.,
2230  "#eta",
2231  "<P_{in} - P_{out} / P_{in}>");
2232  p1_ele_fbremVsEta_mean = bookP1(iBooker,
2233  "fbremvsEtamean",
2234  "mean ele brem fraction vs eta, mean of GSF components",
2235  eta2D_nbin,
2236  eta_min,
2237  eta_max,
2238  0.,
2239  1.,
2240  "#eta",
2241  "<P_{in} - P_{out} / P_{in}>");
2243  bookH1withSumw2(iBooker, "superclusterfbrem", "supercluster brem fraction", 100, 0., 1., "1 - E_{ele} / E_{SC}");
2245  iBooker, "superclusterfbrem_barrel", "supercluster brem fraction for barrel", 100, 0., 1., "1 - E_{ele} / E_{SC}");
2247  "superclusterfbrem_endcaps",
2248  "supercluster brem franction for endcaps",
2249  100,
2250  0.,
2251  1.,
2252  "1 - E_{ele} / E_{SC}");
2253  // e/g et pflow electrons
2254  h1_ele_mva = bookH1withSumw2(iBooker, "mva", "ele identification mva", 100, -1., 1.);
2255  h1_ele_mva_barrel = bookH1withSumw2(iBooker, "mva_barrel", "ele identification mva barrel", 100, -1., 1.);
2256  h1_ele_mva_endcaps = bookH1withSumw2(iBooker, "mva_endcaps", "ele identification mva endcaps", 100, -1., 1.);
2257  h1_ele_mva_isolated = bookH1withSumw2(iBooker, "mva_isolated", "ele identification mva isolated", 100, -1., 1.);
2259  bookH1withSumw2(iBooker, "mva_isolated_barrel", "ele identification mva isolated barrel", 100, -1., 1.);
2261  bookH1withSumw2(iBooker, "mva_isolated_endcaps", "ele identification mva isolated endcaps", 100, -1., 1.);
2262  h1_ele_provenance = bookH1withSumw2(iBooker, "provenance", "ele provenance", 5, -2., 3.);
2263  h1_ele_provenance_Extended = bookH1withSumw2(iBooker, "provenance_Extended", "ele provenance_Extended", 5, -2., 3.);
2264  h1_ele_provenance_barrel = bookH1withSumw2(iBooker, "provenance_barrel", "ele provenance barrel", 5, -2., 3.);
2265  h1_ele_provenance_endcaps = bookH1withSumw2(iBooker, "provenance_endcaps", "ele provenance endcaps", 5, -2., 3.);
2266 
2267  // pflow isolation variables
2269  iBooker, "chargedHadronIso", "chargedHadronIso", 100, 0.0, 20., "chargedHadronIso", "Events", "ELE_LOGY E1 P");
2271  "chargedHadronIso_barrel",
2272  "chargedHadronIso for barrel",
2273  100,
2274  0.0,
2275  20.,
2276  "chargedHadronIso_barrel",
2277  "Events",
2278  "ELE_LOGY E1 P");
2280  "chargedHadronIso_endcaps",
2281  "chargedHadronIso for endcaps",
2282  100,
2283  0.0,
2284  20.,
2285  "chargedHadronIso_endcaps",
2286  "Events",
2287  "ELE_LOGY E1 P");
2289  iBooker, "neutralHadronIso", "neutralHadronIso", 21, 0.0, 20., "neutralHadronIso", "Events", "ELE_LOGY E1 P");
2291  "neutralHadronIso_barrel",
2292  "neutralHadronIso for barrel",
2293  21,
2294  0.0,
2295  20.,
2296  "neutralHadronIso_barrel",
2297  "Events",
2298  "ELE_LOGY E1 P");
2300  "neutralHadronIso_endcaps",
2301  "neutralHadronIso for endcaps",
2302  21,
2303  0.0,
2304  20.,
2305  "neutralHadronIso_endcaps",
2306  "Events",
2307  "ELE_LOGY E1 P");
2309  bookH1withSumw2(iBooker, "photonIso", "photonIso", 100, 0.0, 20., "photonIso", "Events", "ELE_LOGY E1 P");
2311  iBooker, "photonIso_barrel", "photonIso for barrel", 100, 0.0, 20., "photonIso_barrel", "Events", "ELE_LOGY E1 P");
2313  "photonIso_endcaps",
2314  "photonIso for endcaps",
2315  100,
2316  0.0,
2317  20.,
2318  "photonIso_endcaps",
2319  "Events",
2320  "ELE_LOGY E1 P");
2321  // -- pflow over pT
2323  "chargedHadronRelativeIso",
2324  "chargedHadronRelativeIso",
2325  100,
2326  0.0,
2327  2.,
2328  "chargedHadronRelativeIso",
2329  "Events",
2330  "ELE_LOGY E1 P");
2332  "chargedHadronRelativeIso_Extended",
2333  "chargedHadronRelativeIso_Extended",
2334  100,
2335  0.0,
2336  2.,
2337  "chargedHadronRelativeIso Extended, 2.5<|eta|<3",
2338  "Events",
2339  "ELE_LOGY E1 P");
2341  "chargedHadronRelativeIso_barrel",
2342  "chargedHadronRelativeIso for barrel",
2343  100,
2344  0.0,
2345  2.,
2346  "chargedHadronRelativeIso_barrel",
2347  "Events",
2348  "ELE_LOGY E1 P");
2350  "chargedHadronRelativeIso_endcaps",
2351  "chargedHadronRelativeIso for endcaps",
2352  100,
2353  0.0,
2354  2.,
2355  "chargedHadronRelativeIso_endcaps",
2356  "Events",
2357  "ELE_LOGY E1 P");
2359  "neutralHadronRelativeIso",
2360  "neutralHadronRelativeIso",
2361  100,
2362  0.0,
2363  2.,
2364  "neutralHadronRelativeIso",
2365  "Events",
2366  "ELE_LOGY E1 P");
2368  "neutralHadronRelativeIso_Extended",
2369  "neutralHadronRelativeIso_Extended",
2370  100,
2371  0.0,
2372  2.,
2373  "neutralHadronRelativeIso Extended, 2.5<|eta|<3",
2374  "Events",
2375  "ELE_LOGY E1 P");
2377  "neutralHadronRelativeIso_barrel",
2378  "neutralHadronRelativeIso for barrel",
2379  100,
2380  0.0,
2381  2.,
2382  "neutralHadronRelativeIso_barrel",
2383  "Events",
2384  "ELE_LOGY E1 P");
2386  "neutralHadronRelativeIso_endcaps",
2387  "neutralHadronRelativeIso for endcaps",
2388  100,
2389  0.0,
2390  2.,
2391  "neutralHadronRelativeIso_endcaps",
2392  "Events",
2393  "ELE_LOGY E1 P");
2395  iBooker, "photonRelativeIso", "photonRelativeIso", 100, 0.0, 2., "photonRelativeIso", "Events", "ELE_LOGY E1 P");
2397  "photonRelativeIso_Extended",
2398  "photonRelativeIso_Extended",
2399  100,
2400  0.0,
2401  2.,
2402  "photonRelativeIso Extended, 2.5<|eta|<3",
2403  "Events",
2404  "ELE_LOGY E1 P");
2406  "photonRelativeIso_barrel",
2407  "photonRelativeIso for barrel",
2408  100,
2409  0.0,
2410  2.,
2411  "photonRelativeIso_barrel",
2412  "Events",
2413  "ELE_LOGY E1 P");
2415  "photonRelativeIso_endcaps",
2416  "photonRelativeIso for endcaps",
2417  100,
2418  0.0,
2419  2.,
2420  "photonRelativeIso_endcaps",
2421  "Events",
2422  "ELE_LOGY E1 P");
2423 
2424  // conversion rejection information
2425  h1_ele_convFlags = bookH1withSumw2(iBooker, "convFlags", "conversion rejection flag", 5, -2.5, 2.5);
2427  bookH1withSumw2(iBooker, "convFlags_all", "conversion rejection flag, all electrons", 5, -2.5, 2.5);
2428  h1_ele_convDist = bookH1withSumw2(iBooker, "convDist", "distance to the conversion partner", 100, -15., 15.);
2430  bookH1withSumw2(iBooker, "convDist_all", "distance to the conversion partner, all electrons", 100, -15., 15.);
2432  iBooker, "convDcot", "difference of cot(angle) with the conversion partner", 100, -CLHEP::pi / 2., CLHEP::pi / 2.);
2434  "convDcot_all",
2435  "difference of cot(angle) with the conversion partner, all electrons",
2436  100,
2437  -CLHEP::pi / 2.,
2438  CLHEP::pi / 2.);
2439  h1_ele_convRadius = bookH1withSumw2(iBooker, "convRadius", "signed conversion radius", 100, 0., 130.);
2441  bookH1withSumw2(iBooker, "convRadius_all", "signed conversion radius, all electrons", 100, 0., 130.);
2442 }
2443 
2445 
2446 //=========================================================================
2447 // Main methods
2448 //=========================================================================
2449 
2451  // get reco electrons
2452  auto gsfElectrons = iEvent.getHandle(electronCollection_);
2453  auto gsfElectronsEndcaps = iEvent.getHandle(electronCollectionEndcaps_);
2454  auto gsfElectronCores = iEvent.getHandle(electronCoreCollection_);
2455  auto gsfElectronTracks = iEvent.getHandle(electronTrackCollection_);
2456  auto gsfElectronSeeds = iEvent.getHandle(electronSeedCollection_);
2457 
2458  // get gen jets
2459  auto genJets = iEvent.getHandle(matchingObjectCollection_);
2460 
2461  // get the beamspot from the Event:
2462  auto recoBeamSpotHandle = iEvent.getHandle(beamSpotTag_);
2463  const BeamSpot &bs = *recoBeamSpotHandle;
2464 
2465  auto isoFromDepsTk03Handle = iEvent.getHandle(isoFromDepsTk03Tag_);
2466  auto isoFromDepsTk04Handle = iEvent.getHandle(isoFromDepsTk04Tag_);
2467  auto isoFromDepsEcalFull03Handle = iEvent.getHandle(isoFromDepsEcalFull03Tag_);
2468  auto isoFromDepsEcalFull04Handle = iEvent.getHandle(isoFromDepsEcalFull04Tag_);
2469  auto isoFromDepsEcalReduced03Handle = iEvent.getHandle(isoFromDepsEcalReduced03Tag_);
2470  auto isoFromDepsEcalReduced04Handle = iEvent.getHandle(isoFromDepsEcalReduced04Tag_);
2471  auto isoFromDepsHcal03Handle = iEvent.getHandle(isoFromDepsHcal03Tag_);
2472  auto isoFromDepsHcal04Handle = iEvent.getHandle(isoFromDepsHcal04Tag_);
2473 
2474  auto vertexCollectionHandle = iEvent.getHandle(offlineVerticesCollection_);
2475  if (!vertexCollectionHandle.isValid()) {
2476  edm::LogInfo("ElectronMcFakeValidator::analyze") << "vertexCollectionHandle KO";
2477  } else {
2478  edm::LogInfo("ElectronMcFakeValidator::analyze") << "vertexCollectionHandle OK";
2479  }
2480 
2481  edm::LogInfo("ElectronMcFakeValidator::analyze")
2482  << "Treating event " << iEvent.id() << " with " << gsfElectrons.product()->size() << " electrons";
2483  edm::LogInfo("ElectronMcSignalValidator::analyze")
2484  << "Treating event " << iEvent.id() << " with " << gsfElectronsEndcaps.product()->size() << " electrons";
2485 
2486  h1_recEleNum_->Fill((*gsfElectrons).size());
2487  h1_recCoreNum_->Fill((*gsfElectronCores).size());
2488  h1_recTrackNum_->Fill((*gsfElectronTracks).size());
2489  h1_recSeedNum_->Fill((*gsfElectronSeeds).size());
2490  h1_recOfflineVertices_->Fill((*vertexCollectionHandle).size());
2491 
2492  reco::GsfElectronCollection::const_iterator gsfIter;
2493  std::vector<reco::GsfElectron>::const_iterator gsfIter3;
2494  std::vector<reco::GsfElectron>::const_iterator gsfIter4;
2495 
2496  //===============================================
2497  // get a vector with EB & EE
2498  //===============================================
2499  std::vector<reco::GsfElectron> localCollection;
2500 
2501  // looking for EB
2502  for (gsfIter = gsfElectrons->begin(); gsfIter != gsfElectrons->end(); gsfIter++) {
2503  if (gsfIter->isEB()) {
2504  localCollection.push_back(*gsfIter);
2505  }
2506  }
2507 
2508  // looking for EE
2509  for (gsfIter = gsfElectronsEndcaps->begin(); gsfIter != gsfElectronsEndcaps->end(); gsfIter++) {
2510  if (gsfIter->isEE()) {
2511  localCollection.push_back(*gsfIter);
2512  }
2513  }
2514 
2515  // all rec electrons
2516  for (gsfIter3 = localCollection.begin(); gsfIter3 != localCollection.end(); gsfIter3++) {
2517  // preselect electrons
2518  if (gsfIter3->pt() > maxPt_ || std::abs(gsfIter3->eta()) > maxAbsEta_)
2519  continue;
2520 
2521  h1_ele_EoverP_all->Fill(gsfIter3->eSuperClusterOverP());
2522  h1_ele_EseedOP_all->Fill(gsfIter3->eSeedClusterOverP());
2523  h1_ele_EoPout_all->Fill(gsfIter3->eSeedClusterOverPout());
2524  h1_ele_EeleOPout_all->Fill(gsfIter3->eEleClusterOverPout());
2525  h1_ele_dEtaSc_propVtx_all->Fill(gsfIter3->deltaEtaSuperClusterTrackAtVtx());
2526  h1_ele_dPhiSc_propVtx_all->Fill(gsfIter3->deltaPhiSuperClusterTrackAtVtx());
2527  h1_ele_dEtaCl_propOut_all->Fill(gsfIter3->deltaEtaSeedClusterTrackAtCalo());
2528  h1_ele_dPhiCl_propOut_all->Fill(gsfIter3->deltaPhiSeedClusterTrackAtCalo());
2529  h1_ele_HoE_all->Fill(gsfIter3->hadronicOverEm());
2530  h1_ele_HoE_bc_all->Fill(gsfIter3->hcalOverEcalBc());
2531  double d = gsfIter3->vertex().x() * gsfIter3->vertex().x() + gsfIter3->vertex().y() * gsfIter3->vertex().y();
2533  h1_ele_vertexEta_all->Fill(gsfIter3->eta());
2534  h1_ele_vertexPt_all->Fill(gsfIter3->pt());
2535  float enrj1 = gsfIter3->ecalEnergy();
2536 
2537  // mee
2538  for (gsfIter4 = gsfIter3 + 1; gsfIter4 != localCollection.end(); gsfIter4++) {
2539  math::XYZTLorentzVector p12 = (*gsfIter3).p4() + (*gsfIter4).p4();
2540  float mee2 = p12.Dot(p12);
2541  h1_ele_mee_all->Fill(sqrt(mee2));
2542  float enrj2 = gsfIter4->ecalEnergy();
2543  h2_ele_E2mnE1vsMee_all->Fill(sqrt(mee2), enrj2 - enrj1);
2544  if (gsfIter3->ecalDrivenSeed() && gsfIter4->ecalDrivenSeed()) {
2545  h2_ele_E2mnE1vsMee_egeg_all->Fill(sqrt(mee2), enrj2 - enrj1);
2546  }
2547  if (gsfIter3->charge() * gsfIter4->charge() < 0.) {
2548  h1_ele_mee_os->Fill(sqrt(mee2));
2549  }
2550  }
2551 
2552  // conversion rejection
2553  int flags = gsfIter3->convFlags();
2554  if (flags == -9999) {
2555  flags = -1;
2556  }
2558  if (flags >= 0.) {
2559  h1_ele_convDist_all->Fill(gsfIter3->convDist());
2560  h1_ele_convDcot_all->Fill(gsfIter3->convDcot());
2561  h1_ele_convRadius_all->Fill(gsfIter3->convRadius());
2562  }
2563  }
2564 
2565  // association matching object-reco electrons
2566  int matchingObjectNum = 0;
2567  reco::GenJetCollection::const_iterator moIter;
2568  for (moIter = genJets->begin(); moIter != genJets->end(); ++moIter) {
2569  // number of matching objects
2570  matchingObjectNum++;
2571 
2572  if (moIter->energy() / cosh(moIter->eta()) > maxPt_ || std::abs(moIter->eta()) > maxAbsEtaExtended_) {
2573  continue;
2574  }
2575 
2576  if (std::abs(moIter->eta()) < maxAbsEta_) {
2577  h1_matchingObjectEta->Fill(moIter->eta());
2578  h1_matchingObjectAbsEta->Fill(std::abs(moIter->eta()));
2580  h1_matchingObjectP->Fill(moIter->energy());
2581  h1_matchingObjectPt->Fill(moIter->energy() / cosh(moIter->eta()));
2582  h1_matchingObjectPhi->Fill(moIter->phi());
2583  h1_matchingObjectZ->Fill(moIter->vz());
2584  }
2585  if (std::abs(moIter->eta()) < maxAbsEtaExtended_) {
2586  h1_matchingObjectEta_Extended->Fill(moIter->eta());
2588  }
2589 
2590  // looking for the best matching gsf electron
2591  bool okGsfFound = false;
2592  double gsfOkRatio = 999999.;
2593  bool isEBflag = false;
2594  bool isEEflag = false;
2595  bool isEEextendedflag = false;
2596 
2597  // find best matched electron
2598  reco::GsfElectron bestGsfElectron;
2599 
2600  for (gsfIter3 = localCollection.begin(); gsfIter3 != localCollection.end(); gsfIter3++) {
2601  double dphi = gsfIter3->phi() - moIter->phi();
2602  if (std::abs(dphi) > CLHEP::pi) {
2603  dphi = dphi < 0 ? (CLHEP::twopi) + dphi : dphi - CLHEP::twopi;
2604  }
2605  double deltaR2 = (gsfIter3->eta() - moIter->eta()) * (gsfIter3->eta() - moIter->eta()) + dphi * dphi;
2606  if (deltaR2 < deltaR2_) {
2607  double tmpGsfRatio = gsfIter3->p() / moIter->energy();
2608  if (std::abs(tmpGsfRatio - 1) < std::abs(gsfOkRatio - 1)) {
2609  gsfOkRatio = tmpGsfRatio;
2610  bestGsfElectron = *gsfIter3;
2611  okGsfFound = true;
2612  }
2613  }
2614  } // loop over rec ele to look for the best one
2615 
2616  // analysis when the matching object is matched by a rec electron
2617 
2618  if (okGsfFound) {
2619  //passMiniAODSelection = bestGsfElectron.pt() >= 5.;
2620  isEBflag = bestGsfElectron.isEB();
2621  isEEflag = bestGsfElectron.isEE() && (std::abs(moIter->eta()) < maxAbsEta_);
2622  isEEextendedflag = bestGsfElectron.isEE();
2623  /*isEBflag = bestGsfElectron.isEB();
2624  isEEflag = bestGsfElectron.isEE();*/
2625 
2626  if (isEEextendedflag) { // Extended flag
2627  if (!isEEflag) {
2631  h2_ele_EoPVsEta_Extended->Fill(bestGsfElectron.eta(), bestGsfElectron.eSuperClusterOverP());
2635  h1_ele_HoE_Extended->Fill(bestGsfElectron.hadronicOverEm());
2637  bestGsfElectron.pt());
2639  bestGsfElectron.pt());
2641  bestGsfElectron.pt());
2644 
2645  double fbrem_mode = bestGsfElectron.fbrem();
2646  h1_ele_fbrem_Extended->Fill(fbrem_mode);
2647  if (!readAOD_) {
2648  if (bestGsfElectron.ecalDrivenSeed()) {
2650  }
2651  if (bestGsfElectron.trackerDrivenSeed()) {
2653  }
2654  if (bestGsfElectron.trackerDrivenSeed() || bestGsfElectron.ecalDrivenSeed()) {
2656  }
2657  if (bestGsfElectron.trackerDrivenSeed() && !bestGsfElectron.ecalDrivenSeed()) {
2659  }
2660  if (!bestGsfElectron.trackerDrivenSeed() && bestGsfElectron.ecalDrivenSeed()) {
2662  }
2663  }
2664  }
2665 
2666  if (!readAOD_) {
2667  h2_ele_foundHitsVsEta_Extended->Fill(bestGsfElectron.eta(), bestGsfElectron.gsfTrack()->numberOfValidHits());
2668  }
2669  }
2670 
2671  if (!isEBflag && !isEEflag)
2672  continue;
2673 
2674  // electron related distributions
2675  h1_ele_charge->Fill(bestGsfElectron.charge());
2676  h2_ele_chargeVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.charge());
2677  h2_ele_chargeVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.charge());
2678  h2_ele_chargeVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.charge());
2679  h1_ele_vertexP->Fill(bestGsfElectron.p());
2680  h1_ele_vertexPt->Fill(bestGsfElectron.pt());
2681  h2_ele_vertexPtVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.pt());
2682  h2_ele_vertexPtVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.pt());
2683  h1_ele_vertexEta->Fill(bestGsfElectron.eta());
2684  // generated distributions for matched electrons
2685  h1_ele_matchingObjectPt_matched->Fill(moIter->energy() / cosh(moIter->eta()));
2686  h1_ele_matchingObjectPhi_matched->Fill(moIter->phi());
2689  h1_ele_matchingObjectEta_matched->Fill(moIter->eta());
2691  h2_ele_vertexEtaVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eta());
2692  h1_ele_vertexPhi->Fill(bestGsfElectron.phi());
2693  h1_ele_vertexX->Fill(bestGsfElectron.vertex().x());
2694  h1_ele_vertexY->Fill(bestGsfElectron.vertex().y());
2695  h1_ele_vertexZ->Fill(bestGsfElectron.vertex().z());
2696  h1_ele_matchingObjectZ_matched->Fill(moIter->vz());
2697  double d =
2698  (bestGsfElectron.vertex().x() - bs.position().x()) * (bestGsfElectron.vertex().x() - bs.position().x()) +
2699  (bestGsfElectron.vertex().y() - bs.position().y()) * (bestGsfElectron.vertex().y() - bs.position().y());
2700  d = sqrt(d);
2702  h2_ele_vertexTIPVsEta->Fill(bestGsfElectron.eta(), d);
2703  h2_ele_vertexTIPVsPhi->Fill(bestGsfElectron.phi(), d);
2704  h2_ele_vertexTIPVsPt->Fill(bestGsfElectron.pt(), d);
2705  h1_ele_EtaMnEtamatchingObject->Fill(bestGsfElectron.eta() - moIter->eta());
2706  h2_ele_EtaMnEtamatchingObjectVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eta() - moIter->eta());
2707  h2_ele_EtaMnEtamatchingObjectVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eta() - moIter->eta());
2708  h2_ele_EtaMnEtamatchingObjectVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.eta() - moIter->eta());
2709  h1_ele_PhiMnPhimatchingObject->Fill(bestGsfElectron.phi() - moIter->phi());
2710  h1_ele_PhiMnPhimatchingObject2->Fill(bestGsfElectron.phi() - moIter->phi());
2711  h2_ele_PhiMnPhimatchingObjectVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.phi() - moIter->phi());
2712  h2_ele_PhiMnPhimatchingObjectVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.phi() - moIter->phi());
2713  h2_ele_PhiMnPhimatchingObjectVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.phi() - moIter->phi());
2714  h1_ele_PoPmatchingObject->Fill(bestGsfElectron.p() / moIter->energy());
2715  h2_ele_PoPmatchingObjectVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.p() / moIter->energy());
2716  h2_ele_PoPmatchingObjectVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.p() / moIter->energy());
2717  h2_ele_PoPmatchingObjectVsPt->Fill(bestGsfElectron.py(), bestGsfElectron.p() / moIter->energy());
2718  if (isEBflag)
2719  h1_ele_PoPmatchingObject_barrel->Fill(bestGsfElectron.p() / moIter->energy());
2720  else if (isEEflag)
2721  h1_ele_PoPmatchingObject_endcaps->Fill(bestGsfElectron.p() / moIter->energy());
2722 
2723  // supercluster related distributions
2724  reco::SuperClusterRef sclRef = bestGsfElectron.superCluster();
2725  if (!bestGsfElectron.ecalDrivenSeed() && bestGsfElectron.trackerDrivenSeed())
2726  sclRef = bestGsfElectron.parentSuperCluster();
2727  if (sclRef.isNonnull()) {
2728  h1_scl_En_->Fill(sclRef->energy());
2729  double R = TMath::Sqrt(sclRef->x() * sclRef->x() + sclRef->y() * sclRef->y() + sclRef->z() * sclRef->z());
2730  double Rt = TMath::Sqrt(sclRef->x() * sclRef->x() + sclRef->y() * sclRef->y());
2731  h1_scl_Et_->Fill(sclRef->energy() * (Rt / R));
2732  h2_scl_EtVsEta_->Fill(sclRef->eta(), sclRef->energy() * (Rt / R));
2733  h2_scl_EtVsPhi_->Fill(sclRef->phi(), sclRef->energy() * (Rt / R));
2734  if (isEBflag)
2735  h1_scl_EoEmatchingObject_barrel->Fill(sclRef->energy() / moIter->energy());
2736  else if (isEEflag) {
2737  h1_scl_EoEmatchingObject_endcaps->Fill(sclRef->energy() / moIter->energy());
2738  h1_scl_ESFrac_endcaps->Fill(sclRef->preshowerEnergy() / sclRef->rawEnergy());
2739  }
2740  h1_scl_Eta_->Fill(sclRef->eta());
2741  h2_scl_EtaVsPhi_->Fill(sclRef->phi(), sclRef->eta());
2742  h1_scl_Phi_->Fill(sclRef->phi());
2743  }
2744  h1_scl_SigIEtaIEta_->Fill(bestGsfElectron.scSigmaIEtaIEta());
2746  h1_scl_E1x5_->Fill(bestGsfElectron.scE1x5());
2747  h1_scl_E2x5max_->Fill(bestGsfElectron.scE2x5Max());
2748  h1_scl_E5x5_->Fill(bestGsfElectron.scE5x5());
2749  if (isEBflag) {
2750  h1_scl_SigIEtaIEta_barrel_->Fill(bestGsfElectron.scSigmaIEtaIEta());
2752  h1_scl_E1x5_barrel_->Fill(bestGsfElectron.scE1x5());
2753  h1_scl_E2x5max_barrel_->Fill(bestGsfElectron.scE2x5Max());
2754  h1_scl_E5x5_barrel_->Fill(bestGsfElectron.scE5x5());
2755  } else if (isEEflag) {
2756  h1_scl_SigIEtaIEta_endcaps_->Fill(bestGsfElectron.scSigmaIEtaIEta());
2758  h1_scl_E1x5_endcaps_->Fill(bestGsfElectron.scE1x5());
2759  h1_scl_E2x5max_endcaps_->Fill(bestGsfElectron.scE2x5Max());
2760  h1_scl_E5x5_endcaps_->Fill(bestGsfElectron.scE5x5());
2761  }
2762 
2763  // track related distributions
2765  h2_ele_ambiguousTracksVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.ambiguousGsfTracksSize());
2766  h2_ele_ambiguousTracksVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.ambiguousGsfTracksSize());
2767  h2_ele_ambiguousTracksVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.ambiguousGsfTracksSize());
2768  if (!readAOD_) { // track extra does not exist in AOD
2769  h1_ele_foundHits->Fill(bestGsfElectron.gsfTrack()->numberOfValidHits());
2770  h2_ele_foundHitsVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.gsfTrack()->numberOfValidHits());
2771  h2_ele_foundHitsVsEta_Extended->Fill(bestGsfElectron.eta(), bestGsfElectron.gsfTrack()->numberOfValidHits());
2772  h2_ele_foundHitsVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.gsfTrack()->numberOfValidHits());
2773  h1_ele_lostHits->Fill(bestGsfElectron.gsfTrack()->numberOfLostHits());
2774  h2_ele_lostHitsVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.gsfTrack()->numberOfLostHits());
2775  h2_ele_lostHitsVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.gsfTrack()->numberOfLostHits());
2776  h2_ele_lostHitsVsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.gsfTrack()->numberOfLostHits());
2777  h1_ele_chi2->Fill(bestGsfElectron.gsfTrack()->normalizedChi2());
2778  h2_ele_chi2VsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.gsfTrack()->normalizedChi2());
2779  h2_ele_chi2VsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.gsfTrack()->normalizedChi2());
2780  h2_ele_chi2VsPt->Fill(bestGsfElectron.pt(), bestGsfElectron.gsfTrack()->normalizedChi2());
2781  }
2782  // from gsf track interface, hence using mean
2783  if (!readAOD_) { // track extra does not exist in AOD
2784  h1_ele_PinMnPout->Fill(bestGsfElectron.gsfTrack()->innerMomentum().R() -
2785  bestGsfElectron.gsfTrack()->outerMomentum().R());
2786  h1_ele_outerP->Fill(bestGsfElectron.gsfTrack()->outerMomentum().R());
2787  h1_ele_outerPt->Fill(bestGsfElectron.gsfTrack()->outerMomentum().Rho());
2788  }
2789  // from electron interface, hence using mode
2790  h1_ele_PinMnPout_mode->Fill(bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2792  bestGsfElectron.eta(), bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2794  bestGsfElectron.phi(), bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2796  bestGsfElectron.pt(), bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2797  h2_ele_PinMnPoutVsE_mode->Fill(bestGsfElectron.caloEnergy(),
2798  bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2799  if (!readAOD_) // track extra does not exist in AOD
2801  bestGsfElectron.gsfTrack()->normalizedChi2(),
2802  bestGsfElectron.trackMomentumAtVtx().R() - bestGsfElectron.trackMomentumOut().R());
2803  h1_ele_outerP_mode->Fill(bestGsfElectron.trackMomentumOut().R());
2804  h2_ele_outerPVsEta_mode->Fill(bestGsfElectron.eta(), bestGsfElectron.trackMomentumOut().R());
2805  h1_ele_outerPt_mode->Fill(bestGsfElectron.trackMomentumOut().Rho());
2806  h2_ele_outerPtVsEta_mode->Fill(bestGsfElectron.eta(), bestGsfElectron.trackMomentumOut().Rho());
2807  h2_ele_outerPtVsPhi_mode->Fill(bestGsfElectron.phi(), bestGsfElectron.trackMomentumOut().Rho());
2808  h2_ele_outerPtVsPt_mode->Fill(bestGsfElectron.pt(), bestGsfElectron.trackMomentumOut().Rho());
2809 
2810  if (!readAOD_) { // track extra does not exist in AOD
2811  edm::RefToBase<TrajectorySeed> seed = bestGsfElectron.gsfTrack()->extra()->seedRef();
2812  ElectronSeedRef elseed = seed.castTo<ElectronSeedRef>();
2813  h1_ele_seed_subdet2_->Fill(elseed->subDet(1));
2814  h1_ele_seed_mask_->Fill(elseed->hitsMask());
2815  if (elseed->subDet(1) == 1) {
2816  h1_ele_seed_mask_bpix_->Fill(elseed->hitsMask());
2817  } else if (elseed->subDet(1) == 2) {
2818  h1_ele_seed_mask_fpix_->Fill(elseed->hitsMask());
2819  } else if (elseed->subDet(1) == 6) {
2820  h1_ele_seed_mask_tec_->Fill(elseed->hitsMask());
2821  }
2822 
2823  if (elseed->dPhiNeg(1) != std::numeric_limits<float>::infinity()) {
2824  h1_ele_seed_dphi2_->Fill(elseed->dPhiNeg(1));
2825  h2_ele_seed_dphi2VsEta_->Fill(bestGsfElectron.eta(), elseed->dPhiNeg(1));
2826  h2_ele_seed_dphi2VsPt_->Fill(bestGsfElectron.pt(), elseed->dPhiNeg(1));
2827  }
2828  if (elseed->dPhiPos(1) != std::numeric_limits<float>::infinity()) {
2829  h1_ele_seed_dphi2pos_->Fill(elseed->dPhiPos(1));
2830  h2_ele_seed_dphi2posVsEta_->Fill(bestGsfElectron.eta(), elseed->dPhiPos(1));
2831  h2_ele_seed_dphi2posVsPt_->Fill(bestGsfElectron.pt(), elseed->dPhiPos(1));
2832  }
2833  if (elseed->dRZNeg(1) != std::numeric_limits<float>::infinity()) {
2834  h1_ele_seed_drz2_->Fill(elseed->dRZNeg(1));
2835  h2_ele_seed_drz2VsEta_->Fill(bestGsfElectron.eta(), elseed->dRZNeg(1));
2836  h2_ele_seed_drz2VsPt_->Fill(bestGsfElectron.pt(), elseed->dRZNeg(1));
2837  }
2838  if (elseed->dRZPos(1) != std::numeric_limits<float>::infinity()) {
2839  h1_ele_seed_drz2pos_->Fill(elseed->dRZPos(1));
2840  h2_ele_seed_drz2posVsEta_->Fill(bestGsfElectron.eta(), elseed->dRZPos(1));
2841  h2_ele_seed_drz2posVsPt_->Fill(bestGsfElectron.pt(), elseed->dRZPos(1));
2842  }
2843  }
2844  // match distributions
2845  h1_ele_EoP->Fill(bestGsfElectron.eSuperClusterOverP());
2846  h2_ele_EoPVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eSuperClusterOverP());
2847  h2_ele_EoPVsEta_Extended->Fill(bestGsfElectron.eta(), bestGsfElectron.eSuperClusterOverP());
2848  h2_ele_EoPVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eSuperClusterOverP());
2849  h1_ele_EseedOP->Fill(bestGsfElectron.eSeedClusterOverP());
2850  h2_ele_EseedOPVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eSeedClusterOverP());
2851  h2_ele_EseedOPVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eSeedClusterOverP());
2852  h2_ele_EseedOPVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eSeedClusterOverP());
2853  h1_ele_EoPout->Fill(bestGsfElectron.eSeedClusterOverPout());
2854  h2_ele_EoPoutVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eSeedClusterOverPout());
2855  h2_ele_EoPoutVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eSeedClusterOverPout());
2856  h2_ele_EoPoutVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eSeedClusterOverPout());
2857  h1_ele_EeleOPout->Fill(bestGsfElectron.eEleClusterOverPout());
2858  h2_ele_EeleOPoutVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.eEleClusterOverPout());
2859  h2_ele_EeleOPoutVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.eEleClusterOverPout());
2860  h2_ele_EeleOPoutVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.eEleClusterOverPout());
2862  //h1_ele_dEtaSc_propVtx_Extended->Fill(bestGsfElectron.deltaEtaSuperClusterTrackAtVtx());
2863  h2_ele_dEtaScVsEta_propVtx->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaEtaSuperClusterTrackAtVtx());
2864  h2_ele_dEtaScVsPhi_propVtx->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaEtaSuperClusterTrackAtVtx());
2865  h2_ele_dEtaScVsPt_propVtx->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaEtaSuperClusterTrackAtVtx());
2867  //h1_ele_dPhiSc_propVtx_Extended->Fill(bestGsfElectron.deltaPhiSuperClusterTrackAtVtx());
2868  h2_ele_dPhiScVsEta_propVtx->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaPhiSuperClusterTrackAtVtx());
2869  h2_ele_dPhiScVsPhi_propVtx->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaPhiSuperClusterTrackAtVtx());
2870  h2_ele_dPhiScVsPt_propVtx->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaPhiSuperClusterTrackAtVtx());
2872  h2_ele_dEtaClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaEtaSeedClusterTrackAtCalo());
2873  h2_ele_dEtaClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaEtaSeedClusterTrackAtCalo());
2874  h2_ele_dEtaClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaEtaSeedClusterTrackAtCalo());
2876  h2_ele_dPhiClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaPhiSeedClusterTrackAtCalo());
2877  h2_ele_dPhiClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaPhiSeedClusterTrackAtCalo());
2878  h2_ele_dPhiClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaPhiSeedClusterTrackAtCalo());
2880  h2_ele_dEtaEleClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaEtaEleClusterTrackAtCalo());
2881  h2_ele_dEtaEleClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaEtaEleClusterTrackAtCalo());
2882  h2_ele_dEtaEleClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaEtaEleClusterTrackAtCalo());
2884  h2_ele_dPhiEleClVsEta_propOut->Fill(bestGsfElectron.eta(), bestGsfElectron.deltaPhiEleClusterTrackAtCalo());
2885  h2_ele_dPhiEleClVsPhi_propOut->Fill(bestGsfElectron.phi(), bestGsfElectron.deltaPhiEleClusterTrackAtCalo());
2886  h2_ele_dPhiEleClVsPt_propOut->Fill(bestGsfElectron.pt(), bestGsfElectron.deltaPhiEleClusterTrackAtCalo());
2887  h1_ele_HoE->Fill(bestGsfElectron.hadronicOverEm());
2888  h1_ele_HoE_bc->Fill(bestGsfElectron.hcalOverEcalBc());
2889  if (isEBflag) {
2890  h1_ele_EoP_barrel->Fill(bestGsfElectron.eSuperClusterOverP());
2891  h1_ele_EseedOP_barrel->Fill(bestGsfElectron.eSeedClusterOverP());
2892  h1_ele_EoPout_barrel->Fill(bestGsfElectron.eSeedClusterOverPout());
2893  h1_ele_EeleOPout_barrel->Fill(bestGsfElectron.eEleClusterOverPout());
2900  h1_ele_HoE_bc_barrel->Fill(bestGsfElectron.hcalOverEcalBc());
2901  h1_ele_HoE_barrel->Fill(bestGsfElectron.hadronicOverEm());
2902  } else if (isEEflag) {
2903  h1_ele_EoP_endcaps->Fill(bestGsfElectron.eSuperClusterOverP());
2904  h1_ele_EseedOP_endcaps->Fill(bestGsfElectron.eSeedClusterOverP());
2905  h1_ele_EoPout_endcaps->Fill(bestGsfElectron.eSeedClusterOverPout());
2913  h1_ele_HoE_bc_endcaps->Fill(bestGsfElectron.hcalOverEcalBc());
2914  h1_ele_HoE_endcaps->Fill(bestGsfElectron.hadronicOverEm());
2915  }
2916 
2917  if (!bestGsfElectron.isEBEtaGap() && !bestGsfElectron.isEBPhiGap() && !bestGsfElectron.isEBEEGap() &&
2918  !bestGsfElectron.isEERingGap() && !bestGsfElectron.isEEDeeGap())
2919  h1_ele_HoE_fiducial->Fill(bestGsfElectron.hadronicOverEm());
2920  h2_ele_HoEVsEta->Fill(bestGsfElectron.eta(), bestGsfElectron.hadronicOverEm());
2921  h2_ele_HoEVsPhi->Fill(bestGsfElectron.phi(), bestGsfElectron.hadronicOverEm());
2922  h2_ele_HoEVsE->Fill(bestGsfElectron.caloEnergy(), bestGsfElectron.hadronicOverEm());
2923 
2924  //classes
2925  int eleClass = bestGsfElectron.classification();
2926  if (isEEflag)
2927  eleClass += 10;
2928  h1_ele_classes->Fill(eleClass);
2929 
2930  h1_ele_eta->Fill(std::abs(bestGsfElectron.eta()));
2931  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2932  h1_ele_eta_golden->Fill(std::abs(bestGsfElectron.eta()));
2933  if (bestGsfElectron.classification() == GsfElectron::BIGBREM)
2934  h1_ele_eta_bbrem->Fill(std::abs(bestGsfElectron.eta()));
2935  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2936  h1_ele_eta_shower->Fill(std::abs(bestGsfElectron.eta()));
2937 
2938  // fbrem
2939 
2940  double fbrem_mode = bestGsfElectron.fbrem();
2941  h1_ele_fbrem->Fill(fbrem_mode);
2942  p1_ele_fbremVsEta_mode->Fill(bestGsfElectron.eta(), fbrem_mode);
2943  double superclusterfbrem_mode = bestGsfElectron.superClusterFbrem();
2944  h1_ele_superclusterfbrem->Fill(superclusterfbrem_mode);
2945  if (isEBflag) {
2946  double fbrem_mode_barrel = bestGsfElectron.fbrem();
2947  h1_ele_fbrem_barrel->Fill(fbrem_mode_barrel);
2948  double superclusterfbrem_mode_barrel = bestGsfElectron.superClusterFbrem();
2949  h1_ele_superclusterfbrem_barrel->Fill(superclusterfbrem_mode_barrel);
2950  } else if (isEEflag) {
2951  double fbrem_mode_endcaps = bestGsfElectron.fbrem();
2952  h1_ele_fbrem_endcaps->Fill(fbrem_mode_endcaps);
2953  double superclusterfbrem_mode_endcaps = bestGsfElectron.superClusterFbrem();
2954  h1_ele_superclusterfbrem_endcaps->Fill(superclusterfbrem_mode_endcaps);
2955  }
2956 
2957  if (!readAOD_) // track extra does not exist in AOD
2958  {
2959  double fbrem_mean =
2960  1. - bestGsfElectron.gsfTrack()->outerMomentum().R() / bestGsfElectron.gsfTrack()->innerMomentum().R();
2961  p1_ele_fbremVsEta_mean->Fill(bestGsfElectron.eta(), fbrem_mean);
2962 
2963  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2964  h2_ele_PinVsPoutGolden_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().R(),
2965  bestGsfElectron.gsfTrack()->innerMomentum().R());
2966  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2967  h2_ele_PinVsPoutShowering_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().R(),
2968  bestGsfElectron.gsfTrack()->innerMomentum().R());
2969  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2970  h2_ele_PtinVsPtoutGolden_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().Rho(),
2971  bestGsfElectron.gsfTrack()->innerMomentum().Rho());
2972  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2973  h2_ele_PtinVsPtoutShowering_mean->Fill(bestGsfElectron.gsfTrack()->outerMomentum().Rho(),
2974  bestGsfElectron.gsfTrack()->innerMomentum().Rho());
2975  }
2976  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2977  h2_ele_PtinVsPtoutGolden_mode->Fill(bestGsfElectron.trackMomentumOut().Rho(),
2978  bestGsfElectron.trackMomentumAtVtx().Rho());
2979  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2980  h2_ele_PtinVsPtoutShowering_mode->Fill(bestGsfElectron.trackMomentumOut().Rho(),
2981  bestGsfElectron.trackMomentumAtVtx().Rho());
2982 
2983  if (bestGsfElectron.classification() == GsfElectron::GOLDEN)
2984  h2_ele_PinVsPoutGolden_mode->Fill(bestGsfElectron.trackMomentumOut().R(),
2985  bestGsfElectron.trackMomentumAtVtx().R());
2986  if (bestGsfElectron.classification() == GsfElectron::SHOWERING)
2987  h2_ele_PinVsPoutShowering_mode->Fill(bestGsfElectron.trackMomentumOut().R(),
2988  bestGsfElectron.trackMomentumAtVtx().R());
2989 
2990  h1_ele_mva->Fill(bestGsfElectron.mva_e_pi());
2991  h1_ele_mva_isolated->Fill(bestGsfElectron.mva_Isolated());
2992  if (isEBflag) {
2993  h1_ele_mva_barrel->Fill(bestGsfElectron.mva_e_pi());
2994  h1_ele_mva_barrel_isolated->Fill(bestGsfElectron.mva_Isolated());
2995  } else if (isEEflag) {
2996  h1_ele_mva_endcaps->Fill(bestGsfElectron.mva_e_pi());
2997  h1_ele_mva_endcaps_isolated->Fill(bestGsfElectron.mva_Isolated());
2998  }
2999 
3000  if (bestGsfElectron.ecalDrivenSeed()) {
3001  h1_ele_provenance->Fill(1.);
3002  }
3003  if (bestGsfElectron.trackerDrivenSeed()) {
3004  h1_ele_provenance->Fill(-1.);
3005  }
3006  if (bestGsfElectron.trackerDrivenSeed() || bestGsfElectron.ecalDrivenSeed()) {
3007  h1_ele_provenance->Fill(0.);
3008  }
3009  if (bestGsfElectron.trackerDrivenSeed() && !bestGsfElectron.ecalDrivenSeed()) {
3010  h1_ele_provenance->Fill(-2.);
3011  }
3012  if (!bestGsfElectron.trackerDrivenSeed() && bestGsfElectron.ecalDrivenSeed()) {
3013  h1_ele_provenance->Fill(2.);
3014  }
3015  if (bestGsfElectron.ecalDrivenSeed() && isEBflag)
3017  if (bestGsfElectron.trackerDrivenSeed() && isEBflag)
3019  if ((bestGsfElectron.trackerDrivenSeed() || bestGsfElectron.ecalDrivenSeed()) && isEBflag)
3021  if (bestGsfElectron.trackerDrivenSeed() && !bestGsfElectron.ecalDrivenSeed() && isEBflag)
3023  if (!bestGsfElectron.trackerDrivenSeed() && bestGsfElectron.ecalDrivenSeed() && isEBflag)
3025  if (bestGsfElectron.ecalDrivenSeed() && isEEflag)
3027  if (bestGsfElectron.trackerDrivenSeed() && isEEflag)
3029  if ((bestGsfElectron.trackerDrivenSeed() || bestGsfElectron.ecalDrivenSeed()) && isEEflag)
3031  if (bestGsfElectron.trackerDrivenSeed() && !bestGsfElectron.ecalDrivenSeed() && isEEflag)
3033  if (!bestGsfElectron.trackerDrivenSeed() && bestGsfElectron.ecalDrivenSeed() && isEEflag)
3035 
3036  // Pflow isolation
3040  if (isEBflag) {
3044  } else if (isEEflag) {
3048  }
3049 
3050  // -- pflow over pT
3052  bestGsfElectron.pt());
3054  bestGsfElectron.pt());
3055  h1_ele_photonRelativeIso->Fill(bestGsfElectron.pfIsolationVariables().sumPhotonEt / bestGsfElectron.pt());
3056 
3057  if (isEBflag) {
3059  bestGsfElectron.pt());
3061  bestGsfElectron.pt());
3063  bestGsfElectron.pt());
3064  } else if (isEEflag) {
3066  bestGsfElectron.pt());
3068  bestGsfElectron.pt());
3070  bestGsfElectron.pt());
3071  }
3072 
3073  // isolation
3074  h1_ele_tkSumPt_dr03->Fill(bestGsfElectron.dr03TkSumPt());
3075  h1_ele_ecalPFClusterIso->Fill(bestGsfElectron.ecalPFClusterIso());
3076  h1_ele_hcalPFClusterIso->Fill(bestGsfElectron.hcalPFClusterIso());
3082  h1_ele_hcalDepth1OverEcalBc->Fill(bestGsfElectron.hcalOverEcalBc(1));
3083  h1_ele_hcalDepth2OverEcalBc->Fill(bestGsfElectron.hcalOverEcalBc(2));
3084  if (isEBflag) {
3085  h1_ele_tkSumPt_dr03_barrel->Fill(bestGsfElectron.dr03TkSumPt());
3094  } else if (isEEflag) {
3095  h1_ele_tkSumPt_dr03_endcaps->Fill(bestGsfElectron.dr03TkSumPt());
3104  }
3105 
3106  // conversion rejection
3107  int flags = bestGsfElectron.convFlags();
3108  if (flags == -9999) {
3109  flags = -1;
3110  }
3112  if (flags >= 0.) {
3113  h1_ele_convDist->Fill(bestGsfElectron.convDist());
3114  h1_ele_convDcot->Fill(bestGsfElectron.convDcot());
3115  h1_ele_convRadius->Fill(bestGsfElectron.convRadius());
3116  }
3117 
3118  } // gsf electron found
3119 
3120  } // loop overmatching object
3121 
3122  h1_matchingObjectNum->Fill(matchingObjectNum);
3123 }
float deltaPhiEleClusterTrackAtCalo() const
Definition: GsfElectron.h:230
MonitorElement * h2_ele_ambiguousTracksVsPhi
MonitorElement * h1_ele_matchingObjectPt_matched
MonitorElement * h1_ele_neutralHadronRelativeIso_Extended
MonitorElement * h2_ele_EtaMnEtamatchingObjectVsEta
MonitorElement * h2_ele_seed_dphi2posVsPt_
MonitorElement * h1_ele_dEtaSc_propVtx
MonitorElement * h1_ele_provenance_endcaps
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
MonitorElement * h1_ele_chargedHadronRelativeIso_Extended
float scSigmaIEtaIEta() const
Definition: GsfElectron.h:496
MonitorElement * h1_ele_dEtaEleCl_propOut_barrel
MonitorElement * h1_ele_dEtaCl_propOut_endcaps
MonitorElement * h1_ele_photonRelativeIso_Extended
MonitorElement * h1_ele_hcalDepth1OverEcalBc_endcaps
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
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth2
MonitorElement * h1_ele_matchingObjectAbsEta_matched
double pt() const final
transverse momentum
bool ecalDrivenSeed() const
Definition: GsfElectron.h:158
float deltaPhiSeedClusterTrackAtCalo() const
Definition: GsfElectron.h:229
MonitorElement * h1_scl_EoEmatchingObjectGolden_endcaps
MonitorElement * h1_ele_ecalRecHitSumEt_dr03
MonitorElement * h1_ele_ecalPFClusterIso
MonitorElement * h2_ele_EtaMnEtamatchingObjectVsPt
edm::EDGetTokenT< reco::ElectronSeedCollection > electronSeedCollection_
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:36
MonitorElement * h2_ele_PoPmatchingObjectVsPhi
float eSeedClusterOverP() const
Definition: GsfElectron.h:222
float scE1x5() const
Definition: GsfElectron.h:497
bool trackerDrivenSeed() const
Definition: GsfElectron.h:159
MonitorElement * h1_ele_photonIso_barrel
MonitorElement * h1_ele_ecalPFClusterIso_barrel
MonitorElement * h1_ele_ecalRecHitSumEt_dr03_barrel
MonitorElement * h1_ele_tkSumPt_dr03_endcaps
MonitorElement * h1_ele_dPhiCl_propOut_all
bool isEBPhiGap() const
Definition: GsfElectron.h:334
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsEcalReduced04Tag_
MonitorElement * h2_ele_ambiguousTracksVsPt
MonitorElement * h2_ele_PtinVsPtoutGolden_mode
MonitorElement * h1_ele_EseedOP_endcaps
MonitorElement * h1_ele_hcalDepth2OverEcalBc
bool isEERingGap() const
Definition: GsfElectron.h:337
MonitorElement * h1_ele_photonIso_endcaps
MonitorElement * p1_ele_fbremVsEta_mode
MonitorElement * h1_ele_chargedHadronIso_endcaps
MonitorElement * h1_scl_EoEmatchingObjectShowering_barrel
MonitorElement * h1_ele_ecalPFClusterIso_endcaps
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_
MonitorElement * h2_ele_PinVsPoutShowering_mode
MonitorElement * h1_ele_hcalTowerSumEt_dr03_depth1_barrel
edm::EDGetTokenT< reco::GenJetCollection > matchingObjectCollection_
bool isNonnull() const
Checks for non-null.
Definition: Ref.h:238
MonitorElement * h1_ele_tkSumPt_dr03_barrel
MonitorElement * h1_ele_provenance_Extended
MonitorElement * h2_ele_vertexTIPVsPhi
edm::EDGetTokenT< reco::GsfTrackCollection > electronTrackCollection_
MonitorElement * h1_ele_foundHits_endcaps
float hcalOverEcalBc(const ShowerShape &ss, int depth) const
Definition: GsfElectron.h:442
const Point & vertex() const override
vertex position (overwritten by PF...)
MonitorElement * h1_ele_lostHits_endcaps
MonitorElement * h1_ele_dEtaSc_propVtx_all
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 deltaEtaEleClusterTrackAtCalo() const
Definition: GsfElectron.h:227
MonitorElement * h1_ele_dEtaCl_propOut_all
MonitorElement * h2_ele_PinVsPoutShowering_mean
MonitorElement * h2_ele_E2mnE1vsMee_all
MonitorElement * h2_ele_seed_drz2VsPt_
MonitorElement * h1_ele_HoE_bc_endcaps
MonitorElement * h1_ele_superclusterfbrem_endcaps
MonitorElement * h1_ele_neutralHadronRelativeIso_endcaps
MonitorElement * h1_scl_full5x5_sigmaIetaIeta_endcaps_
float convDcot() const
Definition: GsfElectron.h:646
MonitorElement * h2_ele_ambiguousTracksVsEta
MonitorElement * h2_ele_outerPtVsPt_mode
bool isEBEtaGap() const
Definition: GsfElectron.h:333
MonitorElement * h1_ele_ecalPFClusterIso_Extended
float eSuperClusterOverP() const
Definition: GsfElectron.h:221
Classification classification() const
Definition: GsfElectron.h:805
MonitorElement * h2_ele_E2mnE1vsMee_egeg_all
MonitorElement * h2_ele_PtinVsPtoutShowering_mean
MonitorElement * h2_ele_PhiMnPhimatchingObjectVsPt
const Double_t pi
float eEleClusterOverPout() const
Definition: GsfElectron.h:224
MonitorElement * h2_ele_dEtaEleClVsEta_propOut
bool isEB() const
Definition: GsfElectron.h:328
MonitorElement * h2_ele_PinMnPoutVsChi2_mode
MonitorElement * h1_ele_fbrem_Extended
float dr03TkSumPt() const
Definition: GsfElectron.h:557
float eSeedClusterOverPout() const
Definition: GsfElectron.h:223
void Fill(long long x)
MonitorElement * h1_ele_matchingObjectEta_matched
XYZTLorentzVectorD XYZTLorentzVector
Lorentz vector with cylindrical internal representation using pseudorapidity.
Definition: LorentzVector.h:29
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")
MonitorElement * h2_ele_EeleOPoutVsEta
MonitorElement * h2_ele_PinMnPoutVsPt_mode
GsfTrackRef gsfTrack() const override
reference to a GsfTrack
Definition: GsfElectron.h:156
MonitorElement * h1_ele_dEtaCl_propOut
MonitorElement * h1_ele_hcalPFClusterIso_barrel
const PflowIsolationVariables & pfIsolationVariables() const
Definition: GsfElectron.h:729
float ecalPFClusterIso() const
Definition: GsfElectron.h:731
math::XYZVectorF trackMomentumOut() const
Definition: GsfElectron.h:270
int iEvent
Definition: GenABIO.cc:224
MonitorElement * h2_ele_dEtaScVsEta_propVtx
void analyze(const edm::Event &e, const edm::EventSetup &c) override
float dr03HcalTowerSumEtBc(int depth=0) const
Definition: GsfElectron.h:593
float caloEnergy() const
Definition: GsfElectron.h:899
MonitorElement * h2_ele_foundHitsVsPhi
double p() const final
magnitude of momentum vector
MonitorElement * h1_ele_chargedHadronRelativeIso_barrel
MonitorElement * h2_ele_dEtaScVsPt_propVtx
MonitorElement * h2_ele_PtinVsPtoutShowering_mode
MonitorElement * h2_ele_dEtaClVsPt_propOut
MonitorElement * h1_ele_PhiMnPhimatchingObject
float mva_e_pi() const
Definition: GsfElectron.h:744
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
MonitorElement * h2_ele_dPhiClVsPt_propOut
MonitorElement * h2_ele_EoPVsEta_Extended
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_
MonitorElement * h2_ele_dPhiEleClVsPt_propOut
float sumPhotonEt
sum pt of PF photons // old float photonIso ;
Definition: GsfElectron.h:665
GsfTrackRefVector::size_type ambiguousGsfTracksSize() const
Definition: GsfElectron.h:766
MonitorElement * h1_ele_hcalDepth1OverEcalBc
int convFlags() const
Definition: GsfElectron.h:643
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsTk03Tag_
bool isEBEEGap() const
Definition: GsfElectron.h:331
MonitorElement * h2_ele_dEtaEleClVsPhi_propOut
MonitorElement * h1_ele_dEtaEleCl_propOut_endcaps
MonitorElement * h1_ele_dEtaSc_propVtx_Extended
MonitorElement * h1_ele_PoPmatchingObject
const double infinity
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth1
MonitorElement * h1_ele_convRadius_all
float convDist() const
Definition: GsfElectron.h:645
MonitorElement * h2_ele_PinMnPoutVsEta_mode
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
MonitorElement * h1_ele_lostHits_barrel
MonitorElement * h1_ele_neutralHadronIso_barrel
math::XYZVectorF trackMomentumAtVtx() const
Definition: GsfElectron.h:268
MonitorElement * h1_ele_photonRelativeIso_endcaps
MonitorElement * h1_matchingObjectEta_Extended
void setBookPrefix(const std::string &)
edm::EDGetTokenT< reco::VertexCollection > offlineVerticesCollection_
float sumNeutralHadronEt
sum pt of neutral hadrons // old float neutralHadronIso ;
Definition: GsfElectron.h:664
bool isEEDeeGap() const
Definition: GsfElectron.h:336
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_matchingObjectAbsEta_Extended
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
d
Definition: ztail.py:151
MonitorElement * h1_ele_foundHits_barrel
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_
float deltaPhiSuperClusterTrackAtVtx() const
Definition: GsfElectron.h:228
MonitorElement * h2_ele_dEtaClVsEta_propOut
MonitorElement * h1_ele_mva_barrel_isolated
float superClusterFbrem() const
Definition: GsfElectron.h:803
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
float deltaEtaSuperClusterTrackAtVtx() const
Definition: GsfElectron.h:225
MonitorElement * h1_scl_full5x5_sigmaIetaIeta_
MonitorElement * h1_ele_photonRelativeIso
MonitorElement * h2_ele_seed_dphi2VsPt_
float scE2x5Max() const
Definition: GsfElectron.h:498
MonitorElement * h2_ele_dEtaClVsPhi_propOut
MonitorElement * h2_ele_seed_drz2VsEta_
edm::EDGetTokenT< reco::BeamSpot > beamSpotTag_
bool isEE() const
Definition: GsfElectron.h:329
MonitorElement * h1_ele_PoPmatchingObject_endcaps
MonitorElement * h1_ele_dEtaSc_propVtx_barrel
MonitorElement * h2_ele_outerPtVsEta_mode
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth1_barrel
MonitorElement * h1_ele_seed_mask_fpix_
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_scl_SigIEtaIEta_barrel_
MonitorElement * h1_ele_photonRelativeIso_barrel
MonitorElement * h1_ele_neutralHadronIso
edm::EDGetTokenT< edm::ValueMap< double > > isoFromDepsHcal03Tag_
MonitorElement * h2_ele_dPhiClVsPhi_propOut
MonitorElement * h2_ele_seed_dphi2posVsEta_
MonitorElement * h1_ele_EoPout_endcaps
virtual SuperClusterRef parentSuperCluster() const
Definition: GsfElectron.h:160
float fbrem() const
Definition: GsfElectron.h:809
float hcalPFClusterIso() const
Definition: GsfElectron.h:732
MonitorElement * h1_scl_full5x5_sigmaIetaIeta_Extended_
MonitorElement * h2_ele_PhiMnPhimatchingObjectVsEta
fixed size matrix
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
float mva_Isolated() const
Definition: GsfElectron.h:743
MonitorElement * h1_ele_dPhiEleCl_propOut_endcaps
MonitorElement * h2_ele_dEtaScVsPhi_propVtx
MonitorElement * h2_ele_PhiMnPhimatchingObjectVsPhi
MonitorElement * h1_ele_hcalDepth2OverEcalBc_barrel
MonitorElement * h1_ele_dPhiEleCl_propOut
float convRadius() const
Definition: GsfElectron.h:647
MonitorElement * h2_ele_foundHitsVsEta_Extended
MonitorElement * h1_ele_EseedOP_barrel
MonitorElement * h1_scl_ESFrac_endcaps
float dr03EcalRecHitSumEt() const
Definition: GsfElectron.h:559
MonitorElement * h1_ele_dEtaEleCl_propOut
MonitorElement * h2_ele_seed_drz2posVsPt_
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth2_endcaps
MonitorElement * h1_ele_hcalPFClusterIso_endcaps
float deltaEtaSeedClusterTrackAtCalo() const
Definition: GsfElectron.h:226
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 * h2_ele_dPhiClVsEta_propOut
MonitorElement * h1_ele_hcalPFClusterIso
MonitorElement * h1_ele_dEtaCl_propOut_barrel
MonitorElement * h1_ele_hcalPFClusterIso_Extended
float scE5x5() const
Definition: GsfElectron.h:499
MonitorElement * h2_ele_dPhiScVsPt_propVtx
MonitorElement * h1_ele_dPhiSc_propVtx_barrel
float full5x5_sigmaIetaIeta() const
Definition: GsfElectron.h:471
float dr03HcalTowerSumEt(int depth=0) const
Definition: GsfElectron.h:576
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
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_matchingObjectAbsEta_Extended_matched
MonitorElement * h1_ele_neutralHadronRelativeIso
MonitorElement * h1_ele_hcalTowerSumEtBc_dr03_depth2_barrel
MonitorElement * h1_ele_provenance_barrel
float hadronicOverEm() const
Definition: GsfElectron.h:500
MonitorElement * h1_ele_PinMnPout_mode
SuperClusterRef superCluster() const override
reference to a SuperCluster
Definition: GsfElectron.h:155
MonitorElement * h1_ele_dPhiSc_propVtx_Extended
MonitorElement * h2_ele_outerPVsEta_mode
Definition: Run.h:45
MonitorElement * h1_ele_PoPmatchingObject_barrel
int charge() const final
electric charge
MonitorElement * h1_ele_matchingObjectEta_Extended_matched
MonitorElement * h1_scl_full5x5_sigmaIetaIeta_barrel_
MonitorElement * h2_ele_dPhiEleClVsEta_propOut
MonitorElement * h1_ele_ambiguousTracks
double eta() const final
momentum pseudorapidity
MonitorElement * h1_ele_EeleOPout_endcaps
MonitorElement * h1_ele_chargedHadronRelativeIso_endcaps