> This is not efficient. For whom?
> (a) L-BFGS-B does not identify itself even though it was called overriding > the method > parameter in optim. Would you prefer that the warning > o <- optim(par=c(1,2), fn=function(x)-sum(abs(sin(x))), method="CG", lower=c(-1,-1), upper= c(2,3)) Warning message: In optim(par = c(1, 2), fn = function(x) -sum(abs(sin(x))), method = "CG", : bounds can only be used with method L-BFGS-B (or Brent) explicitly say that method L-BFGS-B was used because bounds were given? > (b) Optim reports as final converged minimum value a function value that is > much larger > than others computed during the optimization. That is where a self-contained example would make it much quicker to identify and perhaps fix the problem. Bill Dunlap Spotfire, TIBCO Software wdunlap tibco.com > -----Original Message----- > From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On > Behalf > Of Michael Meyer > Sent: Wednesday, September 04, 2013 1:35 AM > To: r-help@r-project.org > Subject: [R] optim evils > > It would take some effort to extract selfcontained code from the mass of code > wherein > this optimization is embedded. Moreover I would have to obtain permission > from my > employer to do so. > > This is not efficient. > However some things are evident from the trace log which I have submitted: > (a) L-BFGS-B does not identify itself even though it was called overriding > the method > parameter in optim. > (b) OptimĀ reports as final converged minimum value a function value that is > much larger > than > others computed during the optimization. > > I think we can agree on calling this a bug. > [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.