From octave-sources-request at bevo dot che dot wisc dot edu Wed Aug 21 10:14:49 2002 Subject: small change to leasqr.m From: "E. Joshua Rigler" To: octave-sources at bevo dot che dot wisc dot edu Date: 21 Aug 2002 09:12:13 -0600 I want to recommend, and perhaps eventually submit a small change to the leasqr.m function in octave-forge that should be completely transparent and backward compatible. Feedback on my idea, and instructions for submitting this change would be appreciated. In the eval calls to the function "F" (i.e. the function who's parameters are being estimated), and "dFdp" (either the numerical, or user-written analytic derivative function), I suggest that a structure is passed that contains miscellaneous information that is neither an input or output vector, nor one of the parameters. It will be the job of the user-written function to use the information in that structure appropriately. This, of course, will require an additional input to leasqr.m, but if the structure is placed as the last input variable, no previously written code should be affected. It also seems to me that this should be compatible with Matlab, which seems to have been another goal of the authors of leasqr.m. My only option now (aside from changing my local copy of leasqr.m) is to set a global variable, or variables, that define the options I want, but I always feel a little tainted using global variables (a consequence of working on too much bad FORTRAN code I suppose). If someone has a better option, please let me know. Thanks. -EJR