{ //=========Macro generated from canvas: c1/c1 //========= (Thu May 31 16:21:01 2012) by ROOT version5.32/03 TCanvas *c1 = new TCanvas("c1", "c1",66,52,700,500); gStyle->SetOptTitle(0); c1->Range(-7.135135,-1.057633,37.45946,5.552571); c1->SetFillColor(0); c1->SetBorderMode(0); c1->SetBorderSize(2); c1->SetLogy(); c1->SetTickx(1); c1->SetTicky(1); c1->SetLeftMargin(0.16); c1->SetTopMargin(0.05); c1->SetBottomMargin(0.16); c1->SetFrameBorderMode(0); c1->SetFrameBorderMode(0); TH1D *entriesPerChannel__1 = new TH1D("entriesPerChannel__1","Entries per channel",1000,0,1000); entriesPerChannel__1->SetBinContent(1,88006); entriesPerChannel__1->SetBinContent(2,1498); entriesPerChannel__1->SetBinContent(3,1859); entriesPerChannel__1->SetBinContent(4,2156); entriesPerChannel__1->SetBinContent(5,2597); entriesPerChannel__1->SetBinContent(6,2879); entriesPerChannel__1->SetBinContent(7,3471); entriesPerChannel__1->SetBinContent(8,4047); entriesPerChannel__1->SetBinContent(9,4220); entriesPerChannel__1->SetBinContent(10,4269); entriesPerChannel__1->SetBinContent(11,4073); entriesPerChannel__1->SetBinContent(12,3639); entriesPerChannel__1->SetBinContent(13,3016); entriesPerChannel__1->SetBinContent(14,2240); entriesPerChannel__1->SetBinContent(15,1728); entriesPerChannel__1->SetBinContent(16,1219); entriesPerChannel__1->SetBinContent(17,771); entriesPerChannel__1->SetBinContent(18,535); entriesPerChannel__1->SetBinContent(19,279); entriesPerChannel__1->SetBinContent(20,170); entriesPerChannel__1->SetBinContent(21,91); entriesPerChannel__1->SetBinContent(22,58); entriesPerChannel__1->SetBinContent(23,19); entriesPerChannel__1->SetBinContent(24,11); entriesPerChannel__1->SetBinContent(25,5); entriesPerChannel__1->SetBinContent(26,6); entriesPerChannel__1->SetBinContent(27,2); entriesPerChannel__1->SetEntries(132864); entriesPerChannel__1->SetDirectory(0); TPaveStats *ptstats = new TPaveStats(0.78,0.875,0.98,0.995,"brNDC"); ptstats->SetName("stats"); ptstats->SetBorderSize(1); ptstats->SetFillColor(0); ptstats->SetFillStyle(1); ptstats->SetTextAlign(12); TText *text = ptstats->AddText("Entries = 132864 "); text = ptstats->AddText("Mean = 3.361"); text = ptstats->AddText("RMS = 4.636"); ptstats->SetOptStat(1110); ptstats->SetOptFit(0); ptstats->Draw(); entriesPerChannel__1->GetListOfFunctions()->Add(ptstats); ptstats->SetParent(entriesPerChannel__1); Int_t ci; // for color index setting ci = TColor::GetColor("#0000ff"); entriesPerChannel__1->SetLineColor(ci); entriesPerChannel__1->SetLineWidth(2); ci = TColor::GetColor("#0000ff"); entriesPerChannel__1->SetMarkerColor(ci); entriesPerChannel__1->SetMarkerStyle(20); entriesPerChannel__1->SetMarkerSize(1.2); entriesPerChannel__1->GetXaxis()->SetTitle("Entries/channel"); entriesPerChannel__1->GetXaxis()->SetRange(1,33); entriesPerChannel__1->GetXaxis()->SetLabelFont(42); entriesPerChannel__1->GetXaxis()->SetLabelSize(0.05); entriesPerChannel__1->GetXaxis()->SetTitleSize(0.05); entriesPerChannel__1->GetXaxis()->SetTitleFont(42); entriesPerChannel__1->GetYaxis()->SetTitle("#"); entriesPerChannel__1->GetYaxis()->SetLabelFont(42); entriesPerChannel__1->GetYaxis()->SetLabelSize(0.05); entriesPerChannel__1->GetYaxis()->SetTitleSize(0.05); entriesPerChannel__1->GetYaxis()->SetTitleFont(42); entriesPerChannel__1->GetZaxis()->SetLabelFont(42); entriesPerChannel__1->GetZaxis()->SetLabelSize(0.05); entriesPerChannel__1->GetZaxis()->SetTitleSize(0.05); entriesPerChannel__1->GetZaxis()->SetTitleFont(42); entriesPerChannel__1->Draw(""); c1->Modified(); c1->cd(); c1->SetSelected(c1); }