A versatile implementation of the Gauss-Newton minimization algorithm using MATLAB for Macintosh microcomputers.
The present report describes a weighted nonlinear least-squares minimization routine for fitting a wide variety of functions nonlinear in the parameters. The minimization routine is implemented in MacMATLAB, the Macintosh microcomputer version of MATLAB, an interactive program for scientific numeric calculations. Our algorithm makes use of a subroutine that estimates the required derivatives numerically, avoiding the need to differentiate the function under study analytically. We have also implemented two specific subroutines to integrate ordinary differential equations numerically. Therefore, in principle, any kind of nonlinear function can be fitted to a given set of data. The program only requires that the user writes the appropriate equation in a specific subroutine, thus relieving one from knowing and using any 'low-level' code. Other features of the program are: (a) the possibility of using weight to correct for nonuniformity of variance by flexible specification of the error structure; (b) the possibility of checking the parameter values and the residual variance at each iteration; and (c) by the use of the graphic capabilities of MacMATLAB, the possibility of following the improvement of the fitting graphically. One example of nonlinear functions and one example of linear differential equation together with their respective 'function file' and illustrative data are presented to demonstrate the flexibility of our approach and the power of the method used.
Institute of Pharmacological Sciences, University of Milan, Italy.
G E
GE
Rovati
D000465:Algorithms; D008432:Mathematical Computing; D008838:Microcomputers; D012984:Software