[R] nlm recursion problem
j.logsdon at lancaster.ac.uk
Wed Sep 29 11:24:34 CEST 1999
I am trying to use nlm with an additional call to nlm within the function
but after the first pass, the parameters to the outer call are being
passed to the inner call. The inner call is a very trivial problem.
on the second call of test.outer by nlm, the inner calls to test.inner are
I have tried the obvious nlmx<-nlm and calling nlmx as the inner call but
this does not fix it. Can I use recursion with nlm or is there an
alternative non-linear minimiser? I suspect that it is the static memory
within the Fortran - is there any way of copying this to an object after
the outer call then restoring it after the inner calls?
nlm is called by many functions and packages so perhaps this is quite a
common problem - what is the slickest way round it? The solution required
is just the intercept and slope of a line where there may be censored data
so lm() won't do and neither will optimise() (it is only for 1 dimension
and I require 2).
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
More information about the R-help