public abstract class MarquardtChiSqFitter extends MarquardtMinimiser
MarquardtMinimiser
to
minimise a chi^2 goodness of fit measure between a model and some data. yfit
and dydas need to be implemented in subclasses, which encapsulate the model
for the data and its derivatives. The second derivatives are approximated by
multiples of first derivatives avoiding the need for their computation.
Constructor and Description |
---|
MarquardtChiSqFitter() |
Modifier and Type | Method and Description |
---|---|
double |
getChiSq()
Returns the value of chi-squared.
|
double |
getRelativeResidual()
Returns the mean squared relative error given the current values in a.
|
double |
getResidual()
Returns the average residual squared error given the current values in a.
|
double[] |
getResiduals()
Returns the residual error (absolute difference from fitted value) for
each data point.
|
void |
setSig(int index,
double std)
Allows the standard deviations of the data points to be specified.
|
getCONVERGETHRESH, getFObjVal, getParameters, minimise, setConvergence, setCONVERGETHRESH, setInitParams, setMAXITER
public void setSig(int index, double std)
index
- The index of the standard deviation to set.std
- The new value of the standard deviation.public double getChiSq()
public double getResidual()
public double[] getResiduals()
public double getRelativeResidual()