minimize_least_squares: Minimizes the sum of the error squares

View source: R/minimize_least_squares.R

minimize_least_squaresR Documentation

Minimizes the sum of the error squares

Description

This is an internal function of the remulator package. It fits a user defined function to data minimizing the sum of the error squares.

Usage

minimize_least_squares(dat, initial_values, userform, ...)

Arguments

dat

Array with data points to fit containing one column with sample numbers, one column with x values, and one column with y values

initial_values

Initial values for the parameters to be optimized over.

userform

Fit function for which least squares will be calaculated using the optim function.

...

Arguments passed on to the optim function. Useful to define bounds on fit coefficients.

Value

list containing fit coefficients and messages

Author(s)

David Klein


pik-piam/remulator documentation built on Oct. 19, 2023, 4:07 p.m.