void sigmm() { //=========Macro generated from canvas: stopStuff/sigmm/stopStuff/sigmm //========= (Fri Sep 30 12:20:07 2016) by ROOT version6.06/01 TCanvas *stopStuff/sigmm = new TCanvas("stopStuff/sigmm", "stopStuff/sigmm",0,0,700,500); stopStuff/sigmm->SetHighLightColor(2); stopStuff/sigmm->Range(-40,-1.739219,360,-0.114745); stopStuff/sigmm->SetFillColor(0); stopStuff/sigmm->SetBorderMode(0); stopStuff/sigmm->SetBorderSize(2); stopStuff/sigmm->SetLogy(); stopStuff/sigmm->SetRightMargin(0.05); stopStuff/sigmm->SetFrameBorderMode(0); stopStuff/sigmm->SetFrameBorderMode(0); Double_t xAxis3[9] = {0, 20, 40, 60, 80, 100, 140, 240, 340}; TH1F *stack_mm_treeHisto__3 = new TH1F("stack_mm_treeHisto__3","SMS-T2tt_mStop-150to250",8, xAxis3); stack_mm_treeHisto__3->SetBinContent(1,0.2148803); stack_mm_treeHisto__3->SetBinContent(2,0.05299791); stack_mm_treeHisto__3->SetBinContent(3,0.06236311); stack_mm_treeHisto__3->SetBinContent(4,0.08213943); stack_mm_treeHisto__3->SetBinContent(5,0.08980103); stack_mm_treeHisto__3->SetBinContent(6,0.1545429); stack_mm_treeHisto__3->SetBinContent(7,0.2787782); stack_mm_treeHisto__3->SetBinContent(8,0.06449718); stack_mm_treeHisto__3->SetBinError(1,0.04772046); stack_mm_treeHisto__3->SetBinError(2,0.02059692); stack_mm_treeHisto__3->SetBinError(3,0.02660169); stack_mm_treeHisto__3->SetBinError(4,0.02847398); stack_mm_treeHisto__3->SetBinError(5,0.03029244); stack_mm_treeHisto__3->SetBinError(6,0.03912728); stack_mm_treeHisto__3->SetBinError(7,0.05404971); stack_mm_treeHisto__3->SetBinError(8,0.02373073); stack_mm_treeHisto__3->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_mm_treeHisto"); AText->SetTextSize(0.0368); AText = ptstats->AddText("Entries = 8 "); AText = ptstats->AddText("Mean = 110.9"); AText = ptstats->AddText("Std Dev = 82.27"); ptstats->SetOptStat(1111); ptstats->SetOptFit(0); ptstats->Draw(); stack_mm_treeHisto__3->GetListOfFunctions()->Add(ptstats); ptstats->SetParent(stack_mm_treeHisto__3); Int_t ci; // for color index setting TColor *color; // for color definition with alpha ci = TColor::GetColor("#0000ff"); stack_mm_treeHisto__3->SetLineColor(ci); ci = TColor::GetColor("#0000ff"); stack_mm_treeHisto__3->SetMarkerColor(ci); stack_mm_treeHisto__3->GetXaxis()->SetTitle("m_{T2} [GeV]"); stack_mm_treeHisto__3->GetXaxis()->SetLabelFont(42); stack_mm_treeHisto__3->GetXaxis()->SetLabelSize(0.035); stack_mm_treeHisto__3->GetXaxis()->SetTitleSize(0.035); stack_mm_treeHisto__3->GetXaxis()->SetTitleFont(42); stack_mm_treeHisto__3->GetYaxis()->SetTitle("# events"); stack_mm_treeHisto__3->GetYaxis()->SetLabelFont(42); stack_mm_treeHisto__3->GetYaxis()->SetLabelSize(0.035); stack_mm_treeHisto__3->GetYaxis()->SetTitleSize(0.035); stack_mm_treeHisto__3->GetYaxis()->SetTitleFont(42); stack_mm_treeHisto__3->GetZaxis()->SetLabelFont(42); stack_mm_treeHisto__3->GetZaxis()->SetLabelSize(0.035); stack_mm_treeHisto__3->GetZaxis()->SetTitleSize(0.035); stack_mm_treeHisto__3->GetZaxis()->SetTitleFont(42); stack_mm_treeHisto__3->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/sigmm->Modified(); stopStuff/sigmm->cd(); stopStuff/sigmm->SetSelected(stopStuff/sigmm); }