Professional Documents
Culture Documents
http://www.quantcode.com/modules/mydownloads/...
Username:
Links
My Account Home
Search Discussions
Contact
About
Jobs Seekers
Job Seekers
Post Job
Description: This class contains code to perform tting of function parameters using inputs of dependent and observed variables. It is translated from Fortran version of MINPACK.
where x : a vector of independent variables y : observed values p: vector of initial guess values for parameters MyFunction : name of VBA function which implements the fucntion f(x,p) res : output vector of calibrated parameter values eg., for a function f(x)=ax^2+bx+c:
Public Function MyFunction(params As Variant, x As Variant) As Variant a = params(1) b = params(2) c = params(3) m = UBound(x) ReDim function_values(1 To m) For i = 1 To m xi = x(i) function_values(i) = a * xi * xi + b * xi + c Next i MyFunction = function_values End Function
1 sur 3
06/01/2013 11:50
http://www.quantcode.com/modules/mydownloads/...
demo for Levenberg Marquardt algorithm Got a question or problem with this link? Just enter your message and click on submit. No registration is required.
Note: A copy of this message will also be emailed to the submitter of this link 3213 0 bytes Excel VBA http://www.quantcode.com/ Rating: 0.00 (0 votes) Rate this File | Modify | Delete | Report Broken File | Tell a Friend | Comments (20)
Poster Bazman76
Thread Posted: 2009/8/7 6:39 Updated: 2009/8/7 6:39 Re: Levenberg Marquardt in Excel Hi there, I am interested in using the function below. But I have never used classes in VBA before. Do I have to install part or all of the code into a class module? Are there any other dierences from using a normal VBA macro? Thanks Baz
Poster Bazman76
Thread Posted: 2009/8/17 9:53 Updated: 2009/8/17 9:53 Re: Levenberg Marquardt in Excel Please ignore previous post. The code works perfectly thank so much for this.
I have a couple of questions though: http://www.netlib.org/minpack/lmdif.f It says that the function lmdif uses a modication of the LM algorithm. Can someone please explain to me how this diers from standard LM algorithm. Also can someone point me to a good source that explains the theory behind this version of the algorithm. I have tried following the code but it is not always very clear what is happening.
Discuss this le. Just enter your message and click on submit. No
2 sur 3
06/01/2013 11:50
http://www.quantcode.com/modules/mydownloads/...
registration is required.
Similar Links: Levenberg-Marquardt for Visual C++ 2005 (Software) Levenberg Marquardt for function minimization (Forum) Hull White model calibration using Levenberg Marquardt (Software) Example of using Levenberg Marquardt for Parameters calibration in Excel (Software) Levenberg-Marquardt nonlinear least squares algorithms in C/C++ (Software) Subscribe to RSS or daily email updates of latest quantitative nance code listings Email address : Copyright 2011 QuantCode Inc. All rights reserved.
3 sur 3
06/01/2013 11:50