Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2005
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2005

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Coefficients from Fit as a list?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg63414] Re: [mg63396] Coefficients from Fit as a list?
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Fri, 30 Dec 2005 02:32:31 -0500 (EST)
  • Reply-to: hanlonr at cox.net
  • Sender: owner-wri-mathgroup at wolfram.com

points={{0,-1},{1,2},{3,7},{4,6},{7,9},{11,14}};

Fit[points,{1,x,x^2},x]

-0.0592841*x^2 + 1.89613*x - 0.113262

Reverse@Most@Cases[%,_?NumericQ,Infinity]

{-0.0592841,1.89613,-0.113262}

param={a,b,c};

param/.FindFit[points,a*x^2+b*x+c,param,x]

{-0.0592841,1.89613,-0.113262}

Needs["Statistics`NonlinearFit`"];

param/.(BestFitParameters/.
      NonlinearRegress[points,
         a*x^2+b*x+c, x, param])

{-0.0592841,1.89613,-0.113262}


Bob Hanlon

> 
> From: "LectorZ" <lectorz at mail.ru>
To: mathgroup at smc.vnet.net
> Date: 2005/12/29 Thu AM 02:57:28 EST
> Subject: [mg63414] [mg63396] Coefficients from Fit as a list?
> 
> Hi there,
> 
> How can I store the coefficients from the Fit function as a list?
> 
> Thanks,
> 
> LZ
> 
> 


  • Prev by Date: Re: Coefficients from Fit as a list?
  • Next by Date: Re: Mathematica code & Latex
  • Previous by thread: Re: Coefficients from Fit as a list?
  • Next by thread: Mathematica code & Latex