void sigOF() { //=========Macro generated from canvas: stopStuff/sigOF/stopStuff/sigOF //========= (Fri Sep 30 12:20:02 2016) by ROOT version6.06/01 TCanvas *stopStuff/sigOF = new TCanvas("stopStuff/sigOF", "stopStuff/sigOF",0,0,700,500); stopStuff/sigOF->SetHighLightColor(2); stopStuff/sigOF->Range(-42.5,-1.773237,382.5,-0.05483631); stopStuff/sigOF->SetFillColor(0); stopStuff/sigOF->SetBorderMode(0); stopStuff/sigOF->SetBorderSize(2); stopStuff/sigOF->SetLogy(); stopStuff/sigOF->SetFrameBorderMode(0); stopStuff/sigOF->SetFrameBorderMode(0); Double_t xAxis1[9] = {0, 20, 40, 60, 80, 100, 140, 240, 340}; TH1F *stack_OF_treeHisto__1 = new TH1F("stack_OF_treeHisto__1","SMS-T2tt_mStop-150to250",8, xAxis1); stack_OF_treeHisto__1->SetBinContent(1,0.1933099); stack_OF_treeHisto__1->SetBinContent(2,0.05871345); stack_OF_treeHisto__1->SetBinContent(3,0.06465466); stack_OF_treeHisto__1->SetBinContent(4,0.05007645); stack_OF_treeHisto__1->SetBinContent(5,0.06005717); stack_OF_treeHisto__1->SetBinContent(6,0.1919445); stack_OF_treeHisto__1->SetBinContent(7,0.3131661); stack_OF_treeHisto__1->SetBinContent(8,0.06807783); stack_OF_treeHisto__1->SetBinError(1,0.03152897); stack_OF_treeHisto__1->SetBinError(2,0.01830849); stack_OF_treeHisto__1->SetBinError(3,0.0193496); stack_OF_treeHisto__1->SetBinError(4,0.01574641); stack_OF_treeHisto__1->SetBinError(5,0.01865274); stack_OF_treeHisto__1->SetBinError(6,0.03215299); stack_OF_treeHisto__1->SetBinError(7,0.04045595); stack_OF_treeHisto__1->SetBinError(8,0.01877303); stack_OF_treeHisto__1->SetEntries(8); TPaveStats *ptstats = new TPaveStats(0.78,0.775,0.98,0.935,"brNDC"); ptstats->SetName("stats"); ptstats->SetBorderSize(1); ptstats->SetFillColor(0); ptstats->SetTextAlign(12); ptstats->SetTextFont(42); TText *AText = ptstats->AddText("stack_OF_treeHisto"); AText->SetTextSize(0.0368); AText = ptstats->AddText("Entries = 8 "); AText = ptstats->AddText("Mean = 118.1"); AText = ptstats->AddText("Std Dev = 82.52"); ptstats->SetOptStat(1111); ptstats->SetOptFit(0); ptstats->Draw(); stack_OF_treeHisto__1->GetListOfFunctions()->Add(ptstats); ptstats->SetParent(stack_OF_treeHisto__1); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#0000ff"); stack_OF_treeHisto__1->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); stack_OF_treeHisto__1->SetMarkerColor(ci); stack_OF_treeHisto__1->GetXaxis()->SetTitle("m_{T2} [GeV]"); stack_OF_treeHisto__1->GetXaxis()->SetLabelFont(42); stack_OF_treeHisto__1->GetXaxis()->SetLabelSize(0.035); stack_OF_treeHisto__1->GetXaxis()->SetTitleSize(0.035); stack_OF_treeHisto__1->GetXaxis()->SetTitleFont(42); stack_OF_treeHisto__1->GetYaxis()->SetTitle("# events"); stack_OF_treeHisto__1->GetYaxis()->SetLabelFont(42); stack_OF_treeHisto__1->GetYaxis()->SetLabelSize(0.035); stack_OF_treeHisto__1->GetYaxis()->SetTitleSize(0.035); stack_OF_treeHisto__1->GetYaxis()->SetTitleFont(42); stack_OF_treeHisto__1->GetZaxis()->SetLabelFont(42); stack_OF_treeHisto__1->GetZaxis()->SetLabelSize(0.035); stack_OF_treeHisto__1->GetZaxis()->SetTitleSize(0.035); stack_OF_treeHisto__1->GetZaxis()->SetTitleFont(42); stack_OF_treeHisto__1->Draw("HIST"); TLegend *leg = new TLegend(0.6,0.6,0.8,0.8,NULL,"brNDC"); leg->SetBorderSize(0); leg->SetTextSize(0.04); leg->SetLineColor(1); leg->SetLineStyle(1); leg->SetLineWidth(0); leg->SetFillColor(0); leg->SetFillStyle(1001); leg->Draw(); tex = new TLatex(0.21,0.93,"CMS"); tex->SetNDC(); tex->SetTextAlign(31); tex->SetTextFont(61); tex->SetTextSize(0.04); tex->SetLineWidth(2); tex->Draw(); tex = new TLatex(0.37,0.93,"Simulation"); tex->SetNDC(); tex->SetTextAlign(31); tex->SetTextFont(52); tex->SetTextSize(0.03); tex->SetLineWidth(2); tex->Draw(); tex = new TLatex(0.9,0.93,"12.9 fb^{-1} (13 TeV)"); tex->SetNDC(); tex->SetTextAlign(31); tex->SetTextFont(42); tex->SetTextSize(0.04); tex->SetLineWidth(2); tex->Draw(); TPaveText *pt = new TPaveText(0.273046,0.9339831,0.726954,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(0); pt->SetFillColor(0); pt->SetFillStyle(0); pt->SetTextFont(42); AText = pt->AddText("SMS-T2tt_mStop-150to250"); pt->Draw(); stopStuff/sigOF->Modified(); stopStuff/sigOF->cd(); stopStuff/sigOF->SetSelected(stopStuff/sigOF); }