Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2008

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

Search the Archive

Re: Fit data with range

  • To: mathgroup at smc.vnet.net
  • Subject: [mg88442] Re: Fit data with range
  • From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
  • Date: Mon, 5 May 2008 06:15:32 -0400 (EDT)
  • References: <fvhdv7$3q6$1@smc.vnet.net>

Hi,

fit = Fit[Select[data,(xmin<=First[#1]<=xmax) &],{1,x,x^2},x]

??

Regards
   Jens

Ivan wrote:
> Hi
> 
> I want to fit a polynomial function to a set of data,
> only between say xmin to xmax. How can I do that?
> I know only how to fit the whole range.
> 
> For example:
> 
> data = ReadList["file.dat",{Number,Number}];
> 
> fit = Fit[data,{1,x,x^2},x]
> 
> Plot[fit,{x,0,10}]
> 
> 
> 
> thanks!
> 


  • Prev by Date: root of complex function
  • Next by Date: Re: Identical elements
  • Previous by thread: RE: Fit data with range
  • Next by thread: Re: Fit data with range