{ //=========Macro generated from canvas: c1/c1 //========= (Mon Aug 8 13:57:57 2011) by ROOT version5.18/00b TCanvas *c1 = new TCanvas("c1", "c1",710,143,699,499); gStyle->SetOptFit(1); c1->SetHighLightColor(2); c1->Range(-0.1335958,-11.29015,1.218486,99.91786); c1->SetBorderSize(2); c1->SetFrameFillColor(0); TGraph *graph = new TGraph(9); graph->SetName("Graph"); graph->SetTitle("OLO2 vs BCM2 (BcmLog_173)"); graph->SetFillColor(1); graph->SetMarkerColor(4); graph->SetMarkerStyle(22); graph->SetPoint(0,0.984394,80.8457); graph->SetPoint(1,0.605525,49.5059); graph->SetPoint(2,0.248944,20.4318); graph->SetPoint(3,0.123784,10.1662); graph->SetPoint(4,0.062992,5.1687); graph->SetPoint(5,0.024862,2.0459); graph->SetPoint(6,0.012121,0.9956); graph->SetPoint(7,0.005802,0.4839); graph->SetPoint(8,0.002467,0.2031); TH1 *Graph3 = new TH1F("Graph3","OLO2 vs BCM2 (BcmLog_173)",100,0,1.082587); Graph3->SetMinimum(0); Graph3->SetMaximum(88.90996); Graph3->SetDirectory(0); Graph3->SetStats(0); Graph3->GetXaxis()->SetTitle("BCM2 voltage (V)"); Graph3->GetYaxis()->SetTitle("OLO2 current (#muA)"); graph->SetHistogram(Graph3); TF1 *pol1 = new TF1("pol1","pol1",0.002467,0.984394); pol1->SetFillColor(19); pol1->SetFillStyle(0); pol1->SetLineWidth(3); pol1->SetChisquare(0.03677643); pol1->SetParameter(0,-0.004459749); pol1->SetParError(0,0.03202851); pol1->SetParLimits(0,0,0); pol1->SetParameter(1,82.03567); pol1->SetParError(1,0.08069684); pol1->SetParLimits(1,0,0); graph->GetListOfFunctions()->Add(pol1); TPaveStats *ptstats = new TPaveStats(0.6115843,0.2182741,0.9727428,0.3807107,"brNDC"); ptstats->SetName("stats"); ptstats->SetBorderSize(2); ptstats->SetFillColor(19); ptstats->SetTextAlign(12); TText *text = ptstats->AddText("#chi^{2} / ndf = 0.03678 / 7"); text = ptstats->AddText("p0 = -0.00446 #pm 0.03203 "); text = ptstats->AddText("p1 = 82.04 #pm 0.0807 "); ptstats->SetOptStat(0); ptstats->SetOptFit(111); ptstats->Draw(); graph->GetListOfFunctions()->Add(ptstats); ptstats->SetParent(graph->GetListOfFunctions()); graph->Draw("ap"); TPaveText *pt = new TPaveText(0.01,0.9401777,0.4712266,0.995,"blNDC"); pt->SetName("title"); pt->SetBorderSize(2); pt->SetFillColor(19); text = pt->AddText("OLO2 vs BCM2 (BcmLog_173)"); pt->Draw(); c1->Modified(); c1->cd(); c1->SetSelected(c1); }