{ //=========Macro generated from canvas: canv2/canv2 //========= (Mon Sep 20 19:47:02 2004) by ROOT version4.00/08 TCanvas *canv2 = new TCanvas("canv2", "canv2",16,35,700,500); canv2->Range(0,0,1,1); canv2->SetBorderSize(2); canv2->SetGridx(); canv2->SetGridy(); canv2->SetFrameFillColor(0); TGraphErrors *gre = new TGraphErrors(4); gre->SetName("Graph"); gre->SetTitle("Led Characteristic curve. Brd=3 Ch=2"); gre->SetFillColor(1); gre->SetMarkerColor(4); gre->SetMarkerStyle(8); gre->SetMarkerSize(0.5); gre->SetPoint(0,1,1.56); gre->SetPointError(0,0,0.2); gre->SetPoint(1,2,2.03); gre->SetPointError(1,0,0.3); gre->SetPoint(2,3,2.89); gre->SetPointError(2,0,0.4); gre->SetPoint(3,4,3.15); gre->SetPointError(3,0,0.5); TH1 *Graph1 = new TH1F("Graph1","Led Characteristic curve. Brd=3 Ch=2",100,0.7,4.3); Graph1->SetMinimum(1.131); Graph1->SetMaximum(3.879); Graph1->SetDirectory(0); Graph1->SetStats(0); Graph1->GetXaxis()->SetTitle("DAC"); Graph1->GetYaxis()->SetTitle("pe"); gre->SetHistogram(Graph1); gre->Draw("ap"); TPaveText *pt = new TPaveText(7.38054e-316,0,9.07723e-266,7.38054e-316,"brNDC"); pt->SetFillColor(19); TText *text = pt->AddText("run = 3"); text = pt->AddText("time = 34.500"); text = pt->AddText("single_pe_dac = 15"); text = pt->AddText("single_pe = 0.23"); text = pt->AddText("single_pe_eff = 34.00 %"); text->SetTextColor(2); text = pt->AddText("max_pe = 79.00"); text->SetTextColor(2); pt->Draw(); canv2->Modified(); canv2->cd(); canv2->SetSelected(canv2); }