[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: POLY_FIT gives wrong answer !
- Subject: Re: POLY_FIT gives wrong answer !
- From: davidf(at)dfanning.com (David Fanning)
- Date: Tue, 9 May 2000 08:17:53 -0600
- Newsgroups: comp.lang.idl-pvwave
- Organization: Fanning Software Consulting
- References: <3917F8C2.A6DB4535@oma.be>
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:19505
Henk Schets (Henk.Schets@oma.be) writes:
> Maybe all of you already know this, but I didn't and I could not find
> any documentation about it.
> The problem : I have two long arrays (x- and y-values) and I made
> subarrays out of them by using an array as subscript, like
> x = fltarray(l)
> y = fltarray(l)
> indexarr = longarray(l)
> (you know, the way to sort different arrays together)
> However, when I do something like out =
> poly_fit(x[indexarr],y[indexarr]), the outcome is simply wrong ! I know
> this because other programs gave another solution (all the same).
> The only way to do it right is by making other arrays like x2 and y2 and
> doing a poly_fit on it.
> Is this a known issue ?
I don't know. What is known is that things are not always
the way they seem to be. I'm guessing this is one of those
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: firstname.lastname@example.org
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155