void closure_3jets_HT_Central() { //=========Macro generated from canvas: finalPlots/closure_3jets_HT_Central/finalPlots/closure_3jets_HT_Central //========= (Fri May 20 12:36:48 2016) by ROOT version6.02/05 TCanvas *finalPlots/closure_3jets_HT_Central = new TCanvas("finalPlots/closure_3jets_HT_Central", "finalPlots/closure_3jets_HT_Central",0,0,600,600); gStyle->SetOptStat(0); gStyle->SetOptTitle(0); finalPlots/closure_3jets_HT_Central->SetHighLightColor(2); finalPlots/closure_3jets_HT_Central->Range(0,0,1,1); finalPlots/closure_3jets_HT_Central->SetFillColor(0); finalPlots/closure_3jets_HT_Central->SetBorderMode(0); finalPlots/closure_3jets_HT_Central->SetBorderSize(2); finalPlots/closure_3jets_HT_Central->SetTickx(1); finalPlots/closure_3jets_HT_Central->SetTicky(1); finalPlots/closure_3jets_HT_Central->SetLeftMargin(0.13); finalPlots/closure_3jets_HT_Central->SetRightMargin(0.05); finalPlots/closure_3jets_HT_Central->SetTopMargin(0.08); finalPlots/closure_3jets_HT_Central->SetBottomMargin(0.13); finalPlots/closure_3jets_HT_Central->SetFrameFillStyle(0); finalPlots/closure_3jets_HT_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,-1.908019,201.5854,3.895935); 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 *dy3jetsHTSFCentral_pos1 = new TH1F("dy3jetsHTSFCentral_pos1","",19,0,190); dy3jetsHTSFCentral_pos1->SetBinContent(1,1406.187); dy3jetsHTSFCentral_pos1->SetBinContent(2,1063.019); dy3jetsHTSFCentral_pos1->SetBinContent(3,637.951); dy3jetsHTSFCentral_pos1->SetBinContent(4,315.9357); dy3jetsHTSFCentral_pos1->SetBinContent(5,138.7825); dy3jetsHTSFCentral_pos1->SetBinContent(6,57.0872); dy3jetsHTSFCentral_pos1->SetBinContent(7,24.82734); dy3jetsHTSFCentral_pos1->SetBinContent(8,7.691881); dy3jetsHTSFCentral_pos1->SetBinContent(9,4.039113); dy3jetsHTSFCentral_pos1->SetBinContent(10,1.788382); dy3jetsHTSFCentral_pos1->SetBinContent(11,1.610951); dy3jetsHTSFCentral_pos1->SetBinContent(12,0.7332956); dy3jetsHTSFCentral_pos1->SetBinContent(13,0.4350912); dy3jetsHTSFCentral_pos1->SetBinContent(14,0.3198399); dy3jetsHTSFCentral_pos1->SetBinContent(15,0.1697068); dy3jetsHTSFCentral_pos1->SetBinContent(16,0.1995292); dy3jetsHTSFCentral_pos1->SetBinContent(17,0.1819138); dy3jetsHTSFCentral_pos1->SetBinContent(18,0.1417081); dy3jetsHTSFCentral_pos1->SetBinContent(19,0.4112352); dy3jetsHTSFCentral_pos1->SetBinError(1,19.64866); dy3jetsHTSFCentral_pos1->SetBinError(2,17.05053); dy3jetsHTSFCentral_pos1->SetBinError(3,12.5145); dy3jetsHTSFCentral_pos1->SetBinError(4,8.514794); dy3jetsHTSFCentral_pos1->SetBinError(5,5.37795); dy3jetsHTSFCentral_pos1->SetBinError(6,3.183272); dy3jetsHTSFCentral_pos1->SetBinError(7,2.067061); dy3jetsHTSFCentral_pos1->SetBinError(8,0.8344492); dy3jetsHTSFCentral_pos1->SetBinError(9,0.5514864); dy3jetsHTSFCentral_pos1->SetBinError(10,0.2150106); dy3jetsHTSFCentral_pos1->SetBinError(11,0.3787172); dy3jetsHTSFCentral_pos1->SetBinError(12,0.2052038); dy3jetsHTSFCentral_pos1->SetBinError(13,0.07794151); dy3jetsHTSFCentral_pos1->SetBinError(14,0.06713208); dy3jetsHTSFCentral_pos1->SetBinError(15,0.04977684); dy3jetsHTSFCentral_pos1->SetBinError(16,0.05516024); dy3jetsHTSFCentral_pos1->SetBinError(17,0.0604995); dy3jetsHTSFCentral_pos1->SetBinError(18,0.04764779); dy3jetsHTSFCentral_pos1->SetBinError(19,0.08058546); dy3jetsHTSFCentral_pos1->SetEntries(14104.96); dy3jetsHTSFCentral_pos1->SetDirectory(0); dy3jetsHTSFCentral_pos1->SetStats(0); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#ff0000"); dy3jetsHTSFCentral_pos1->SetLineColor(ci); ci = TColor::GetColor("#ff0000"); dy3jetsHTSFCentral_pos1->SetMarkerColor(ci); dy3jetsHTSFCentral_pos1->SetMarkerStyle(20); dy3jetsHTSFCentral_pos1->GetXaxis()->SetTitle("JZB [GeV]"); dy3jetsHTSFCentral_pos1->GetXaxis()->SetRange(1,19); dy3jetsHTSFCentral_pos1->GetXaxis()->SetLabelFont(42); dy3jetsHTSFCentral_pos1->GetXaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_pos1->GetXaxis()->SetTitleSize(0.05); dy3jetsHTSFCentral_pos1->GetXaxis()->SetTitleFont(42); dy3jetsHTSFCentral_pos1->GetYaxis()->SetTitle("Events / 10 GeV"); dy3jetsHTSFCentral_pos1->GetYaxis()->SetLabelFont(42); dy3jetsHTSFCentral_pos1->GetYaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_pos1->GetYaxis()->SetTitleSize(0.05); dy3jetsHTSFCentral_pos1->GetYaxis()->SetTitleOffset(1.1); dy3jetsHTSFCentral_pos1->GetYaxis()->SetTitleFont(42); dy3jetsHTSFCentral_pos1->GetZaxis()->SetLabelFont(42); dy3jetsHTSFCentral_pos1->GetZaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_pos1->GetZaxis()->SetTitleSize(0.05); dy3jetsHTSFCentral_pos1->GetZaxis()->SetTitleFont(42); dy3jetsHTSFCentral_pos1->Draw("E,"); TH1F *dy3jetsHTSFCentral_neg2 = new TH1F("dy3jetsHTSFCentral_neg2","",19,0,190); dy3jetsHTSFCentral_neg2->SetBinContent(1,1354.164); dy3jetsHTSFCentral_neg2->SetBinContent(2,1046.151); dy3jetsHTSFCentral_neg2->SetBinContent(3,651.9274); dy3jetsHTSFCentral_neg2->SetBinContent(4,364.2787); dy3jetsHTSFCentral_neg2->SetBinContent(5,177.926); dy3jetsHTSFCentral_neg2->SetBinContent(6,86.23528); dy3jetsHTSFCentral_neg2->SetBinContent(7,41.15699); dy3jetsHTSFCentral_neg2->SetBinContent(8,21.64306); dy3jetsHTSFCentral_neg2->SetBinContent(9,12.30141); dy3jetsHTSFCentral_neg2->SetBinContent(10,6.154449); dy3jetsHTSFCentral_neg2->SetBinContent(11,4.562617); dy3jetsHTSFCentral_neg2->SetBinContent(12,2.791373); dy3jetsHTSFCentral_neg2->SetBinContent(13,1.353118); dy3jetsHTSFCentral_neg2->SetBinContent(14,0.9673754); dy3jetsHTSFCentral_neg2->SetBinContent(15,0.7570344); dy3jetsHTSFCentral_neg2->SetBinContent(16,0.5059175); dy3jetsHTSFCentral_neg2->SetBinContent(17,0.2268501); dy3jetsHTSFCentral_neg2->SetBinContent(18,0.1737406); dy3jetsHTSFCentral_neg2->SetBinContent(19,0.6773796); dy3jetsHTSFCentral_neg2->SetBinError(1,18.59017); dy3jetsHTSFCentral_neg2->SetBinError(2,15.88563); dy3jetsHTSFCentral_neg2->SetBinError(3,11.93105); dy3jetsHTSFCentral_neg2->SetBinError(4,8.412725); dy3jetsHTSFCentral_neg2->SetBinError(5,5.346843); dy3jetsHTSFCentral_neg2->SetBinError(6,3.410384); dy3jetsHTSFCentral_neg2->SetBinError(7,1.828263); dy3jetsHTSFCentral_neg2->SetBinError(8,1.35213); dy3jetsHTSFCentral_neg2->SetBinError(9,0.8761065); dy3jetsHTSFCentral_neg2->SetBinError(10,0.5915687); dy3jetsHTSFCentral_neg2->SetBinError(11,0.4991032); dy3jetsHTSFCentral_neg2->SetBinError(12,0.5155796); dy3jetsHTSFCentral_neg2->SetBinError(13,0.1509597); dy3jetsHTSFCentral_neg2->SetBinError(14,0.1333775); dy3jetsHTSFCentral_neg2->SetBinError(15,0.1216989); dy3jetsHTSFCentral_neg2->SetBinError(16,0.09722033); dy3jetsHTSFCentral_neg2->SetBinError(17,0.06062957); dy3jetsHTSFCentral_neg2->SetBinError(18,0.05201017); dy3jetsHTSFCentral_neg2->SetBinError(19,0.09818302); dy3jetsHTSFCentral_neg2->SetEntries(16596.53); dy3jetsHTSFCentral_neg2->SetDirectory(0); dy3jetsHTSFCentral_neg2->SetStats(0); ci = TColor::GetColor("#0000ff"); dy3jetsHTSFCentral_neg2->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); dy3jetsHTSFCentral_neg2->SetMarkerColor(ci); dy3jetsHTSFCentral_neg2->SetMarkerStyle(20); dy3jetsHTSFCentral_neg2->GetXaxis()->SetTitle("JZB [GeV]"); dy3jetsHTSFCentral_neg2->GetXaxis()->SetRange(1,19); dy3jetsHTSFCentral_neg2->GetXaxis()->SetLabelFont(42); dy3jetsHTSFCentral_neg2->GetXaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_neg2->GetXaxis()->SetTitleSize(0.05); dy3jetsHTSFCentral_neg2->GetXaxis()->SetTitleFont(42); dy3jetsHTSFCentral_neg2->GetYaxis()->SetTitle("Events / 10 GeV"); dy3jetsHTSFCentral_neg2->GetYaxis()->SetLabelFont(42); dy3jetsHTSFCentral_neg2->GetYaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_neg2->GetYaxis()->SetTitleSize(0.05); dy3jetsHTSFCentral_neg2->GetYaxis()->SetTitleOffset(1.1); dy3jetsHTSFCentral_neg2->GetYaxis()->SetTitleFont(42); dy3jetsHTSFCentral_neg2->GetZaxis()->SetLabelFont(42); dy3jetsHTSFCentral_neg2->GetZaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_neg2->GetZaxis()->SetTitleSize(0.05); dy3jetsHTSFCentral_neg2->GetZaxis()->SetTitleFont(42); dy3jetsHTSFCentral_neg2->Draw("HIST,SAME"); TLegend *leg = new TLegend(0.65,0.5,0.9,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("dy3jetsHTSFCentral_pos","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("dy3jetsHTSFCentral_neg","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(); finalPlots/closure_3jets_HT_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 *dy3jetsHTSFCentral_neg_ratio3 = new TH1F("dy3jetsHTSFCentral_neg_ratio3","",19,0,190); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(1,1.038418); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(2,1.016125); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(3,0.9785615); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(4,0.8672913); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(5,0.7800011); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(6,0.6619936); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(7,0.6032351); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(8,0.3553971); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(9,0.3283455); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(10,0.2905836); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(11,0.3530762); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(12,0.2627006); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(13,0.3215471); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(14,0.3306265); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(15,0.2241731); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(16,0.3943908); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(17,0.801912); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(18,0.8156302); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(19,0.607097); dy3jetsHTSFCentral_neg_ratio3->SetBinError(1,0.02034098); dy3jetsHTSFCentral_neg_ratio3->SetBinError(2,0.02244352); dy3jetsHTSFCentral_neg_ratio3->SetBinError(3,0.02625298); dy3jetsHTSFCentral_neg_ratio3->SetBinError(4,0.03078213); dy3jetsHTSFCentral_neg_ratio3->SetBinError(5,0.03824944); dy3jetsHTSFCentral_neg_ratio3->SetBinError(6,0.04525515); dy3jetsHTSFCentral_neg_ratio3->SetBinError(7,0.05692536); dy3jetsHTSFCentral_neg_ratio3->SetBinError(8,0.04449123); dy3jetsHTSFCentral_neg_ratio3->SetBinError(9,0.05056361); dy3jetsHTSFCentral_neg_ratio3->SetBinError(10,0.04472866); dy3jetsHTSFCentral_neg_ratio3->SetBinError(11,0.09155029); dy3jetsHTSFCentral_neg_ratio3->SetBinError(12,0.0880831); dy3jetsHTSFCentral_neg_ratio3->SetBinError(13,0.06785872); dy3jetsHTSFCentral_neg_ratio3->SetBinError(14,0.08302917); dy3jetsHTSFCentral_neg_ratio3->SetBinError(15,0.07498054); dy3jetsHTSFCentral_neg_ratio3->SetBinError(16,0.1327836); dy3jetsHTSFCentral_neg_ratio3->SetBinError(17,0.3421413); dy3jetsHTSFCentral_neg_ratio3->SetBinError(18,0.3671879); dy3jetsHTSFCentral_neg_ratio3->SetBinError(19,0.147974); dy3jetsHTSFCentral_neg_ratio3->SetMinimum(0); dy3jetsHTSFCentral_neg_ratio3->SetMaximum(2); dy3jetsHTSFCentral_neg_ratio3->SetEntries(357.3526); dy3jetsHTSFCentral_neg_ratio3->SetStats(0); ci = TColor::GetColor("#0000ff"); dy3jetsHTSFCentral_neg_ratio3->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); dy3jetsHTSFCentral_neg_ratio3->SetMarkerColor(ci); dy3jetsHTSFCentral_neg_ratio3->SetMarkerStyle(20); dy3jetsHTSFCentral_neg_ratio3->GetXaxis()->SetRange(1,19); dy3jetsHTSFCentral_neg_ratio3->GetXaxis()->SetLabelFont(42); dy3jetsHTSFCentral_neg_ratio3->GetXaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_neg_ratio3->GetXaxis()->SetLabelSize(0.12); dy3jetsHTSFCentral_neg_ratio3->GetXaxis()->SetTitleSize(0.14); dy3jetsHTSFCentral_neg_ratio3->GetXaxis()->SetTitleFont(42); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetTitle("Ratio"); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->CenterTitle(true); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetNdivisions(4); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetLabelFont(42); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetLabelSize(0.12); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetTitleSize(0.14); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetTitleOffset(0.3); dy3jetsHTSFCentral_neg_ratio3->GetYaxis()->SetTitleFont(42); dy3jetsHTSFCentral_neg_ratio3->GetZaxis()->SetLabelFont(42); dy3jetsHTSFCentral_neg_ratio3->GetZaxis()->SetLabelOffset(0.007); dy3jetsHTSFCentral_neg_ratio3->GetZaxis()->SetTitleSize(0.05); dy3jetsHTSFCentral_neg_ratio3->GetZaxis()->SetTitleFont(42); dy3jetsHTSFCentral_neg_ratio3->Draw("l, "); TLine *line = new TLine(0,1,190,1); ci = TColor::GetColor("#666666"); line->SetLineColor(ci); line->Draw(); Double_t Graph0_fx1[4] = { 0, 400, 400, 0}; Double_t Graph0_fy1[4] = { 0.7, 0.7, 1.3, 1.3}; TGraph *graph = new TGraph(4,Graph0_fx1,Graph0_fy1); graph->SetName("Graph0"); graph->SetTitle("Graph"); ci = 1179; color = new TColor(ci, 1, 0, 0, " ", 0.4); graph->SetFillColor(ci); graph->SetMarkerStyle(20); TH1F *Graph_Graph1 = new TH1F("Graph_Graph1","Graph",100,0,440); Graph_Graph1->SetMinimum(0.64); Graph_Graph1->SetMaximum(1.36); Graph_Graph1->SetDirectory(0); Graph_Graph1->SetStats(0); Graph_Graph1->SetMarkerStyle(20); Graph_Graph1->GetXaxis()->SetLabelFont(42); Graph_Graph1->GetXaxis()->SetLabelOffset(0.007); Graph_Graph1->GetXaxis()->SetTitleSize(0.05); Graph_Graph1->GetXaxis()->SetTitleFont(42); Graph_Graph1->GetYaxis()->SetLabelFont(42); Graph_Graph1->GetYaxis()->SetLabelOffset(0.007); Graph_Graph1->GetYaxis()->SetTitleSize(0.05); Graph_Graph1->GetYaxis()->SetTitleOffset(1.1); Graph_Graph1->GetYaxis()->SetTitleFont(42); Graph_Graph1->GetZaxis()->SetLabelFont(42); Graph_Graph1->GetZaxis()->SetLabelOffset(0.007); Graph_Graph1->GetZaxis()->SetTitleSize(0.05); Graph_Graph1->GetZaxis()->SetTitleFont(42); graph->SetHistogram(Graph_Graph1); graph->Draw("f"); pad2->Modified(); finalPlots/closure_3jets_HT_Central->cd(); finalPlots/closure_3jets_HT_Central->Modified(); finalPlots/closure_3jets_HT_Central->cd(); finalPlots/closure_3jets_HT_Central->SetSelected(finalPlots/closure_3jets_HT_Central); }