ra4_draw  4bd0201e3d922d42bd545d4b045ed44db33454a4
plot_dilep_angles.cxx
Go to the documentation of this file.
2 
3 #include <cmath>
4 
5 #include "TError.h"
6 #include "TVector2.h"
7 
8 #include "core/plot_maker.hpp"
9 #include "core/plot_opt.hpp"
10 #include "core/palette.hpp"
11 #include "core/hist1d.hpp"
12 #include "core/event_scan.hpp"
13 
14 using namespace std;
15 using namespace PlotOptTypes;
16 
17 int main(){
18  gErrorIgnoreLevel = 6000;
19 
20  double lumi = 2.6;
21 
22  Palette colors("txt/colors.txt", "default");
23 
24  string folder_mc = "/net/cms2/cms2r0/babymaker/babies/2016_06_14/mc/merged_standard/";
25  auto tt1l = Process::MakeShared<Baby_full>("t#bar{t} (1l)", Process::Type::background, colors("tt_1l"),
26  {folder_mc+"*_TTJets*Lept*.root", folder_mc+"*_TTJets_HT*.root"}, "ntruleps<=1&&stitch");
27  auto tt2l = Process::MakeShared<Baby_full>("t#bar{t} (2l)", Process::Type::background, colors("tt_2l"),
28  {folder_mc+"*_TTJets*Lept*.root", folder_mc+"*_TTJets_HT*.root"}, "ntruleps>=2&&stitch");
29  auto wjets = Process::MakeShared<Baby_full>("W+jets", Process::Type::background, colors("wjets"),
30  {folder_mc+"*_WJetsToLNu*.root"});
31  auto single_t = Process::MakeShared<Baby_full>("Single t", Process::Type::background, colors("single_t"),
32  {folder_mc+"*_ST_*.root"});
33  auto ttv = Process::MakeShared<Baby_full>("t#bar{t}V", Process::Type::background, colors("ttv"),
34  {folder_mc+"*_TTWJets*.root", folder_mc+"*_TTZTo*.root"});
35  auto other = Process::MakeShared<Baby_full>("Other", Process::Type::background, colors("other"),
36  {folder_mc+"*DYJetsToLL*.root", folder_mc+"*_QCD_HT*.root",
37  folder_mc+"*_ZJet*.root", folder_mc+"*_WWTo*.root",
38  folder_mc+"*ggZH_HToBB*.root", folder_mc+"*ttHJetTobb*.root",
39  folder_mc+"*_TTGJets*.root", folder_mc+"*_TTTT_*.root",
40  folder_mc+"*_WH_HToBB*.root", folder_mc+"*_WZTo*.root",
41  folder_mc+"*_ZH_HToBB*.root", folder_mc+"_ZZ_*.root"});
42  auto data_2016 = Process::MakeShared<Baby_full>("2016 Data", Process::Type::data, kBlack,
43  {"/net/cms2/cms2r0/babymaker/babies/2016_06_21/data/skim_standard/*.root"},
44  "pass&&(trig[4]||trig[8]||trig[13]||trig[33])");
45  auto data_2015 = Process::MakeShared<Baby_full>("2015 Data", Process::Type::data, kRed,
46  {"/net/cms2/cms2r0/babymaker/babies/2016_04_29/data/merged_1lht500met200/*.root"},
47  "pass&&(trig[4]||trig[8]||trig[13]||trig[28])");
48 
49  vector<shared_ptr<Process> > procs = {data_2016, data_2015, tt1l, tt2l, wjets, single_t, ttv, other};
50 
51  PlotOpt log_lumi("txt/plot_styles.txt", "CMSPaper");
52  log_lumi.Title(TitleType::info)
53  .Bottom(BottomType::off)
54  .YAxis(YAxisType::log)
55  .Stack(StackType::data_norm);
56  PlotOpt lin_lumi = log_lumi().YAxis(YAxisType::linear);
57  vector<PlotOpt> plot_types = {log_lumi, lin_lumi};
58 
59  PlotMaker pm;
60  double pi = acos(-1.);
61 
62  NamedFunc baseline = "met<=500&&nbm<=2&&ht>500&&met>200";
63  NamedFunc dilep_all = baseline && "(nleps==2&&njets>=4) || (nleps==1&&nveto==1&&njets>=5&&nbm>=1&&mt>140)";
64  NamedFunc dilep_ee = baseline && "nels==2&&nmus==0&&njets>=4";
65  NamedFunc dilep_em = baseline && "nels==1&&nmus==1&&njets>=4";
66  NamedFunc dilep_mm = baseline && "nels==0&&nmus==2&&njets>=4";
67  NamedFunc dilep_ev = baseline && "nels==1&&nmus==0&&nveto==1&&njets>=5&&nbm>=1&&mt>140";
68  NamedFunc dilep_mv = baseline && "nels==0&&nmus==1&&nveto==1&&njets>=5&&nbm>=1&&mt>140";
69 
70  NamedFunc dphi_ll("dphi_ll", [](const Baby &b) -> NamedFunc::ScalarType{
71  double phi1, eta1, phi2, eta2;
72  GetAngles(b, phi1, eta1, phi2, eta2);
73  if(phi1 == -999 || phi2 == -999) return -1.;
74  return fabs(TVector2::Phi_mpi_pi(phi2-phi1));
75  });
76  NamedFunc min_dphi_lmet("min_dphi_lmet", MinDeltaPhiLepMet);
77  NamedFunc max_dphi_lmet("max_dphi_lmet", MaxDeltaPhiLepMet);
78  NamedFunc min_dphi_lj("min_dphi_lj", MinDeltaPhiLepJet);
79  NamedFunc max_dphi_lj("max_dphi_lj", MaxDeltaPhiLepJet);
80  NamedFunc min_dphi_metj("min_dphi_metj", MinDeltaPhiMetJet);
81  NamedFunc max_dphi_metj("max_dphi_metj", MaxDeltaPhiMetJet);
82 
83  NamedFunc dr_ll("dr_ll", [](const Baby &b) -> NamedFunc::ScalarType{
84  double phi1, eta1, phi2, eta2;
85  GetAngles(b, phi1, eta1, phi2, eta2);
86  if(phi1 == -999 || phi2 == -999) return -1.;
87  return hypot(TVector2::Phi_mpi_pi(phi2-phi1), eta2-eta1);
88  });
89  NamedFunc min_dr_lj("min_dr_lj", MinDeltaRLepJet);
90  NamedFunc max_dr_lj("max_dr_lj", MaxDeltaRLepJet);
91 
92  vector<pair<string, NamedFunc> > categories = {{"all", dilep_all}, {"ee", dilep_ee}, {"em", dilep_em},
93  {"mm", dilep_mm}, {"ev", dilep_ev}, {"mv", dilep_mv}};
94 
95  for(const auto &cat: categories){
96  std::string tag = "angles_"+cat.first;
97  const NamedFunc &cut = cat.second;
98 
99  pm.Push<Hist1D>(Axis(20, 0., pi, dphi_ll, "#Delta#phi(l,l)"), cut, procs, plot_types).Tag(tag);
100  pm.Push<Hist1D>(Axis(20, 0., pi, min_dphi_lmet, "Min. #Delta#phi(l,MET)"), cut, procs, plot_types).Tag(tag);
101  pm.Push<Hist1D>(Axis(20, 0., pi, max_dphi_lmet, "Max. #Delta#phi(l,MET)"), cut, procs, plot_types).Tag(tag);
102  pm.Push<Hist1D>(Axis(20, 0., pi, min_dphi_lj, "Min. #Delta#phi(l,jet)"), cut, procs, plot_types).Tag(tag);
103  pm.Push<Hist1D>(Axis(20, 0., pi, max_dphi_lj, "Max. #Delta#phi(l,jet)"), cut, procs, plot_types).Tag(tag);
104  pm.Push<Hist1D>(Axis(20, 0., pi, min_dphi_metj, "Min. #Delta#phi(MET,jet)"), cut, procs, plot_types).Tag(tag);
105  pm.Push<Hist1D>(Axis(20, 0., pi, max_dphi_metj, "Max. #Delta#phi(MET,jet)"), cut, procs, plot_types).Tag(tag);
106 
107  pm.Push<Hist1D>(Axis(20, 0., 6, dr_ll, "#Delta R(l,l)"), cut, procs, plot_types).Tag(tag);
108  pm.Push<Hist1D>(Axis(20, 0., 6, min_dr_lj, "Min. #Delta R(l,jet)"), cut, procs, plot_types).Tag(tag);
109  pm.Push<Hist1D>(Axis(20, 0., 6, max_dr_lj, "Max. #Delta R(l,jet)"), cut, procs, plot_types).Tag(tag);
110  }
111 
112  pm.Push<EventScan>("dilep_angle", dilep_mm || dilep_em, vector<NamedFunc>{
113  "run", "lumiblock", "event", "nmus", "nels", "nveto",
114  dphi_ll, dr_ll, min_dphi_lmet, max_dphi_lmet, min_dphi_lj,
115  max_dphi_lj, min_dr_lj, max_dr_lj, min_dphi_metj, max_dphi_metj,
116  "mj14", "mt", "njets", "nbm", "met", "met_phi", "leps_pt",
117  "leps_phi", "leps_eta", "leps_id", "jets_pt", "jets_phi", "jets_eta"
118  }, procs, 10);
119 
120  //pm.multithreaded_ = false;
121  pm.MakePlots(lumi);
122 }
123 
124 bool IsGoodMuon(const Baby &b, size_t imu){
125  return imu<b.mus_pt()->size()
126  && b.mus_pt()->at(imu)>20.
127  && fabs(b.mus_eta()->at(imu))<2.4
128  && b.mus_sigid()->at(imu)
129  && b.mus_miniso()->at(imu) >= 0.
130  && b.mus_miniso()->at(imu) < 0.2;
131 }
132 
133 bool IsGoodElectron(const Baby &b, size_t iel){
134  return iel<b.els_pt()->size()
135  && b.els_pt()->at(iel)>20.
136  && fabs(b.els_sceta()->at(iel))<2.5
137  && b.els_sigid()->at(iel)
138  && b.els_miniso()->at(iel) >= 0.
139  && b.els_miniso()->at(iel) < 0.1;
140 }
141 
142 bool IsGoodTrack(const Baby &b, size_t itk){
143  if(itk >= b.tks_pt()->size()) return false;
144 
145  if(fabs(b.tks_pdg()->at(itk))==211 && b.tks_pt()->at(itk)>15. && b.tks_miniso()->at(itk)<0.1 && b.tks_mt2()->at(itk)<60 && b.tks_dz()->at(itk)<0.07 && b.tks_d0()->at(itk)<0.05 ){
146  return true;
147  }else if(fabs(b.tks_pdg()->at(itk))==13 && b.tks_pt()->at(itk)>10. && b.tks_miniso()->at(itk)<0.2 && b.tks_mt2()->at(itk)<80 && b.tks_dz()->at(itk)<0.07 && b.tks_d0()->at(itk)<0.05){
148  return true;
149  }else if(fabs(b.tks_pdg()->at(itk))==11 && b.tks_pt()->at(itk)>10. && b.tks_miniso()->at(itk)<0.2 && b.tks_mt2()->at(itk)<80 && b.tks_dz()->at(itk)<0.07 && b.tks_d0()->at(itk)<0.05){
150  return true;
151  }else{
152  return false;
153  }
154 }
155 
156 bool IsGoodJet(const Baby &b, size_t ijet){
157  if(ijet >= b.jets_pt()->size()) return false;
158 
159  return b.jets_pt()->at(ijet) > 30.
160  && b.jets_eta()->at(ijet) < 2.
161  && !b.jets_islep()->at(ijet);
162 }
163 
164 void GetAngles(const Baby &b,
165  double &phi1, double &eta1,
166  double &phi2, double &eta2){
167  phi1 = -999.; eta1 = -999.;
168  phi2 = -999.; eta2 = -999.;
169  bool h1=false, h2=false;
170  if(b.nels()==2 && b.nmus()==0){
171  for(size_t iel = 0; iel < b.els_pt()->size() && !(h1&&h2); ++iel){
172  if(IsGoodElectron(b, iel)){
173  if(!h1){
174  phi1 = b.els_phi()->at(iel);
175  eta1 = b.els_sceta()->at(iel);
176  h1 = true;
177  }else if(!h2){
178  phi2 = b.els_phi()->at(iel);
179  eta2 = b.els_sceta()->at(iel);
180  h2 = true;
181  }
182  }
183  }
184  }else if(b.nels()==1 && b.nmus()==1){
185  for(size_t iel = 0; iel < b.els_pt()->size() && !h1; ++iel){
186  if(IsGoodElectron(b, iel)){
187  if(!h1){
188  phi1 = b.els_phi()->at(iel);
189  eta1 = b.els_sceta()->at(iel);
190  h1 = true;
191  }else if(!h2){
192  phi2 = b.els_phi()->at(iel);
193  eta2 = b.els_sceta()->at(iel);
194  h2 = true;
195  }
196  }
197  }
198  for(size_t imu = 0; imu < b.mus_pt()->size() && h1 && !h2; ++imu){
199  if(IsGoodMuon(b, imu)){
200  if(!h1){
201  phi1 = b.mus_phi()->at(imu);
202  eta1 = b.mus_eta()->at(imu);
203  h1 = true;
204  }else if(!h2){
205  phi2 = b.mus_phi()->at(imu);
206  eta2 = b.mus_eta()->at(imu);
207  h2 = true;
208  }
209  }
210  }
211  }else if(b.nels()==0 && b.nmus()==2){
212  for(size_t imu = 0; imu < b.mus_pt()->size() && !(h1&&h2); ++imu){
213  if(IsGoodMuon(b, imu)){
214  if(!h1){
215  phi1 = b.mus_phi()->at(imu);
216  eta1 = b.mus_eta()->at(imu);
217  h1 = true;
218  }else if(!h2){
219  phi2 = b.mus_phi()->at(imu);
220  eta2 = b.mus_eta()->at(imu);
221  h2 = true;
222  }
223  }
224  }
225  }else if(b.nels()==1 && b.nmus()==0 && b.nveto()==1){
226  for(size_t iel = 0; iel < b.els_pt()->size() && !h1; ++iel){
227  if(IsGoodElectron(b, iel)){
228  if(!h1){
229  phi1 = b.els_phi()->at(iel);
230  eta1 = b.els_sceta()->at(iel);
231  h1 = true;
232  }else if(!h2){
233  phi2 = b.els_phi()->at(iel);
234  eta2 = b.els_sceta()->at(iel);
235  h2 = true;
236  }
237  }
238  }
239  for(size_t itk = 0; itk < b.tks_pt()->size() && h1 && !h2; ++itk){
240  if(IsGoodTrack(b, itk)){
241  if(!h1){
242  phi1 = b.tks_phi()->at(itk);
243  eta1 = b.tks_eta()->at(itk);
244  h1 = true;
245  }else if(!h2){
246  phi2 = b.tks_phi()->at(itk);
247  eta2 = b.tks_eta()->at(itk);
248  h2 = true;
249  }
250  }
251  }
252  }else if(b.nels()==0 && b.nmus()==1 && b.nveto()==1){
253  for(size_t imu = 0; imu < b.mus_pt()->size() && !h1; ++imu){
254  if(IsGoodMuon(b, imu)){
255  if(!h1){
256  phi1 = b.mus_phi()->at(imu);
257  eta1 = b.mus_eta()->at(imu);
258  h1 = true;
259  }else if(!h2){
260  phi2 = b.mus_phi()->at(imu);
261  eta2 = b.mus_eta()->at(imu);
262  h2 = true;
263  }
264  }
265  }
266  for(size_t itk = 0; itk < b.tks_pt()->size() && h1 && !h2; ++itk){
267  if(IsGoodTrack(b, itk)){
268  if(!h1){
269  phi1 = b.tks_phi()->at(itk);
270  eta1 = b.tks_eta()->at(itk);
271  h1 = true;
272  }else if(!h2){
273  phi2 = b.tks_phi()->at(itk);
274  eta2 = b.tks_eta()->at(itk);
275  h2 = true;
276  }
277  }
278  }
279  }
280 }
281 
283  double phi1, eta1, phi2, eta2;
284  GetAngles(b, phi1, eta1, phi2, eta2);
285  double dphi1 = fabs(TVector2::Phi_mpi_pi(phi1-b.met_phi()));
286  double dphi2 = fabs(TVector2::Phi_mpi_pi(phi2-b.met_phi()));
287  if(phi1 != -999 && phi2 != -999){
288  return std::min(dphi1,dphi2);
289  }else if(phi1 != -999 && phi2 == -999){
290  return dphi1;
291  }else if(phi1 == -999 && phi2 != -999){
292  return dphi2;
293  }
294  return -1;
295 }
296 
298  double phi1, eta1, phi2, eta2;
299  GetAngles(b, phi1, eta1, phi2, eta2);
300  double dphi1 = fabs(TVector2::Phi_mpi_pi(phi1-b.met_phi()));
301  double dphi2 = fabs(TVector2::Phi_mpi_pi(phi2-b.met_phi()));
302  if(phi1 != -999 && phi2 != -999){
303  return std::max(dphi1,dphi2);
304  }else if(phi1 != -999 && phi2 == -999){
305  return dphi1;
306  }else if(phi1 == -999 && phi2 != -999){
307  return dphi2;
308  }
309  return -1;
310 }
311 
313  double phi1, eta1, phi2, eta2;
314  GetAngles(b, phi1, eta1, phi2, eta2);
315  double minphi = -1.;
316  for(size_t ijet = 0; ijet < b.jets_pt()->size(); ++ijet){
317  if(!IsGoodJet(b,ijet)) continue;
318  double dphi1 = fabs(TVector2::Phi_mpi_pi(phi1-b.jets_phi()->at(ijet)));
319  double dphi2 = fabs(TVector2::Phi_mpi_pi(phi2-b.jets_phi()->at(ijet)));
320  double thisdphi = -1;
321  if(phi1 != -999 && phi2 != -999){
322  thisdphi = std::min(dphi1, dphi2);
323  }else if(phi1 != -999 && phi2 == -999){
324  thisdphi = dphi1;
325  }else if(phi1 == -999 && phi2 != -999){
326  thisdphi = dphi2;
327  }
328  if(minphi < 0. || thisdphi < minphi){
329  minphi = thisdphi;
330  }
331  }
332  return minphi;
333 }
334 
336  double phi1, eta1, phi2, eta2;
337  GetAngles(b, phi1, eta1, phi2, eta2);
338  double maxphi = -1.;
339  for(size_t ijet = 0; ijet < b.jets_pt()->size(); ++ijet){
340  if(!IsGoodJet(b,ijet)) continue;
341  double dphi1 = fabs(TVector2::Phi_mpi_pi(phi1-b.jets_phi()->at(ijet)));
342  double dphi2 = fabs(TVector2::Phi_mpi_pi(phi2-b.jets_phi()->at(ijet)));
343  double thisdphi = -1;
344  if(phi1 != -999 && phi2 != -999){
345  thisdphi = std::max(dphi1, dphi2);
346  }else if(phi1 != -999 && phi2 == -999){
347  thisdphi = dphi1;
348  }else if(phi1 == -999 && phi2 != -999){
349  thisdphi = dphi2;
350  }
351  if(maxphi < 0. || thisdphi > maxphi){
352  maxphi = thisdphi;
353  }
354  }
355  return maxphi;
356 }
357 
359  double minphi = -1.;
360  for(size_t ijet = 0; ijet < b.jets_pt()->size(); ++ijet){
361  if(!IsGoodJet(b,ijet)) continue;
362  double thisdphi = fabs(TVector2::Phi_mpi_pi(b.met_phi()-b.jets_phi()->at(ijet)));
363  if(minphi < 0. || thisdphi < minphi){
364  minphi = thisdphi;
365  }
366  }
367  return minphi;
368 }
369 
371  double maxphi = -1.;
372  for(size_t ijet = 0; ijet < b.jets_pt()->size(); ++ijet){
373  if(!IsGoodJet(b,ijet)) continue;
374  double thisdphi = fabs(TVector2::Phi_mpi_pi(b.met_phi()-b.jets_phi()->at(ijet)));
375  if(maxphi < 0. || thisdphi > maxphi){
376  maxphi = thisdphi;
377  }
378  }
379  return maxphi;
380 }
381 
383  double phi1, eta1, phi2, eta2;
384  GetAngles(b, phi1, eta1, phi2, eta2);
385  double minr = -1.;
386  for(size_t ijet = 0; ijet < b.jets_pt()->size(); ++ijet){
387  if(!IsGoodJet(b,ijet)) continue;
388  double dr1 = hypot(TVector2::Phi_mpi_pi(phi1-b.jets_phi()->at(ijet)), eta2-eta1);
389  double dr2 = hypot(TVector2::Phi_mpi_pi(phi2-b.jets_phi()->at(ijet)), eta2-eta1);
390  double thisdr = -1;
391  if(phi1 != -999 && phi2 != -999){
392  thisdr = std::min(dr1, dr2);
393  }else if(phi1 != -999 && phi2 == -999){
394  thisdr = dr1;
395  }else if(phi1 == -999 && phi2 != -999){
396  thisdr = dr2;
397  }
398  if(minr < 0. || thisdr < minr){
399  minr = thisdr;
400  }
401  }
402  return minr;
403 }
404 
406  double phi1, eta1, phi2, eta2;
407  GetAngles(b, phi1, eta1, phi2, eta2);
408  double maxr = -1.;
409  for(size_t ijet = 0; ijet < b.jets_pt()->size(); ++ijet){
410  if(!IsGoodJet(b,ijet)) continue;
411  double dr1 = hypot(TVector2::Phi_mpi_pi(phi1-b.jets_phi()->at(ijet)), eta2-eta1);
412  double dr2 = hypot(TVector2::Phi_mpi_pi(phi2-b.jets_phi()->at(ijet)), eta2-eta1);
413  double thisdr = -1;
414  if(phi1 != -999 && phi2 != -999){
415  thisdr = std::max(dr1, dr2);
416  }else if(phi1 != -999 && phi2 == -999){
417  thisdr = dr1;
418  }else if(phi1 == -999 && phi2 != -999){
419  thisdr = dr2;
420  }
421  if(maxr < 0. || thisdr > maxr){
422  maxr = thisdr;
423  }
424  }
425  return maxr;
426 }
std::vector< float > *const & mus_eta() const
Get mus_eta for current event and cache it.
Definition: baby.cpp:5525
PlotOpt & Stack(PlotOptTypes::StackType stack_type)
Definition: plot_opt.cpp:120
PlotOpt & YAxis(PlotOptTypes::YAxisType y_axis_type)
Definition: plot_opt.cpp:102
std::vector< float > *const & els_pt() const
Get els_pt for current event and cache it.
Definition: baby.cpp:3461
bool IsGoodTrack(const Baby &b, size_t itk)
std::vector< float > *const & mus_phi() const
Get mus_phi for current event and cache it.
Definition: baby.cpp:5621
std::vector< float > *const & jets_phi() const
Get jets_phi for current event and cache it.
Definition: baby.cpp:4277
Abstract base class for access to ntuple variables.
Definition: baby.hpp:16
NamedFunc::ScalarType MaxDeltaRLepJet(const Baby &b)
std::vector< float > *const & tks_mt2() const
Get tks_mt2 for current event and cache it.
Definition: baby.cpp:7253
NamedFunc::ScalarType MaxDeltaPhiLepJet(const Baby &b)
STL namespace.
std::vector< float > *const & mus_pt() const
Get mus_pt for current event and cache it.
Definition: baby.cpp:5633
Combines a callable function taking a Baby and returning a scalar or vector with its string represent...
Definition: named_func.hpp:13
bool IsGoodMuon(const Baby &b, size_t imu)
float const & met_phi() const
Get met_phi for current event and cache it.
Definition: baby.cpp:4733
std::vector< float > *const & tks_eta() const
Get tks_eta for current event and cache it.
Definition: baby.cpp:7217
NamedFunc::ScalarType MaxDeltaPhiMetJet(const Baby &b)
std::vector< float > *const & els_miniso() const
Get els_miniso for current event and cache it.
Definition: baby.cpp:3437
bool IsGoodElectron(const Baby &b, size_t iel)
double ScalarType
Definition: named_func.hpp:15
NamedFunc::ScalarType MaxDeltaPhiLepMet(const Baby &b)
int const & nmus() const
Get nmus for current event and cache it.
Definition: baby.cpp:6077
std::vector< float > *const & tks_d0() const
Get tks_d0 for current event and cache it.
Definition: baby.cpp:7193
NamedFunc::ScalarType MinDeltaRLepJet(const Baby &b)
int main()
FigureType & Push(Args &&...args)
Definition: plot_maker.hpp:24
std::vector< float > *const & els_phi() const
Get els_phi for current event and cache it.
Definition: baby.cpp:3449
Definition: axis.hpp:12
NamedFunc::ScalarType MinDeltaPhiLepJet(const Baby &b)
std::vector< float > *const & jets_eta() const
Get jets_eta for current event and cache it.
Definition: baby.cpp:4121
std::vector< bool > *const & mus_sigid() const
Get mus_sigid for current event and cache it.
Definition: baby.cpp:5681
std::vector< bool > *const & els_sigid() const
Get els_sigid for current event and cache it.
Definition: baby.cpp:3509
void GetAngles(const Baby &b, double &phi1, double &eta1, double &phi2, double &eta2)
bool IsGoodJet(const Baby &b, size_t ijet)
Organizes efficient production of plots with single loop over each process.
Definition: plot_maker.hpp:14
NamedFunc::ScalarType MinDeltaPhiLepMet(const Baby &b)
std::vector< float > *const & tks_miniso() const
Get tks_miniso for current event and cache it.
Definition: baby.cpp:7229
std::vector< float > *const & tks_pt() const
Get tks_pt for current event and cache it.
Definition: baby.cpp:7289
PlotOpt & Bottom(PlotOptTypes::BottomType bottom_type)
Definition: plot_opt.cpp:93
std::vector< float > *const & els_sceta() const
Get els_sceta for current event and cache it.
Definition: baby.cpp:3485
std::vector< float > *const & tks_phi() const
Get tks_phi for current event and cache it.
Definition: baby.cpp:7277
int const & nels() const
Get nels for current event and cache it.
Definition: baby.cpp:5897
int const & nveto() const
Get nveto for current event and cache it.
Definition: baby.cpp:6257
std::vector< int > *const & tks_pdg() const
Get tks_pdg for current event and cache it.
Definition: baby.cpp:7265
A full 1D plot with stacked/overlayed histograms.
Definition: hist1d.hpp:23
std::vector< float > *const & jets_pt() const
Get jets_pt for current event and cache it.
Definition: baby.cpp:4289
std::vector< float > *const & mus_miniso() const
Get mus_miniso for current event and cache it.
Definition: baby.cpp:5585
std::vector< float > *const & tks_dz() const
Get tks_dz for current event and cache it.
Definition: baby.cpp:7205
NamedFunc::ScalarType MinDeltaPhiMetJet(const Baby &b)
std::vector< bool > *const & jets_islep() const
Get jets_islep for current event and cache it.
Definition: baby.cpp:4253
void MakePlots(double luminosity, const std::string &subdir="")
Prints all added plots with given luminosity.
Definition: plot_maker.cpp:54
PlotOpt & Title(PlotOptTypes::TitleType title_type)
Definition: plot_opt.cpp:111
Loads colors from a text configuration file.
Definition: palette.hpp:8