void atlasClosure_Central() { //=========Macro generated from canvas: atlasClosure/atlasClosure_Central/atlasClosure/atlasClosure_Central //========= (Wed Jun 8 17:48:17 2016) by ROOT version6.02/05 TCanvas *atlasClosure/atlasClosure_Central = new TCanvas("atlasClosure/atlasClosure_Central", "atlasClosure/atlasClosure_Central",0,0,600,600); gStyle->SetOptStat(0); gStyle->SetOptTitle(0); atlasClosure/atlasClosure_Central->SetHighLightColor(2); atlasClosure/atlasClosure_Central->Range(0,0,1,1); atlasClosure/atlasClosure_Central->SetFillColor(0); atlasClosure/atlasClosure_Central->SetBorderMode(0); atlasClosure/atlasClosure_Central->SetBorderSize(2); atlasClosure/atlasClosure_Central->SetTickx(1); atlasClosure/atlasClosure_Central->SetTicky(1); atlasClosure/atlasClosure_Central->SetLeftMargin(0.13); atlasClosure/atlasClosure_Central->SetRightMargin(0.05); atlasClosure/atlasClosure_Central->SetTopMargin(0.08); atlasClosure/atlasClosure_Central->SetBottomMargin(0.13); atlasClosure/atlasClosure_Central->SetFrameFillStyle(0); atlasClosure/atlasClosure_Central->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.3997647,201.5854,4.915976); 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_sf1 = new TH1F("atlas_pos_sf1","",19,0,190); atlas_pos_sf1->SetBinContent(1,18792); atlas_pos_sf1->SetBinContent(2,16459); atlas_pos_sf1->SetBinContent(3,12768); atlas_pos_sf1->SetBinContent(4,9145); atlas_pos_sf1->SetBinContent(5,5848); atlas_pos_sf1->SetBinContent(6,3645); atlas_pos_sf1->SetBinContent(7,2243); atlas_pos_sf1->SetBinContent(8,1328); atlas_pos_sf1->SetBinContent(9,769); atlas_pos_sf1->SetBinContent(10,442); atlas_pos_sf1->SetBinContent(11,281); atlas_pos_sf1->SetBinContent(12,201); atlas_pos_sf1->SetBinContent(13,109); atlas_pos_sf1->SetBinContent(14,81); atlas_pos_sf1->SetBinContent(15,49); atlas_pos_sf1->SetBinContent(16,38); atlas_pos_sf1->SetBinContent(17,23); atlas_pos_sf1->SetBinContent(18,19); atlas_pos_sf1->SetBinContent(19,90); atlas_pos_sf1->SetBinError(1,137.0912); atlas_pos_sf1->SetBinError(2,128.316); atlas_pos_sf1->SetBinError(3,113.0044); atlas_pos_sf1->SetBinError(4,95.63995); atlas_pos_sf1->SetBinError(5,76.47222); atlas_pos_sf1->SetBinError(6,60.3904); atlas_pos_sf1->SetBinError(7,47.38143); atlas_pos_sf1->SetBinError(8,36.49658); atlas_pos_sf1->SetBinError(9,27.73085); atlas_pos_sf1->SetBinError(10,21.07131); atlas_pos_sf1->SetBinError(11,16.76305); atlas_pos_sf1->SetBinError(12,14.17745); atlas_pos_sf1->SetBinError(13,10.44031); atlas_pos_sf1->SetBinError(14,9); atlas_pos_sf1->SetBinError(15,7); atlas_pos_sf1->SetBinError(16,6.324555); atlas_pos_sf1->SetBinError(17,4.795832); atlas_pos_sf1->SetBinError(18,4.795832); atlas_pos_sf1->SetBinError(19,9.797959); atlas_pos_sf1->SetEntries(72296.02); atlas_pos_sf1->SetStats(0); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#ff0000"); atlas_pos_sf1->SetLineColor(ci); atlas_pos_sf1->SetLineWidth(2); ci = TColor::GetColor("#ff0000"); atlas_pos_sf1->SetMarkerColor(ci); atlas_pos_sf1->SetMarkerStyle(20); atlas_pos_sf1->GetXaxis()->SetTitle("JZB [GeV]"); atlas_pos_sf1->GetXaxis()->SetLabelFont(42); atlas_pos_sf1->GetXaxis()->SetLabelOffset(0.007); atlas_pos_sf1->GetXaxis()->SetTitleSize(0.05); atlas_pos_sf1->GetXaxis()->SetTitleFont(42); atlas_pos_sf1->GetYaxis()->SetTitle("Events / 10 GeV"); atlas_pos_sf1->GetYaxis()->SetLabelFont(42); atlas_pos_sf1->GetYaxis()->SetLabelOffset(0.007); atlas_pos_sf1->GetYaxis()->SetTitleSize(0.05); atlas_pos_sf1->GetYaxis()->SetTitleOffset(1.1); atlas_pos_sf1->GetYaxis()->SetTitleFont(42); atlas_pos_sf1->GetZaxis()->SetLabelFont(42); atlas_pos_sf1->GetZaxis()->SetLabelOffset(0.007); atlas_pos_sf1->GetZaxis()->SetTitleSize(0.05); atlas_pos_sf1->GetZaxis()->SetTitleFont(42); atlas_pos_sf1->Draw("E,"); TH1F *atlas_neg_sf2 = new TH1F("atlas_neg_sf2","",19,0,190); atlas_neg_sf2->SetBinContent(1,18867); atlas_neg_sf2->SetBinContent(2,16576); atlas_neg_sf2->SetBinContent(3,13153); atlas_neg_sf2->SetBinContent(4,9423); atlas_neg_sf2->SetBinContent(5,5962); atlas_neg_sf2->SetBinContent(6,3866); atlas_neg_sf2->SetBinContent(7,2338); atlas_neg_sf2->SetBinContent(8,1335); atlas_neg_sf2->SetBinContent(9,866); atlas_neg_sf2->SetBinContent(10,510); atlas_neg_sf2->SetBinContent(11,345); atlas_neg_sf2->SetBinContent(12,233); atlas_neg_sf2->SetBinContent(13,147); atlas_neg_sf2->SetBinContent(14,109); atlas_neg_sf2->SetBinContent(15,81); atlas_neg_sf2->SetBinContent(16,46); atlas_neg_sf2->SetBinContent(17,34); atlas_neg_sf2->SetBinContent(18,33); atlas_neg_sf2->SetBinContent(19,124); atlas_neg_sf2->SetBinError(1,137.379); atlas_neg_sf2->SetBinError(2,128.7556); atlas_neg_sf2->SetBinError(3,114.704); atlas_neg_sf2->SetBinError(4,97.07214); atlas_neg_sf2->SetBinError(5,77.21399); atlas_neg_sf2->SetBinError(6,62.17717); atlas_neg_sf2->SetBinError(7,48.35287); atlas_neg_sf2->SetBinError(8,36.53765); atlas_neg_sf2->SetBinError(9,29.42788); atlas_neg_sf2->SetBinError(10,22.58318); atlas_neg_sf2->SetBinError(11,18.57418); atlas_neg_sf2->SetBinError(12,15.32971); atlas_neg_sf2->SetBinError(13,12.12436); atlas_neg_sf2->SetBinError(14,10.44031); atlas_neg_sf2->SetBinError(15,9); atlas_neg_sf2->SetBinError(16,6.78233); atlas_neg_sf2->SetBinError(17,5.830952); atlas_neg_sf2->SetBinError(18,5.744563); atlas_neg_sf2->SetBinError(19,11.13553); atlas_neg_sf2->SetEntries(74034); atlas_neg_sf2->SetStats(0); ci = TColor::GetColor("#0000ff"); atlas_neg_sf2->SetLineColor(ci); atlas_neg_sf2->SetLineWidth(2); ci = TColor::GetColor("#0000ff"); atlas_neg_sf2->SetMarkerColor(ci); atlas_neg_sf2->SetMarkerStyle(20); atlas_neg_sf2->GetXaxis()->SetTitle("JZB [GeV]"); atlas_neg_sf2->GetXaxis()->SetLabelFont(42); atlas_neg_sf2->GetXaxis()->SetLabelOffset(0.007); atlas_neg_sf2->GetXaxis()->SetTitleSize(0.05); atlas_neg_sf2->GetXaxis()->SetTitleFont(42); atlas_neg_sf2->GetYaxis()->SetTitle("Events / 10 GeV"); atlas_neg_sf2->GetYaxis()->SetLabelFont(42); atlas_neg_sf2->GetYaxis()->SetLabelOffset(0.007); atlas_neg_sf2->GetYaxis()->SetTitleSize(0.05); atlas_neg_sf2->GetYaxis()->SetTitleOffset(1.1); atlas_neg_sf2->GetYaxis()->SetTitleFont(42); atlas_neg_sf2->GetZaxis()->SetLabelFont(42); atlas_neg_sf2->GetZaxis()->SetLabelOffset(0.007); atlas_neg_sf2->GetZaxis()->SetTitleSize(0.05); atlas_neg_sf2->GetZaxis()->SetTitleFont(42); atlas_neg_sf2->Draw("HIST,SAME"); TLegend *leg = new TLegend(0.15,0.4,0.35,0.72,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(2); 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_Central->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 *atlas_neg_sf_ratio3 = new TH1F("atlas_neg_sf_ratio3","",19,0,190); atlas_neg_sf_ratio3->SetBinContent(1,0.9960248); atlas_neg_sf_ratio3->SetBinContent(2,0.9929416); atlas_neg_sf_ratio3->SetBinContent(3,0.9707291); atlas_neg_sf_ratio3->SetBinContent(4,0.9704977); atlas_neg_sf_ratio3->SetBinContent(5,0.9808789); atlas_neg_sf_ratio3->SetBinContent(6,0.942835); atlas_neg_sf_ratio3->SetBinContent(7,0.959367); atlas_neg_sf_ratio3->SetBinContent(8,0.9947566); atlas_neg_sf_ratio3->SetBinContent(9,0.8879908); atlas_neg_sf_ratio3->SetBinContent(10,0.8666667); atlas_neg_sf_ratio3->SetBinContent(11,0.8144928); atlas_neg_sf_ratio3->SetBinContent(12,0.8626609); atlas_neg_sf_ratio3->SetBinContent(13,0.7414966); atlas_neg_sf_ratio3->SetBinContent(14,0.7431192); atlas_neg_sf_ratio3->SetBinContent(15,0.6049383); atlas_neg_sf_ratio3->SetBinContent(16,0.8260869); atlas_neg_sf_ratio3->SetBinContent(17,0.6764706); atlas_neg_sf_ratio3->SetBinContent(18,0.5757576); atlas_neg_sf_ratio3->SetBinContent(19,0.7258065); atlas_neg_sf_ratio3->SetBinError(1,0.01026627); atlas_neg_sf_ratio3->SetBinError(2,0.01092753); atlas_neg_sf_ratio3->SetBinError(3,0.01206146); atlas_neg_sf_ratio3->SetBinError(4,0.01424671); atlas_neg_sf_ratio3->SetBinError(5,0.01805264); atlas_neg_sf_ratio3->SetBinError(6,0.02177039); atlas_neg_sf_ratio3->SetBinError(7,0.02836134); atlas_neg_sf_ratio3->SetBinError(8,0.0385825); atlas_neg_sf_ratio3->SetBinError(9,0.04399924); atlas_neg_sf_ratio3->SetBinError(10,0.05638974); atlas_neg_sf_ratio3->SetBinError(11,0.06545031); atlas_neg_sf_ratio3->SetBinError(12,0.08320905); atlas_neg_sf_ratio3->SetBinError(13,0.09372538); atlas_neg_sf_ratio3->SetBinError(14,0.1090133); atlas_neg_sf_ratio3->SetBinError(15,0.1094819); atlas_neg_sf_ratio3->SetBinError(16,0.1836813); atlas_neg_sf_ratio3->SetBinError(17,0.1826346); atlas_neg_sf_ratio3->SetBinError(18,0.176538); atlas_neg_sf_ratio3->SetBinError(19,0.1024297); atlas_neg_sf_ratio3->SetMinimum(0); atlas_neg_sf_ratio3->SetMaximum(2); atlas_neg_sf_ratio3->SetEntries(1612.748); atlas_neg_sf_ratio3->SetStats(0); ci = TColor::GetColor("#0000ff"); atlas_neg_sf_ratio3->SetLineColor(ci); atlas_neg_sf_ratio3->SetLineWidth(2); ci = TColor::GetColor("#0000ff"); atlas_neg_sf_ratio3->SetMarkerColor(ci); atlas_neg_sf_ratio3->SetMarkerStyle(20); atlas_neg_sf_ratio3->GetXaxis()->SetLabelFont(42); atlas_neg_sf_ratio3->GetXaxis()->SetLabelOffset(0.007); atlas_neg_sf_ratio3->GetXaxis()->SetLabelSize(0.12); atlas_neg_sf_ratio3->GetXaxis()->SetTitleSize(0.14); atlas_neg_sf_ratio3->GetXaxis()->SetTitleFont(42); atlas_neg_sf_ratio3->GetYaxis()->SetTitle("Ratio"); atlas_neg_sf_ratio3->GetYaxis()->CenterTitle(true); atlas_neg_sf_ratio3->GetYaxis()->SetNdivisions(4); atlas_neg_sf_ratio3->GetYaxis()->SetLabelFont(42); atlas_neg_sf_ratio3->GetYaxis()->SetLabelOffset(0.007); atlas_neg_sf_ratio3->GetYaxis()->SetLabelSize(0.12); atlas_neg_sf_ratio3->GetYaxis()->SetTitleSize(0.14); atlas_neg_sf_ratio3->GetYaxis()->SetTitleOffset(0.3); atlas_neg_sf_ratio3->GetYaxis()->SetTitleFont(42); atlas_neg_sf_ratio3->GetZaxis()->SetLabelFont(42); atlas_neg_sf_ratio3->GetZaxis()->SetLabelOffset(0.007); atlas_neg_sf_ratio3->GetZaxis()->SetTitleSize(0.05); atlas_neg_sf_ratio3->GetZaxis()->SetTitleFont(42); atlas_neg_sf_ratio3->Draw("HIST,"); TLine *line = new TLine(0,1,190,1); ci = TColor::GetColor("#666666"); line->SetLineColor(ci); line->Draw(); pad2->Modified(); atlasClosure/atlasClosure_Central->cd(); atlasClosure/atlasClosure_Central->Modified(); atlasClosure/atlasClosure_Central->cd(); atlasClosure/atlasClosure_Central->SetSelected(atlasClosure/atlasClosure_Central); }