void closure_3jets_HT_Central() { //=========Macro generated from canvas: finalPlots/closure_3jets_HT_Central/finalPlots/closure_3jets_HT_Central //========= (Fri May 20 12:38:32 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->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.895295,201.5854,3.893025); 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,1401.077); dy3jetsHTSFCentral_pos1->SetBinContent(2,1073.347); dy3jetsHTSFCentral_pos1->SetBinContent(3,639.5182); dy3jetsHTSFCentral_pos1->SetBinContent(4,316.8337); dy3jetsHTSFCentral_pos1->SetBinContent(5,143.1976); dy3jetsHTSFCentral_pos1->SetBinContent(6,57.4928); dy3jetsHTSFCentral_pos1->SetBinContent(7,25.51954); dy3jetsHTSFCentral_pos1->SetBinContent(8,7.709143); dy3jetsHTSFCentral_pos1->SetBinContent(9,4.128893); dy3jetsHTSFCentral_pos1->SetBinContent(10,1.794317); dy3jetsHTSFCentral_pos1->SetBinContent(11,1.56726); dy3jetsHTSFCentral_pos1->SetBinContent(12,0.7607921); dy3jetsHTSFCentral_pos1->SetBinContent(13,0.4416354); dy3jetsHTSFCentral_pos1->SetBinContent(14,0.3219277); dy3jetsHTSFCentral_pos1->SetBinContent(15,0.1528817); dy3jetsHTSFCentral_pos1->SetBinContent(16,0.2164912); dy3jetsHTSFCentral_pos1->SetBinContent(17,0.1793996); dy3jetsHTSFCentral_pos1->SetBinContent(18,0.1442229); dy3jetsHTSFCentral_pos1->SetBinContent(19,0.4112352); dy3jetsHTSFCentral_pos1->SetBinError(1,19.32217); dy3jetsHTSFCentral_pos1->SetBinError(2,17.13573); dy3jetsHTSFCentral_pos1->SetBinError(3,12.49269); dy3jetsHTSFCentral_pos1->SetBinError(4,8.517781); dy3jetsHTSFCentral_pos1->SetBinError(5,5.45556); dy3jetsHTSFCentral_pos1->SetBinError(6,3.183355); dy3jetsHTSFCentral_pos1->SetBinError(7,2.08068); dy3jetsHTSFCentral_pos1->SetBinError(8,0.8323941); dy3jetsHTSFCentral_pos1->SetBinError(9,0.5536631); dy3jetsHTSFCentral_pos1->SetBinError(10,0.2151811); dy3jetsHTSFCentral_pos1->SetBinError(11,0.3777074); dy3jetsHTSFCentral_pos1->SetBinError(12,0.2061146); dy3jetsHTSFCentral_pos1->SetBinError(13,0.07814934); dy3jetsHTSFCentral_pos1->SetBinError(14,0.06714874); dy3jetsHTSFCentral_pos1->SetBinError(15,0.04682798); dy3jetsHTSFCentral_pos1->SetBinError(16,0.05768487); dy3jetsHTSFCentral_pos1->SetBinError(17,0.06044721); dy3jetsHTSFCentral_pos1->SetBinError(18,0.04771411); dy3jetsHTSFCentral_pos1->SetBinError(19,0.08058546); dy3jetsHTSFCentral_pos1->SetEntries(14349.67); 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.664); dy3jetsHTSFCentral_neg2->SetBinContent(2,1044.025); dy3jetsHTSFCentral_neg2->SetBinContent(3,648.2596); dy3jetsHTSFCentral_neg2->SetBinContent(4,359.5484); dy3jetsHTSFCentral_neg2->SetBinContent(5,176.3345); dy3jetsHTSFCentral_neg2->SetBinContent(6,85.46211); dy3jetsHTSFCentral_neg2->SetBinContent(7,40.85665); dy3jetsHTSFCentral_neg2->SetBinContent(8,21.33043); dy3jetsHTSFCentral_neg2->SetBinContent(9,12.53574); dy3jetsHTSFCentral_neg2->SetBinContent(10,5.684819); dy3jetsHTSFCentral_neg2->SetBinContent(11,4.553064); dy3jetsHTSFCentral_neg2->SetBinContent(12,2.773767); dy3jetsHTSFCentral_neg2->SetBinContent(13,1.334284); dy3jetsHTSFCentral_neg2->SetBinContent(14,0.9708556); dy3jetsHTSFCentral_neg2->SetBinContent(15,0.7677313); dy3jetsHTSFCentral_neg2->SetBinContent(16,0.4524805); dy3jetsHTSFCentral_neg2->SetBinContent(17,0.2463744); dy3jetsHTSFCentral_neg2->SetBinContent(18,0.1926894); dy3jetsHTSFCentral_neg2->SetBinContent(19,0.658354); dy3jetsHTSFCentral_neg2->SetBinError(1,18.88562); dy3jetsHTSFCentral_neg2->SetBinError(2,15.8921); dy3jetsHTSFCentral_neg2->SetBinError(3,11.91511); dy3jetsHTSFCentral_neg2->SetBinError(4,8.354882); dy3jetsHTSFCentral_neg2->SetBinError(5,5.303043); dy3jetsHTSFCentral_neg2->SetBinError(6,3.413539); dy3jetsHTSFCentral_neg2->SetBinError(7,1.837102); dy3jetsHTSFCentral_neg2->SetBinError(8,1.314687); dy3jetsHTSFCentral_neg2->SetBinError(9,0.9412263); dy3jetsHTSFCentral_neg2->SetBinError(10,0.4749779); dy3jetsHTSFCentral_neg2->SetBinError(11,0.4993686); dy3jetsHTSFCentral_neg2->SetBinError(12,0.5151722); dy3jetsHTSFCentral_neg2->SetBinError(13,0.150394); dy3jetsHTSFCentral_neg2->SetBinError(14,0.1338264); dy3jetsHTSFCentral_neg2->SetBinError(15,0.1221439); dy3jetsHTSFCentral_neg2->SetBinError(16,0.09284567); dy3jetsHTSFCentral_neg2->SetBinError(17,0.06371429); dy3jetsHTSFCentral_neg2->SetBinError(18,0.05405242); dy3jetsHTSFCentral_neg2->SetBinError(19,0.09707365); dy3jetsHTSFCentral_neg2->SetEntries(16301.01); 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.034262); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(2,1.028086); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(3,0.9865156); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(4,0.881199); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(5,0.8120791); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(6,0.6727285); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(7,0.6246117); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(8,0.3614154); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(9,0.3293697); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(10,0.3156332); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(11,0.344221); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(12,0.2742812); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(13,0.3309905); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(14,0.3315918); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(15,0.1991344); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(16,0.4784543); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(17,0.7281584); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(18,0.7484733); dy3jetsHTSFCentral_neg_ratio3->SetBinContent(19,0.6246414); dy3jetsHTSFCentral_neg_ratio3->SetBinError(1,0.02028173); dy3jetsHTSFCentral_neg_ratio3->SetBinError(2,0.02267811); dy3jetsHTSFCentral_neg_ratio3->SetBinError(3,0.02646048); dy3jetsHTSFCentral_neg_ratio3->SetBinError(4,0.03131319); dy3jetsHTSFCentral_neg_ratio3->SetBinError(5,0.03941638); dy3jetsHTSFCentral_neg_ratio3->SetBinError(6,0.04592903); dy3jetsHTSFCentral_neg_ratio3->SetBinError(7,0.05815739); dy3jetsHTSFCentral_neg_ratio3->SetBinError(8,0.04493394); dy3jetsHTSFCentral_neg_ratio3->SetBinError(9,0.05061902); dy3jetsHTSFCentral_neg_ratio3->SetBinError(10,0.0461328); dy3jetsHTSFCentral_neg_ratio3->SetBinError(11,0.09114347); dy3jetsHTSFCentral_neg_ratio3->SetBinError(12,0.09009373); dy3jetsHTSFCentral_neg_ratio3->SetBinError(13,0.06944301); dy3jetsHTSFCentral_neg_ratio3->SetBinError(14,0.08290317); dy3jetsHTSFCentral_neg_ratio3->SetBinError(15,0.06873249); dy3jetsHTSFCentral_neg_ratio3->SetBinError(16,0.1609069); dy3jetsHTSFCentral_neg_ratio3->SetBinError(17,0.3092811); dy3jetsHTSFCentral_neg_ratio3->SetBinError(18,0.3246524); dy3jetsHTSFCentral_neg_ratio3->SetBinError(19,0.1531854); dy3jetsHTSFCentral_neg_ratio3->SetMinimum(0); dy3jetsHTSFCentral_neg_ratio3->SetMaximum(2); dy3jetsHTSFCentral_neg_ratio3->SetEntries(411.6603); 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); }