On Wed, 25 May 2011 23:46:02 +0000, Ben Bolker <bbol...@gmail.com> wrote:
> Sebastian P. Luque <spluque <at> gmail.com> writes: >> Hi, >> When using method L-BFGS-B along with a parscale argument, should the >> lower and upper bounds provided be on the scaled or unscaled values? >> Thanks. > I think you can figure this out by experimentation on your own, I'm asking because I've already experimented and I'm not certain. > but I believe that all of the scaling done by parscale is internal > (i.e., you should provide bounds on the original, unmodified scale). Within the bounds I provide in the original scale I shouldn't find problems, but optim() reports that my function is returning non-finite values. I added a debugging message to the function given to optim() to see whether those bounds are being violated: fn <- function(p, l1, l2) { res <- -sum(FUNCTION-WITH-p-l1-l2) if (any(!is.finite(res))) { print(paste("problems with", p, l1, l2)) } else res } which shows me that the estimate for at least one parameter is outside the bounds. I'll try to prepare a simplified example to reproduce. -- Seb ______________________________________________ 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.