1 |
< |
{ |
2 |
< |
TChain chain("ttljets"); |
3 |
< |
//chain . Add("./ttlj_chowder_muon.root"); |
4 |
< |
chain . Add("./ttlj_chowder_electron.root"); |
5 |
< |
chain . Add("./ttlj_gumbo_electron.root"); |
6 |
< |
//chain . Add("./ttlj_gumbo_muon.root"); |
1 |
> |
{ gROOT->SetStyle("Plain"); |
2 |
> |
gStyle->SetOptStat(0000); |
3 |
> |
gStyle->SetPalette(1); |
4 |
> |
|
5 |
> |
TChain ch_ttbar("mva/ttljets"); |
6 |
> |
//TChain ch_w("mva/ttljets"); |
7 |
> |
//TChain ch_z("mva/ttljets"); |
8 |
> |
TChain ch_w("ttljets"); |
9 |
> |
TChain ch_z("ttljets"); |
10 |
> |
TChain ch_qcd("mva/ttljets"); |
11 |
> |
ch_ttbar . Add("tjets_muon-08apr2009.root"); |
12 |
> |
//ch_w . Add("wjets_muon-08apr2009.root"); |
13 |
> |
//ch_z . Add("zjets_muon-08apr2009.root"); |
14 |
> |
ch_w . Add("wjets_muon_fastsim-23apr2009.root"); |
15 |
> |
ch_z . Add("zjets_muon_fastsim-23apr2009.root"); |
16 |
> |
ch_qcd . Add("qcd_muon-08apr2009.root"); |
17 |
> |
|
18 |
> |
#include "cuts.C" |
19 |
> |
|
20 |
> |
//reversible_cut = "lepton_pt/(lepton_pt + lepton_calo_iso) > 0.9"; |
21 |
> |
//reversible_cut = "lepton_pt/(lepton_pt + lepton_track_iso) > 0.9"; |
22 |
> |
|
23 |
> |
TCut nom_cut = semilep_cut && reversible_cut; |
24 |
> |
TCut rev_cut = semilep_cut && !reversible_cut; |
25 |
> |
|
26 |
> |
//the_cut = ""; |
27 |
> |
//the_cut = cut3; |
28 |
> |
//the_cut = cut3_rev; |
29 |
> |
//the_cut = cut3_qcd; |
30 |
> |
the_cut = cut4; |
31 |
> |
|
32 |
> |
double lumi = 20.0; |
33 |
> |
|
34 |
> |
double xsec_ttbar = 317.0; |
35 |
> |
double xsec_w = 40000.0; |
36 |
> |
double xsec_z = 3700.0; |
37 |
> |
double xsec_qcd = 0.5091e+9; |
38 |
> |
|
39 |
> |
double eff_gen_ttbar = 1.0; |
40 |
> |
double eff_gen_w = 1.0; |
41 |
> |
double eff_gen_z = 1.0; |
42 |
> |
double eff_gen_qcd = 0.000239; |
43 |
> |
|
44 |
> |
Long64_t n_processed_ttbar = 1018924; |
45 |
> |
//Long64_t n_processed_w = 9984223; // FIXME not precise fullsim |
46 |
> |
//Long64_t n_processed_z = 1163479; //PAT: 236345 |
47 |
> |
Long64_t n_processed_w = 101467739; |
48 |
> |
Long64_t n_processed_z = 9679459; // PAT: 2000116 |
49 |
> |
//Long64_t n_processed_qcd = 3889924; // ~half of the processed set |
50 |
> |
Long64_t n_processed_qcd = 6142581; // PAT: 1282829 |
51 |
> |
|
52 |
> |
cout << "Selecting events..." << endl; |
53 |
> |
|
54 |
> |
TH1F h1("h1","IP",100,-0.2, 0.2); |
55 |
> |
TH1F h2("h2","IP",100,-0.2, 0.2); |
56 |
> |
TH1F h3("h3","IP",100,-0.2, 0.2); |
57 |
> |
TH1F h4("h4","IP",100,-0.2, 0.2); |
58 |
> |
h1 . SetFillColor(2); |
59 |
> |
h2 . SetFillColor(3); |
60 |
> |
h2 . SetFillColor(4); |
61 |
> |
h2 . SetFillColor(5); |
62 |
|
|
63 |
< |
gROOT->Macro("./cuts.C"); |
63 |
> |
TCanvas c("canvas", "canvas", 800, 400); |
64 |
> |
c.GetPad(0)->SetLogy(1); |
65 |
> |
|
66 |
> |
Long64_t n_selected_ttbar = ch_ttbar -> Draw("lepton_d0>>h1", the_cut); |
67 |
> |
Long64_t n_selected_w = ch_w -> Draw("lepton_d0>>h2", the_cut); |
68 |
> |
Long64_t n_selected_z = ch_z -> Draw("lepton_d0>>h3", the_cut); |
69 |
> |
Long64_t n_selected_qcd = ch_qcd -> Draw("lepton_d0>>h4", the_cut); |
70 |
> |
|
71 |
> |
double eff_sel_ttbar = (double)n_selected_ttbar/(double)n_processed_ttbar; |
72 |
> |
double eff_sel_w = (double)n_selected_w/(double)n_processed_w; |
73 |
> |
double eff_sel_z = (double)n_selected_z/(double)n_processed_z; |
74 |
> |
double eff_sel_qcd = (double)n_selected_qcd/(double)n_processed_qcd; |
75 |
> |
|
76 |
> |
double n_expected_ttbar = xsec_ttbar * eff_gen_ttbar * eff_sel_ttbar * lumi; |
77 |
> |
double n_expected_w = xsec_w * eff_gen_w * eff_sel_w * lumi; |
78 |
> |
double n_expected_z = xsec_z * eff_gen_z * eff_sel_z * lumi; |
79 |
> |
double n_expected_qcd = xsec_qcd * eff_gen_qcd * eff_sel_qcd * lumi; |
80 |
> |
|
81 |
> |
double n_expected_all = n_expected_ttbar + n_expected_w + n_expected_z + n_expected_qcd; |
82 |
> |
double n_expected_phys = n_expected_ttbar + n_expected_w + n_expected_z; |
83 |
> |
|
84 |
|
|
85 |
+ |
/* |
86 |
|
TH1F h_id("h_id","Track Isolation",60,0, 60); |
87 |
|
h_id . SetFillColor(2); |
88 |
|
|
13 |
– |
TH1F h_track_iso("h_track_iso","Track Isolation",100,0, 3); |
14 |
– |
TH1F h_track_iso_2("h_track_iso_2","Track Isolation",100,0, 3); |
15 |
– |
h_track_iso . SetFillColor(2); |
16 |
– |
h_track_iso_2 . SetFillColor(3); |
89 |
|
|
90 |
|
TH1F h_calo_iso("h_calo_iso","Calorimeter Isolation",100,0, 6); |
91 |
|
TH1F h_calo_iso_2("h_calo_iso_2","Calorimeter Isolation",100,0, 6); |
112 |
|
h_sphericity . SetFillColor(2); |
113 |
|
h_sphericity_2 . SetFillColor(3); |
114 |
|
|
43 |
– |
TCut sig_cut = ttbar; |
44 |
– |
TCut bg_cut = wzjets; |
45 |
– |
|
115 |
|
//TCanvas c("canvas", "canvas", 770, 595); |
47 |
– |
TCanvas c("canvas", "canvas", 800, 400); |
116 |
|
|
117 |
|
//chain . Draw("process_id>>h_id", weight); |
118 |
|
//chain . Draw("process_id>>h_id_2", weight*sig_cut, "same"); |
119 |
|
h_id . SetMarkerSize(1.5); |
120 |
|
chain . Draw("process_id>>h_id", weight, "TEXT"); |
121 |
< |
|
54 |
< |
//chain . Draw("aplanarity>>h_apl", weight*(sig_cut || bg_cut)); |
55 |
< |
//chain . Draw("aplanarity>>h_apl_2", weight*sig_cut, "same"); |
56 |
< |
|
57 |
< |
//chain . Draw("et3>>h_et3", weight*(!ttbar)); |
58 |
< |
//chain . Draw("et3>>h_et3_2", weight*ttbar, "same"); |
59 |
< |
|
60 |
< |
//chain . Draw("ht2p>>h_ht2p", weight*(!ttbar)); |
61 |
< |
//chain . Draw("ht2p>>h_ht2p_2", weight*ttbar, "same"); |
62 |
< |
|
63 |
< |
//chain . Draw("sphericity>>h_sphericity", weight*(!ttbar)); |
64 |
< |
//chain . Draw("sphericity>>h_sphericity_2", weight*ttbar, "same"); |
65 |
< |
|
66 |
< |
//c.GetPad(0)->SetLogy(); |
67 |
< |
//chain . Draw("lepton_track_iso>>h_track_iso", weight*(ttbar||wzjets) ); |
68 |
< |
//chain . Draw("lepton_track_iso>>h_track_iso_2", weight*wzjets, "same"); |
69 |
< |
|
70 |
< |
//c.GetPad(0)->SetLogy(); |
71 |
< |
//chain . Draw("lepton_calo_iso>>h_calo_iso", weight*ttbar ); |
72 |
< |
//chain . Draw("lepton_calo_iso>>h_calo_iso_2", weight*wzjets, "same"); |
121 |
> |
*/ |
122 |
|
} |