BivariateSampleNonlinearRegression Method

Finds the parameterized function that best fits the data.

Definition

Namespace: Meta.Numerics.Statistics
Assembly: Meta.Numerics (in Meta.Numerics.dll) Version: 4.2.0+6d77d64445f7d5d91b12e331399c4362ecb25333
C#
public NonlinearRegressionResult NonlinearRegression(
	Func<IReadOnlyList<double>, double, double> f,
	IReadOnlyList<double> start
)

Parameters

f  FuncIReadOnlyListDouble, Double, Double
The parameterized function.
start  IReadOnlyListDouble
An initial guess for the parameters.

Return Value

NonlinearRegressionResult
The fit result.

Remarks

In the returned FitResult, the parameters appear in the same order as in the supplied fit function and initial guess vector. No goodness-of-fit test is returned.

Exceptions

ArgumentNullExceptionf or start is null.
InsufficientDataExceptionThere are not more data points than fit parameters.
DivideByZeroExceptionThe curvature matrix is singular, indicating that the data is independent of one or more parameters, or that two or more parameters are linearly dependent.

See Also