void atlasClosure_Forward() { //=========Macro generated from canvas: atlasClosure/atlasClosure_Forward/atlasClosure/atlasClosure_Forward //========= (Thu Jun 23 08:37:44 2016) by ROOT version6.06/01 TCanvas *atlasClosure/atlasClosure_Forward = new TCanvas("atlasClosure/atlasClosure_Forward", "atlasClosure/atlasClosure_Forward",0,0,600,600); gStyle->SetOptFit(1); gStyle->SetOptStat(0); gStyle->SetOptTitle(0); atlasClosure/atlasClosure_Forward->SetHighLightColor(2); atlasClosure/atlasClosure_Forward->Range(0,0,1,1); atlasClosure/atlasClosure_Forward->SetFillColor(0); atlasClosure/atlasClosure_Forward->SetBorderMode(0); atlasClosure/atlasClosure_Forward->SetBorderSize(2); atlasClosure/atlasClosure_Forward->SetTickx(1); atlasClosure/atlasClosure_Forward->SetTicky(1); atlasClosure/atlasClosure_Forward->SetLeftMargin(0.13); atlasClosure/atlasClosure_Forward->SetRightMargin(0.05); atlasClosure/atlasClosure_Forward->SetTopMargin(0.08); atlasClosure/atlasClosure_Forward->SetBottomMargin(0.13); atlasClosure/atlasClosure_Forward->SetFrameFillStyle(0); atlasClosure/atlasClosure_Forward->SetFrameBorderMode(0); // ------------>Primitives in pad: pad1 TPad *pad1 = new TPad("pad1", "pad1",0,0.25,1,1); pad1->Draw(); pad1->cd(); pad1->Range(-30.12195,0.5587922,201.5854,5.522454); pad1->SetFillColor(0); pad1->SetBorderMode(0); pad1->SetBorderSize(2); pad1->SetLogy(); pad1->SetTickx(1); pad1->SetTicky(1); pad1->SetLeftMargin(0.13); pad1->SetRightMargin(0.05); pad1->SetTopMargin(0.08); pad1->SetFrameFillStyle(0); pad1->SetFrameBorderMode(0); pad1->SetFrameFillStyle(0); pad1->SetFrameBorderMode(0); TH1F *atlas_pos_sf__4 = new TH1F("atlas_pos_sf__4","",19,0,190); atlas_pos_sf__4->SetBinContent(1,70174); atlas_pos_sf__4->SetBinContent(2,59197); atlas_pos_sf__4->SetBinContent(3,42938); atlas_pos_sf__4->SetBinContent(4,27845); atlas_pos_sf__4->SetBinContent(5,16488); atlas_pos_sf__4->SetBinContent(6,9274); atlas_pos_sf__4->SetBinContent(7,4880); atlas_pos_sf__4->SetBinContent(8,2645); atlas_pos_sf__4->SetBinContent(9,1387); atlas_pos_sf__4->SetBinContent(10,747); atlas_pos_sf__4->SetBinContent(11,408); atlas_pos_sf__4->SetBinContent(12,273); atlas_pos_sf__4->SetBinContent(13,164); atlas_pos_sf__4->SetBinContent(14,101); atlas_pos_sf__4->SetBinContent(15,73); atlas_pos_sf__4->SetBinContent(16,56); atlas_pos_sf__4->SetBinContent(17,37); atlas_pos_sf__4->SetBinContent(18,28); atlas_pos_sf__4->SetBinContent(19,142); atlas_pos_sf__4->SetBinError(1,264.9038); atlas_pos_sf__4->SetBinError(2,243.3043); atlas_pos_sf__4->SetBinError(3,207.2149); atlas_pos_sf__4->SetBinError(4,166.8682); atlas_pos_sf__4->SetBinError(5,128.4056); atlas_pos_sf__4->SetBinError(6,96.30161); atlas_pos_sf__4->SetBinError(7,69.857); atlas_pos_sf__4->SetBinError(8,51.42956); atlas_pos_sf__4->SetBinError(9,37.24245); atlas_pos_sf__4->SetBinError(10,27.3313); atlas_pos_sf__4->SetBinError(11,20.19901); atlas_pos_sf__4->SetBinError(12,16.52271); atlas_pos_sf__4->SetBinError(13,12.80625); atlas_pos_sf__4->SetBinError(14,10.04988); atlas_pos_sf__4->SetBinError(15,8.544004); atlas_pos_sf__4->SetBinError(16,7.483315); atlas_pos_sf__4->SetBinError(17,6.082763); atlas_pos_sf__4->SetBinError(18,5.291503); atlas_pos_sf__4->SetBinError(19,11.91638); atlas_pos_sf__4->SetEntries(236857); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#ff0000"); atlas_pos_sf__4->SetLineColor(ci); ci = TColor::GetColor("#ff0000"); atlas_pos_sf__4->SetMarkerColor(ci); atlas_pos_sf__4->SetMarkerStyle(20); atlas_pos_sf__4->GetXaxis()->SetTitle("JZB [GeV]"); atlas_pos_sf__4->GetXaxis()->SetLabelFont(42); atlas_pos_sf__4->GetXaxis()->SetLabelOffset(0.007); atlas_pos_sf__4->GetXaxis()->SetTitleSize(0.05); atlas_pos_sf__4->GetXaxis()->SetTitleFont(42); atlas_pos_sf__4->GetYaxis()->SetTitle("Events / 10 GeV"); atlas_pos_sf__4->GetYaxis()->SetLabelFont(42); atlas_pos_sf__4->GetYaxis()->SetLabelOffset(0.007); atlas_pos_sf__4->GetYaxis()->SetTitleSize(0.05); atlas_pos_sf__4->GetYaxis()->SetTitleOffset(1.1); atlas_pos_sf__4->GetYaxis()->SetTitleFont(42); atlas_pos_sf__4->GetZaxis()->SetLabelFont(42); atlas_pos_sf__4->GetZaxis()->SetLabelOffset(0.007); atlas_pos_sf__4->GetZaxis()->SetTitleSize(0.05); atlas_pos_sf__4->GetZaxis()->SetTitleFont(42); atlas_pos_sf__4->Draw("E,"); TH1F *atlas_neg_sf__5 = new TH1F("atlas_neg_sf__5","",19,0,190); atlas_neg_sf__5->SetBinContent(1,69794); atlas_neg_sf__5->SetBinContent(2,57653); atlas_neg_sf__5->SetBinContent(3,40800); atlas_neg_sf__5->SetBinContent(4,25492); atlas_neg_sf__5->SetBinContent(5,14620); atlas_neg_sf__5->SetBinContent(6,7881); atlas_neg_sf__5->SetBinContent(7,4115); atlas_neg_sf__5->SetBinContent(8,2136); atlas_neg_sf__5->SetBinContent(9,1160); atlas_neg_sf__5->SetBinContent(10,629); atlas_neg_sf__5->SetBinContent(11,370); atlas_neg_sf__5->SetBinContent(12,205); atlas_neg_sf__5->SetBinContent(13,120); atlas_neg_sf__5->SetBinContent(14,82); atlas_neg_sf__5->SetBinContent(15,52); atlas_neg_sf__5->SetBinContent(16,47); atlas_neg_sf__5->SetBinContent(17,22); atlas_neg_sf__5->SetBinContent(18,22); atlas_neg_sf__5->SetBinContent(19,61); atlas_neg_sf__5->SetBinError(1,264.1855); atlas_neg_sf__5->SetBinError(2,240.1104); atlas_neg_sf__5->SetBinError(3,201.9901); atlas_neg_sf__5->SetBinError(4,159.6621); atlas_neg_sf__5->SetBinError(5,120.9132); atlas_neg_sf__5->SetBinError(6,88.775); atlas_neg_sf__5->SetBinError(7,64.14827); atlas_neg_sf__5->SetBinError(8,46.21688); atlas_neg_sf__5->SetBinError(9,34.05877); atlas_neg_sf__5->SetBinError(10,25.07987); atlas_neg_sf__5->SetBinError(11,19.23538); atlas_neg_sf__5->SetBinError(12,14.31782); atlas_neg_sf__5->SetBinError(13,10.95445); atlas_neg_sf__5->SetBinError(14,9.055385); atlas_neg_sf__5->SetBinError(15,7.211103); atlas_neg_sf__5->SetBinError(16,6.855655); atlas_neg_sf__5->SetBinError(17,4.690416); atlas_neg_sf__5->SetBinError(18,4.690416); atlas_neg_sf__5->SetBinError(19,7.81025); atlas_neg_sf__5->SetEntries(225261); ci = TColor::GetColor("#0000ff"); atlas_neg_sf__5->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); atlas_neg_sf__5->SetMarkerColor(ci); atlas_neg_sf__5->SetMarkerStyle(20); atlas_neg_sf__5->GetXaxis()->SetTitle("JZB [GeV]"); atlas_neg_sf__5->GetXaxis()->SetLabelFont(42); atlas_neg_sf__5->GetXaxis()->SetLabelOffset(0.007); atlas_neg_sf__5->GetXaxis()->SetTitleSize(0.05); atlas_neg_sf__5->GetXaxis()->SetTitleFont(42); atlas_neg_sf__5->GetYaxis()->SetTitle("Events / 10 GeV"); atlas_neg_sf__5->GetYaxis()->SetLabelFont(42); atlas_neg_sf__5->GetYaxis()->SetLabelOffset(0.007); atlas_neg_sf__5->GetYaxis()->SetTitleSize(0.05); atlas_neg_sf__5->GetYaxis()->SetTitleOffset(1.1); atlas_neg_sf__5->GetYaxis()->SetTitleFont(42); atlas_neg_sf__5->GetZaxis()->SetLabelFont(42); atlas_neg_sf__5->GetZaxis()->SetLabelOffset(0.007); atlas_neg_sf__5->GetZaxis()->SetTitleSize(0.05); atlas_neg_sf__5->GetZaxis()->SetTitleFont(42); atlas_neg_sf__5->Draw("HIST,SAME"); TLegend *leg = new TLegend(0.7,0.55,0.9,0.87,NULL,"brNDC"); leg->SetBorderSize(0); leg->SetTextSize(0.04); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(0); leg->SetFillColor(0); leg->SetFillStyle(1001); TLegendEntry *entry=leg->AddEntry("atlas_pos_sf","JZB > 0","P"); entry->SetLineColor(1); entry->SetLineStyle(1); entry->SetLineWidth(1); ci = TColor::GetColor("#ff0000"); entry->SetMarkerColor(ci); entry->SetMarkerStyle(20); entry->SetMarkerSize(1); entry->SetTextFont(42); entry=leg->AddEntry("atlas_neg_sf","JZB < 0","L"); ci = TColor::GetColor("#0000ff"); entry->SetLineColor(ci); entry->SetLineStyle(1); entry->SetLineWidth(1); entry->SetMarkerColor(1); entry->SetMarkerStyle(21); entry->SetMarkerSize(1); entry->SetTextFont(42); leg->Draw(); TLatex * tex = new TLatex(0.21,0.93,"CMS"); tex->SetNDC(); tex->SetTextAlign(31); tex->SetTextFont(42); tex->SetLineWidth(2); tex->Draw(); tex = new TLatex(0.33,0.93,"Simulation"); tex->SetNDC(); tex->SetTextAlign(31); tex->SetTextFont(42); tex->SetTextSize(0.03); tex->SetLineWidth(2); tex->Draw(); tex = new TLatex(0.9,0.93,"2.3 fb^{-1} (13 TeV)"); tex->SetNDC(); tex->SetTextAlign(31); tex->SetTextFont(42); tex->SetLineWidth(2); tex->Draw(); pad1->Modified(); atlasClosure/atlasClosure_Forward->cd(); // ------------>Primitives in pad: pad2 TPad *pad2 = new TPad("pad2", "pad2",0,0.05,1,0.25); pad2->Draw(); pad2->cd(); pad2->Range(-30.12195,-1,201.5854,2.333333); pad2->SetFillColor(0); pad2->SetBorderMode(0); pad2->SetBorderSize(2); pad2->SetTickx(1); pad2->SetTicky(1); pad2->SetLeftMargin(0.13); pad2->SetRightMargin(0.05); pad2->SetBottomMargin(0.3); pad2->SetFrameFillStyle(0); pad2->SetFrameBorderMode(0); pad2->SetFrameFillStyle(0); pad2->SetFrameBorderMode(0); TH1F *neg_sf_ratio_ratio__6 = new TH1F("neg_sf_ratio_ratio__6","",19,0,190); neg_sf_ratio_ratio__6->SetBinContent(1,1.005445); neg_sf_ratio_ratio__6->SetBinContent(2,1.026781); neg_sf_ratio_ratio__6->SetBinContent(3,1.052402); neg_sf_ratio_ratio__6->SetBinContent(4,1.092304); neg_sf_ratio_ratio__6->SetBinContent(5,1.12777); neg_sf_ratio_ratio__6->SetBinContent(6,1.176754); neg_sf_ratio_ratio__6->SetBinContent(7,1.185905); neg_sf_ratio_ratio__6->SetBinContent(8,1.238296); neg_sf_ratio_ratio__6->SetBinContent(9,1.19569); neg_sf_ratio_ratio__6->SetBinContent(10,1.187599); neg_sf_ratio_ratio__6->SetBinContent(11,1.102703); neg_sf_ratio_ratio__6->SetBinContent(12,1.331707); neg_sf_ratio_ratio__6->SetBinContent(13,1.366667); neg_sf_ratio_ratio__6->SetBinContent(14,1.231707); neg_sf_ratio_ratio__6->SetBinContent(15,1.403846); neg_sf_ratio_ratio__6->SetBinContent(16,1.191489); neg_sf_ratio_ratio__6->SetBinContent(17,1.681818); neg_sf_ratio_ratio__6->SetBinContent(18,1.272727); neg_sf_ratio_ratio__6->SetBinContent(19,2.327869); neg_sf_ratio_ratio__6->SetBinError(1,0.005374962); neg_sf_ratio_ratio__6->SetBinError(2,0.00600802); neg_sf_ratio_ratio__6->SetBinError(3,0.007275988); neg_sf_ratio_ratio__6->SetBinError(4,0.009468519); neg_sf_ratio_ratio__6->SetBinError(5,0.01281147); neg_sf_ratio_ratio__6->SetBinError(6,0.01802839); neg_sf_ratio_ratio__6->SetBinError(7,0.02509896); neg_sf_ratio_ratio__6->SetBinError(8,0.03602221); neg_sf_ratio_ratio__6->SetBinError(9,0.04757357); neg_sf_ratio_ratio__6->SetBinError(10,0.06426782); neg_sf_ratio_ratio__6->SetBinError(11,0.0791621); neg_sf_ratio_ratio__6->SetBinError(12,0.1230735); neg_sf_ratio_ratio__6->SetBinError(13,0.1641758); neg_sf_ratio_ratio__6->SetBinError(14,0.1830903); neg_sf_ratio_ratio__6->SetBinError(15,0.2547484); neg_sf_ratio_ratio__6->SetBinError(16,0.2357034); neg_sf_ratio_ratio__6->SetBinError(17,0.4527859); neg_sf_ratio_ratio__6->SetBinError(18,0.3626018); neg_sf_ratio_ratio__6->SetBinError(19,0.356367); neg_sf_ratio_ratio__6->SetMinimum(0); neg_sf_ratio_ratio__6->SetMaximum(2); neg_sf_ratio_ratio__6->SetEntries(867.7668); ci = TColor::GetColor("#666699"); neg_sf_ratio_ratio__6->SetFillColor(ci); ci = TColor::GetColor("#0000ff"); neg_sf_ratio_ratio__6->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); neg_sf_ratio_ratio__6->SetMarkerColor(ci); neg_sf_ratio_ratio__6->SetMarkerStyle(20); neg_sf_ratio_ratio__6->SetMarkerSize(0); neg_sf_ratio_ratio__6->GetXaxis()->SetLabelFont(42); neg_sf_ratio_ratio__6->GetXaxis()->SetLabelOffset(0.007); neg_sf_ratio_ratio__6->GetXaxis()->SetLabelSize(0.12); neg_sf_ratio_ratio__6->GetXaxis()->SetTitleSize(0.14); neg_sf_ratio_ratio__6->GetXaxis()->SetTitleFont(42); neg_sf_ratio_ratio__6->GetYaxis()->SetTitle("Ratio"); neg_sf_ratio_ratio__6->GetYaxis()->CenterTitle(true); neg_sf_ratio_ratio__6->GetYaxis()->SetNdivisions(4); neg_sf_ratio_ratio__6->GetYaxis()->SetLabelFont(42); neg_sf_ratio_ratio__6->GetYaxis()->SetLabelOffset(0.007); neg_sf_ratio_ratio__6->GetYaxis()->SetLabelSize(0.12); neg_sf_ratio_ratio__6->GetYaxis()->SetTitleSize(0.14); neg_sf_ratio_ratio__6->GetYaxis()->SetTitleOffset(0.3); neg_sf_ratio_ratio__6->GetYaxis()->SetTitleFont(42); neg_sf_ratio_ratio__6->GetZaxis()->SetLabelFont(42); neg_sf_ratio_ratio__6->GetZaxis()->SetLabelOffset(0.007); neg_sf_ratio_ratio__6->GetZaxis()->SetTitleSize(0.05); neg_sf_ratio_ratio__6->GetZaxis()->SetTitleFont(42); neg_sf_ratio_ratio__6->Draw("E2,"); Double_t Graph0_fx2[4] = { 0, 190, 190, 0}; Double_t Graph0_fy2[4] = { 0.7, 0.7, 1.3, 1.3}; TGraph *graph = new TGraph(4,Graph0_fx2,Graph0_fy2); graph->SetName("Graph0"); graph->SetTitle("Graph"); ci = 1436; color = new TColor(ci, 1, 0, 0, " ", 0.4); graph->SetFillColor(ci); graph->SetMarkerStyle(20); TH1F *Graph_Graph2 = new TH1F("Graph_Graph2","Graph",100,0,209); Graph_Graph2->SetMinimum(0.64); Graph_Graph2->SetMaximum(1.36); Graph_Graph2->SetDirectory(0); Graph_Graph2->SetStats(0); Graph_Graph2->SetMarkerStyle(20); Graph_Graph2->GetXaxis()->SetLabelFont(42); Graph_Graph2->GetXaxis()->SetLabelOffset(0.007); Graph_Graph2->GetXaxis()->SetTitleSize(0.05); Graph_Graph2->GetXaxis()->SetTitleFont(42); Graph_Graph2->GetYaxis()->SetLabelFont(42); Graph_Graph2->GetYaxis()->SetLabelOffset(0.007); Graph_Graph2->GetYaxis()->SetTitleSize(0.05); Graph_Graph2->GetYaxis()->SetTitleOffset(1.1); Graph_Graph2->GetYaxis()->SetTitleFont(42); Graph_Graph2->GetZaxis()->SetLabelFont(42); Graph_Graph2->GetZaxis()->SetLabelOffset(0.007); Graph_Graph2->GetZaxis()->SetTitleSize(0.05); Graph_Graph2->GetZaxis()->SetTitleFont(42); graph->SetHistogram(Graph_Graph2); graph->Draw("f"); TLine *line = new TLine(0,1,190,1); ci = TColor::GetColor("#666666"); line->SetLineColor(ci); line->Draw(); pad2->Modified(); atlasClosure/atlasClosure_Forward->cd(); atlasClosure/atlasClosure_Forward->Modified(); atlasClosure/atlasClosure_Forward->cd(); atlasClosure/atlasClosure_Forward->SetSelected(atlasClosure/atlasClosure_Forward); }