Package cnuphys.splot.fit
Class ANonlinearFit
java.lang.Object
cnuphys.splot.fit.ANonlinearFit
- All Implemented Interfaces:
- IValueGetter
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptiondoubleGet the chi square of the fitdouble[][]Get the covariance matrixdouble[]Get the fit parametersprotected abstract com.nr.model.MultiFuncdgetFunc()protected abstract double[]initialGuess(Fit fit) doublevalue(double x) This method is an "after the fact" evaluator.
- 
Constructor Details- 
ANonlinearFitCreate a Error function Fit- Parameters:
- fit- the fit data
- tolerance- the tolerance
- Throws:
- IllegalArgumentException
 
 
- 
- 
Method Details- 
getFitParameterspublic double[] getFitParameters()Get the fit parameters- Returns:
- the fit parameters
 
- 
getCovarianceMatrixpublic double[][] getCovarianceMatrix()Get the covariance matrix- Returns:
- the covariance matrix
 
- 
getChiSquarepublic double getChiSquare()Get the chi square of the fit- Returns:
- the chi square
 
- 
valuepublic double value(double x) This method is an "after the fact" evaluator. After the fit is complete is should be able to use the resulting fit parameters to simply evaluate the function at a given x. The default implementation uses the fitting function _func. This is good in that it guarantees consistency, but the fitting function also computes the derivatives so there is an inefficiency. NOTE: this function is NOT used by the fitting process. It is only for convenience, afterward, such as in plotting.- Specified by:
- valuein interface- IValueGetter
 
- 
initialGuess
- 
getFuncprotected abstract com.nr.model.MultiFuncd getFunc()
 
-