Re: Saving canvas with functions like script

From: Dmitry A. Shtol <D.A.Shtol_at_inp.nsk.su>
Date: Fri, 4 Feb 2005 14:19:33 +0600


Hi!
root version is 4.00/08
The shortest script with problem:

{
//=========Macro generated from canvas: c1/c1 //========= (Fri Feb 4 14:16:26 2005) by ROOT version4.00/08

   TCanvas *c1 = new TCanvas("c1", "c1",433,24,699,499);

   c1->Range(-20.1021,426509,1789.09,6.40085e+06);
   c1->SetBorderSize(2);
   c1->SetFrameFillColor(0);
   

   TF1 *VE20p = new TF1("VE20p","",160.817,1608.17);

   VE20p->SetFillColor(19);
   VE20p->SetFillStyle(0);
   VE20p->SetLineColor(4);
   VE20p->SetLineWidth(3);
   VE20p->SetParameter(0,0.743467);
   VE20p->SetParError(0,0);
   VE20p->SetParLimits(0,0,0);
   VE20p->SetParameter(1,0.500967);
   VE20p->SetParError(1,0);
   VE20p->SetParLimits(1,0,0);
   VE20p->SetParameter(2,-0.260267);
   VE20p->SetParError(2,0);
   VE20p->SetParLimits(2,0,0);
   VE20p->SetParameter(3,0.411107);
   VE20p->SetParError(3,0);
   VE20p->SetParLimits(3,0,0);
   VE20p->SetParameter(4,-0.524272);
   VE20p->SetParError(4,0);
   VE20p->SetParLimits(4,0,0);
   VE20p->SetParameter(5,-1.66894);
   VE20p->SetParError(5,0);
   VE20p->SetParLimits(5,0,0);
   VE20p->SetParameter(6,1.81764);
   VE20p->SetParError(6,0);
   VE20p->SetParLimits(6,0,0);
   VE20p->SetParameter(7,3.03437);
   VE20p->SetParError(7,0);
   VE20p->SetParLimits(7,0,0);
   VE20p->SetParameter(8,-1.58357);
   VE20p->SetParError(8,0);
   VE20p->SetParLimits(8,0,0);
   VE20p->SetParameter(9,-2.08492);
   VE20p->SetParError(9,0);
   VE20p->SetParLimits(9,0,0);
   VE20p->SetParameter(10,2);
   VE20p->SetParError(10,0);
   VE20p->SetParLimits(10,0,0);
   VE20p->SetParameter(11,-1);
   VE20p->SetParError(11,0);
   VE20p->SetParLimits(11,0,0);
   VE20p->SetParameter(12,0.8);
   VE20p->SetParError(12,0);
   VE20p->SetParLimits(12,0,0);
   VE20p->SetParameter(13,3.14465e+06);
   VE20p->SetParError(13,0);
   VE20p->SetParLimits(13,0,0);
   VE20p->SetParameter(14,321.634);
   VE20p->SetParError(14,0);
   VE20p->SetParLimits(14,0,0);
   VE20p->Draw("");
   c1->Modified();
   c1->cd();

   c1->SetSelected(c1);
   c1->ToggleToolBar();
}

There are no formula. What should do to make root to create right script?

-- 
Dmitry A. Shtol                        (SND group)    
Budker Institute of Nuclear Physics  
Received on Fri Feb 04 2005 - 09:19:48 MET

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:04 MET