5 unsigned col1 = kOrange+7;
6 unsigned col2 = kBlue+2;
9 TChain chain_r05(
"ntp_recojet");
10 chain_r05.Add(
"data_3pions/p250_e20_0events_file1093_jeteval_r05.root");
11 chain_r05.Add(
"data_3pions/p250_e20_0events_file1096_jeteval_r05.root");
12 chain_r05.Add(
"data_3pions/p250_e20_0events_file1101_jeteval_r05.root");
13 chain_r05.Add(
"data_3pions/p250_e20_0events_file1115_jeteval_r05.root");
14 chain_r05.Add(
"data_3pions/p250_e20_0events_file1122_jeteval_r05.root");
15 chain_r05.Add(
"data_3pions/p250_e20_0events_file1127_jeteval_r05.root");
16 chain_r05.Add(
"data_3pions/p250_e20_0events_file1131_jeteval_r05.root");
17 chain_r05.Add(
"data_3pions/p250_e20_0events_file1164_jeteval_r05.root");
19 TChain chain_r10(
"ntp_recojet");
20 chain_r10.Add(
"data_3pions/p250_e20_0events_file1093_jeteval_r10.root");
21 chain_r10.Add(
"data_3pions/p250_e20_0events_file1096_jeteval_r10.root");
22 chain_r10.Add(
"data_3pions/p250_e20_0events_file1101_jeteval_r10.root");
23 chain_r10.Add(
"data_3pions/p250_e20_0events_file1115_jeteval_r10.root");
24 chain_r10.Add(
"data_3pions/p250_e20_0events_file1122_jeteval_r10.root");
25 chain_r10.Add(
"data_3pions/p250_e20_0events_file1127_jeteval_r10.root");
26 chain_r10.Add(
"data_3pions/p250_e20_0events_file1131_jeteval_r10.root");
27 chain_r10.Add(
"data_3pions/p250_e20_0events_file1164_jeteval_r10.root");
30 TCut select_jet(
"abs(eta) < 1 && pt > 5 && ge < 100" );
33 TH1F* h1_jet_r05_e =
new TH1F(
"h1_jet_r05_e",
";(E_{reco} - E_{true}) / E_{true};", 100, -1, 1 );
34 h1_jet_r05_e->GetXaxis()->SetNdivisions(505);
35 h1_jet_r05_e->GetYaxis()->SetNdivisions(505);
36 h1_jet_r05_e->SetLineColor(col2);
38 TH1F* h1_jet_r10_e = (TH1F*)h1_jet_r05_e->Clone(
"h1_jet_r10_e");
39 h1_jet_r10_e->SetLineColor(col1);
41 cout <<
">>>>> Jet energy: R=0.5" << endl;
42 chain_r05.Draw(
"(e-ge) / ge >> h1_jet_r05_e", select_jet );
43 h1_jet_r05_e->Scale( 1. / h1_jet_r05_e->Integral() );
44 h1_jet_r05_e->Fit(
"gaus");
46 cout <<
">>>>> Jet energy: R=1.0" << endl;
47 chain_r10.Draw(
"(e-ge) / ge >> h1_jet_r10_e", select_jet );
48 h1_jet_r10_e->Scale( 1. / h1_jet_r10_e->Integral() );
49 h1_jet_r10_e->Fit(
"gaus");
52 TH1F* h1_jet_r05_eta =
new TH1F(
"h1_jet_r05_eta",
";#eta_{reco}-#eta_{true};", 100, -0.25, 0.25 );
53 h1_jet_r05_eta->GetXaxis()->SetNdivisions(505);
54 h1_jet_r05_eta->GetYaxis()->SetNdivisions(505);
55 h1_jet_r05_eta->SetLineColor(col2);
57 TH1F* h1_jet_r10_eta = (TH1F*)h1_jet_r05_eta->Clone(
"h1_jet_r10_eta");
58 h1_jet_r10_eta->SetLineColor(col1);
60 cout <<
">>>>> Jet eta: R=0.5" << endl;
61 chain_r05.Draw(
"( eta - geta ) >> h1_jet_r05_eta", select_jet );
62 h1_jet_r05_eta->Scale( 1. / h1_jet_r05_eta->Integral() );
63 h1_jet_r05_eta->Fit(
"gaus");
65 cout <<
">>>>> Jet eta: R=1.0" << endl;
66 chain_r10.Draw(
"( eta - geta ) >> h1_jet_r10_eta", select_jet );
67 h1_jet_r10_eta->Scale( 1. / h1_jet_r10_eta->Integral() );
68 h1_jet_r10_eta->Fit(
"gaus");
71 TH1F* h1_jet_r05_phi =
new TH1F(
"h1_jet_r05_phi",
";#phi_{reco}-#phi_{true};", 100, -0.25, 0.25 );
72 h1_jet_r05_phi->GetXaxis()->SetNdivisions(505);
73 h1_jet_r05_phi->GetYaxis()->SetNdivisions(505);
74 h1_jet_r05_phi->SetLineColor(col2);
76 TH1F* h1_jet_r10_phi = (TH1F*)h1_jet_r05_phi->Clone(
"h1_jet_r10_phi");
77 h1_jet_r10_phi->SetLineColor(col1);
79 cout <<
">>>>> Jet phi: R=0.5" << endl;
80 chain_r05.Draw(
"( phi - gphi ) >> h1_jet_r05_phi", select_jet );
81 h1_jet_r05_phi->Scale( 1. / h1_jet_r05_phi->Integral() );
82 h1_jet_r05_phi->Fit(
"gaus");
84 cout <<
">>>>> Jet phi: R=1.0" << endl;
85 chain_r10.Draw(
"( phi - gphi ) >> h1_jet_r10_phi", select_jet );
86 h1_jet_r10_phi->Scale( 1. / h1_jet_r10_phi->Integral() );
87 h1_jet_r10_phi->Fit(
"gaus");
90 TCanvas *c1 =
new TCanvas();
91 h1_jet_r05_e->Draw(
"");
92 h1_jet_r10_e->Draw(
"same");
93 c1->Print(
"plots/jet_reco_escale.eps");
94 c1->Print(
"plots/jet_reco_escale.png");
96 TCanvas *
c2 =
new TCanvas();
97 h1_jet_r05_eta->Draw(
"");
98 h1_jet_r10_eta->Draw(
"same");
99 c2->Print(
"plots/jet_reco_eta.eps");
100 c2->Print(
"plots/jet_reco_eta.png");
102 TCanvas *c3 =
new TCanvas();
103 h1_jet_r05_phi->Draw(
"");
104 h1_jet_r10_phi->Draw(
"same");
105 c3->Print(
"plots/jet_reco_phi.eps");
106 c3->Print(
"plots/jet_reco_phi.png");
108 TCanvas *c6 =
new TCanvas();
109 chain_r05.Draw(
"e : ge", select_jet,
"colz");
111 TCanvas *c4 =
new TCanvas();
112 chain_r05.Draw(
"eta : geta", select_jet,
"colz");
114 TCanvas *c5 =
new TCanvas();
115 chain_r05.Draw(
"phi : gphi", select_jet,
"colz");