[SciPy-user] polynomal regression

Nils Wagner nwagner at iam.uni-stuttgart.de
Mon Oct 16 12:35:31 CDT 2006


On Mon, 16 Oct 2006 19:16:22 +0200
  Christian Meesters <meesters at uni-mainz.de> wrote:
> On Monday 16 October 2006 15:27, A. M. Archibald wrote:
>>
>> numpy's least-squares fitting procedure will do just 
>>what you're
>> asking for. I think it's called numpy.lstsqr (but it may 
>>have a
>> different number of ss and ts). What you really want is 
>>probably the
>> full covariance matrix, and I think it can give that to 
>>you.
> Thanks, but I'm not sure what you mean: In my numpy 
>there is no lstsqr in the 
> namespace, if I do 'from numpy import *' (fresh download 
>from svn - I needed 
> an upgrade anyway).
> 
> Perhaps my English prevents me from being understood 
>here ... Another attempt:
> Currently what I'm using is scipy.linalg.lstsq for 
>linear regressions (mostly) 
> and scipy.polyfit in other cases. For calculating 
>'errors' / 'deviations' / 
> 'uncertainties' of the calculated coefficients the 
>function needs the input 
> with errors in x & y, right? Is there any such function 
>in scipy?
> 
> Christian
> _______________________________________________
> SciPy-user mailing list
> SciPy-user at scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user

It's linalg.lstsq.
Are you looking for Total Least Squares ?
AFAIK, it's not implemented yet.
Nils


More information about the SciPy-user mailing list