{ //=========Macro generated from canvas: c1/c1 //========= (Mon Aug 8 13:51:37 2011) by ROOT version5.18/00b TCanvas *c1 = new TCanvas("c1", "c1",743,85,699,499); gStyle->SetOptFit(1); c1->SetHighLightColor(2); c1->Range(-0.1357914,-11.27751,1.222122,101.4976); c1->SetBorderSize(2); c1->SetFrameFillColor(0); TGraph *graph = new TGraph(9); graph->SetName("Graph"); graph->SetTitle("OLO2 vs BCM2 (BcmLog_171)"); graph->SetFillColor(1); graph->SetMarkerColor(4); graph->SetMarkerStyle(22); graph->SetPoint(0,0.987796,82.0364); graph->SetPoint(1,0.600887,49.523); graph->SetPoint(2,0.247266,20.2049); graph->SetPoint(3,0.122282,10.0869); graph->SetPoint(4,0.062585,5.1639); graph->SetPoint(5,0.024394,2.0276); graph->SetPoint(6,0.012042,1.0019); graph->SetPoint(7,0.005818,0.4812); graph->SetPoint(8,0.002445,0.1998); TH1 *Graph2 = new TH1F("Graph2","OLO2 vs BCM2 (BcmLog_171)",100,0,1.086331); Graph2->SetMinimum(0); Graph2->SetMaximum(90.22006); Graph2->SetDirectory(0); Graph2->SetStats(0); Graph2->GetXaxis()->SetTitle("BCM2 voltage (V)"); Graph2->GetYaxis()->SetTitle("OLO2 current (#muA)"); graph->SetHistogram(Graph2); TF1 *pol1 = new TF1("pol1","pol1",0.002445,0.987796); pol1->SetFillColor(19); pol1->SetFillStyle(0); pol1->SetLineWidth(3); pol1->SetChisquare(0.1671686); pol1->SetParameter(0,-0.05804659); pol1->SetParError(0,0.06819817); pol1->SetParLimits(0,0,0); pol1->SetParameter(1,82.90815); pol1->SetParError(1,0.1718374); pol1->SetParLimits(1,0,0); graph->GetListOfFunctions()->Add(pol1); TPaveStats *ptstats = new TPaveStats(0.6030664,0.215736,0.9642249,0.3781726,"brNDC"); ptstats->SetName("stats"); ptstats->SetBorderSize(2); ptstats->SetFillColor(19); ptstats->SetTextAlign(12); TText *text = ptstats->AddText("#chi^{2} / ndf = 0.1672 / 7"); text = ptstats->AddText("p0 = -0.05805 #pm 0.0682 "); text = ptstats->AddText("p1 = 82.91 #pm 0.1718 "); 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_171)"); pt->Draw(); c1->Modified(); c1->cd(); c1->SetSelected(c1); }