Ajay Narottam Shah
2005-Jun-09 09:13 UTC
[R] optim() does SANN, why not genetic algorithm (genoud)
It is a very nice touch that optim() offers SANN (simulated annealing) as a random search algorithm. The R community already has genoud - an implementation of a genetic algorithm for search. Wouldn't it be neat if optim() would additionally offer method="GA" where it internally uses code from genoud? I glanced at the code and I find the work is all being done in res <- .Internal(optim(par, fn1, gr1, method, con, lower, upper)) Should we do it as: if (method == "GA") { # insert genoud calls here. } else { res <- .Internal(optim(par, fn1, gr1, method, con, lower, upper)) } Who wrote optim, and who maintains it? -- Ajay Shah Consultant ajayshah at mayin.org Department of Economic Affairs http://www.mayin.org/ajayshah Ministry of Finance, New Delhi