Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: st: where next after nl?
From
"Keith Dear" <[email protected]>
To
<[email protected]>
Subject
RE: st: where next after nl?
Date
Tue, 18 Jan 2011 11:52:46 +1100
Thanks Maarten, but yes I am providing at least some starting values.
The small example I carried across to Excel had four nonlinear and just six linear parameters (_cons+5). If I insert Excel's solution just for the nonlinear parameters, then nl still fails (RSS=147,098; Excel found RSS=143,309; N=6532; RMS=2.19).
If I provide starting values for all 10 parameters, to four sig.figures, then nl sort-of agrees with that solution: it performs 20 iterations (the limit I set) without declaring convergence and without changing the RSS, and then reports a non-converged "solution" very close to the starting values.
If I roughen the starting values to just 1 figure (as if from an approximate solution as in your archive post) then nl finds (with no further change but without converging) what I suppose is a local minimum with RSS=144,129.
Maybe I should start with a 4D grid evaluation over the nonlinear parameters, fitting the linear model at each point ... but this seems more than a bit desperate, and anyway wouldn't work with 8 parameters. Any advice appreciated!
kd
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Maarten buis
Sent: Monday, 17 January 2011 7:07 PM
To: [email protected]
Subject: Re: st: where next after nl?
--- On Mon, 17/1/11, Keith Dear wrote:
> I've been trying to fit nonlinear models using -nl-, and
> finding that it often fails to find a good solution.
My experience with -nl- is that often it needs user specified
starting values in order to achieve reasonable convergence.
But when I specified these starting values, it tends to work
quite well. An example of how to specify starting values is
given in this post (and ofcourse in the documentation of -nl-):
<http://www.stata.com/statalist/archive/2008-01/msg01006.html>
Hope this helps,
Maarten
--------------------------
Maarten L. Buis
Institut fuer Soziologie
Universitaet Tuebingen
Wilhelmstrasse 36
72074 Tuebingen
Germany
http://www.maartenbuis.nl
--------------------------
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/