{ //=========Macro generated from canvas: c1/c1 //========= (Mon Aug 8 13:41:14 2011) by ROOT version5.18/00b TCanvas *c1 = new TCanvas("c1", "c1",728,96,699,499); gStyle->SetOptFit(1); c1->SetHighLightColor(2); c1->Range(-11.18107,-11.24333,101.9791,99.50347); c1->SetBorderSize(2); c1->SetFrameFillColor(0); TGraph *graph = new TGraph(9); graph->SetName("Graph"); graph->SetTitle("Faraday Cup vs OLO2 (BcmLog_171)"); graph->SetFillColor(1); graph->SetMarkerColor(4); graph->SetMarkerStyle(22); graph->SetPoint(0,82.3866,80.5098); graph->SetPoint(1,49.7802,48.8722); graph->SetPoint(2,20.2328,19.8737); graph->SetPoint(3,10.0197,9.8323); graph->SetPoint(4,5.1693,5.0577); graph->SetPoint(5,2.0174,1.9803); graph->SetPoint(6,0.9954,0.9782); graph->SetPoint(7,0.4842,0.4731); graph->SetPoint(8,0.2004,0.1956); TH1 *Graph1 = new TH1F("Graph1","Faraday Cup vs OLO2 (BcmLog_171)",100,0,90.60522); Graph1->SetMinimum(0); Graph1->SetMaximum(88.54122); Graph1->SetDirectory(0); Graph1->SetStats(0); Graph1->GetXaxis()->SetTitle("OLO2 current (#muA)"); Graph1->GetYaxis()->SetTitle("Faraday Cup current (#muA)"); graph->SetHistogram(Graph1); TPaveStats *ptstats = new TPaveStats(0.5996593,0.213198,0.9608177,0.3756345,"brNDC"); ptstats->SetName("stats"); ptstats->SetBorderSize(2); ptstats->SetFillColor(19); ptstats->SetTextAlign(12); TText *text = ptstats->AddText("#chi^{2} / ndf = 0.04026 / 7"); text = ptstats->AddText("p0 = 0.02468 #pm 0.03342 "); text = ptstats->AddText("p1 = 0.9782 #pm 0.001012 "); ptstats->SetOptStat(0); ptstats->SetOptFit(111); ptstats->Draw(); graph->GetListOfFunctions()->Add(ptstats); ptstats->SetParent(graph->GetListOfFunctions()); TF1 *pol1 = new TF1("pol1","pol1",0.2004,82.3866); pol1->SetFillColor(19); pol1->SetFillStyle(0); pol1->SetLineWidth(3); pol1->SetChisquare(0.04025504); pol1->SetParameter(0,0.02467829); pol1->SetParError(0,0.03341575); pol1->SetParLimits(0,0,0); pol1->SetParameter(1,0.9781932); pol1->SetParError(1,0.001012266); pol1->SetParLimits(1,0,0); graph->GetListOfFunctions()->Add(pol1); graph->Draw("ap"); TPaveText *pt = new TPaveText(0.01,0.9401777,0.5700341,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(2); pt->SetFillColor(19); text = pt->AddText("Faraday Cup vs OLO2 (BcmLog_171)"); pt->Draw(); c1->Modified(); c1->cd(); c1->SetSelected(c1); }