Re: Curve fitting help needed




"Nicros" <da@xxxxxx> wrote in message
news:K8imf.37274$D13.12041@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Hi,
>
> I have a series of data points that I am fitting to a reference set. I
> am currently using a chebyshev polynomial approximation to minimize the
> error in the fit.
>
> However, outliers and erronious data points have been causing a huge
> headache.
>
> If there is one poor fitting data point, then all the good points that
> would fit perfectly (if this poor data point was removed) are fitted
> poorly. Removing the data points before fitting is not desireable,
> since I have no way of really knowing ahead of time which data points
> might be bad.
>
> Is there a minimization fitting routine or algorithm out there that will
> minimize the maximum number of datapoints to the highest degree
> possible, while allowing poor fit of outliers? So that if I have 10
> data points (for example) and one of them is significantly off, the
> algorithm allows this one point to shift as far as necessary to fit the
> other 9 perfectly? How about 5 and 5? No clue what would even need to
> happen here.
>
> I am not a mathmatician, Im a software engineer and I didnt find
> anything in numerical recipes in c++ that sounded like it could do this.
>
> Does such an algorithm even exist? Any suggestions or links are
> appreciated!
>
> Thanks,
> N


Maybe someone will point you to an algorithm, but if not you could try this.

Most fitting routines allow you to assign weights to each data point
according to how good you think the point is.
So fit once with all the weights = 1
Calculate the error (deviation) of each point from fitted curve.
Use new weights = 1/(1+|error|) for each point.
Refit
Maybe iterate a few times.

If your data is all over the place this may not converge, but it should do
if most points lie on the curve.





.



Relevant Pages

  • Re: Update Query; But keep rest of field...
    ... Left$ and Right$ act like a scissors, counting from left or right, and cutting the string at that point, returning just that portion of the string. ... Comparing "Fitting ABS" with Left$will tell you if the beginning matches the eleven characters in "Fitting ABS". ... Will take "Fit ABS", and add everything except the first eleven characters, of tblItem.to it. ... Using the Design View to create a query, ...
    (microsoft.public.access.queries)
  • Re: Update Query; But keep rest of field...
    ... Using the Design View to create a query, ... UPDATE tblItem SET tblItem.itemMfgItemNumber = "Fit ABS" ... The goal is to find all items that START with "Fitting ABS" and change them ... Fitting PVC Sch40 1" 90 ELL SxS ...
    (microsoft.public.access.queries)
  • Re: Singular matrix in Invert_RtR
    ... Singular matrix in Invert_RtR ... The problem is that Gnuplot's fit uses a procedure known as Marquard-Levenberg algorithm, ... There is an alternative fitting algorithm, Simplex by Nelson & Mead, which is much more stable and can also minimise Chi^2 or the median of residuals in those cases where minimising the sum of squares is statistically inappropriate. ... Unfortunately, Simplex can not directly calculate the standard deviations for the parameters, that is probably the reason why many scientific fitting programs do not use it. ...
    (comp.graphics.apps.gnuplot)
  • Re: Converting confidence interval to p value
    ... "goodness of fit" as a statistic, ... you want a p-value for testing what? ... squares compared with your model. ... are fitting and what type of test you want. ...
    (comp.soft-sys.matlab)
  • Re: Converting confidence interval to p value
    ... "goodness of fit" as a statistic, ... you want a p-value for testing what? ... squares compared with your model. ... are fitting and what type of test you want. ...
    (comp.soft-sys.matlab)