similar to: Repeated SANN values.

Displaying 20 results from an estimated 300 matches similar to: "Repeated SANN values."

2009 Oct 20
1
Buglet in optim() SANN
I think SANN method in optim() is failing to report that it has not converged. Here is an example genrose.f<- function(x, gs=NULL){ # objective function ## One generalization of the Rosenbrock banana valley function (n parameters) n <- length(x) if(is.null(gs)) { gs=100.0 } fval<-1.0 + sum (gs*(x[1:(n-1)]^2 - x[2:n])^2 + (x[2:n] - 1)^2) return(fval) }
2008 Jan 18
1
constrOptim with method SANN
Hi Everyone, I'm trying to minimize a function using constrOptim with the simulated annealing method SANN. If I understand constrOptim well, it basically passes most of its arguments to optim while somehow enforcing the constraints. My problem is, that since SANN does not need gradients, when using optim with SANN, the gr argument of optim is used to specify a function to create the next
2008 Jan 18
0
constrOptim with SANN
Hi Everyone, I'm trying to minimize a function using constrOptim with the simulated annealing method SANN. If I understand constrOptim well, it basically passes most of its arguments to optim while somehow enforcing the constraints. My problem is, that since SANN does not need gradients, when using optim with SANN, the gr argument of optim is used to specify a function to create the next
2004 May 28
1
optim(method="SANN")
Hello List I'm working on a combinatoric problem in which the object is to minimize the badness() of a vector. I think this class of problem is only soluble by optim() using method=SANN. The badness() of anything is >= 0, and when I've found a solution with zero badness, I want optim() to stop (carrying on beyond zero badness cannot improve the solution). Efficiency is crucial here.
2011 Dec 16
1
optim with simulated annealing SANN for combinatorial optimization
Hi all I am trying to solve a combinatorial optimization problem. Basically, I can reduce my problem into the next problem: 1.- Given a NxN grid of points, with some values in each cell 2.- Find the combination of K points on the grid such that, the maximum mean value is obtained I took the Travel SalesMan problem example in ?optim documentation. I am not sure if I have understood correctly
2009 Nov 19
1
optim(.. ,"SANN",..)
I have a problem using optim, so I am hoping someone can help me out with it: Suppose I have the list: list(D,R,P) [[1]] V1 V2 V3 V4 1 0 1 0 1 2 1 1 0 0 3 1 0 1 0 4 0 0 1 1 5 0 1 0 1 6 1 1 0 0 7 1 0 1 0 8 0 0 1 1 9 1 0 1 0 10 0 0 1 1 [[2]] [1] 23 85 12 73 23 24 25 56 78 1200 [[3]] V1 1 25 2 80 3 15 4
2003 Jul 16
2
numerical differentiation in R? (for optim "SANN" parscale)
Dear R users, I am running a maximum likelihood model with optim. I chose the simulated annealing method (method="SANN"). SANN is not performing bad, but I guess it would be much more effecive if I could set the `parscale' parameter. The help sais: `parscale' A vector of scaling values for the parameters. Optimization is performed on `par/parscale' and these
2008 Mar 16
1
optim: why is REPORT not used in SANN?
Hello, I wonder why the control parameter REPORT is not supported by method SANN. Looking into optim.c I found an internal constant: #define STEPS 100 ... and decreasing this to 10 helped me fine-tuning the annealing parameters in an actual problem. Is there any reason why not passing nREPORT to samin and setting something like: STEPS = nREPORT / tmax Thomas P. -- Thomas Petzoldt
2013 Feb 27
2
temp seems ineffective in SANN (optim)
I am trying to control the behavior of the SANN method in optim (R 2.14.1) via control$temp. In my toy tests it works; in my real use, it doesn't. As far as I can tell my code with different temp values is loaded; I even traced into the function that calls optim and verified temp had the value I had set. Could the fact that I have NaN's coming back from the objective function be a
2011 Dec 16
1
Fortune? -- was Re: optim with simulated annealing SANN ...
Folks: I thought John Nash's comment below was profound and a possible Fortunes candidate: (Aside: I believe it applies to a great deal of what is discussed on this list, not just stochastic optimization.) Cheers, Bert ... (in the context of stochastic optimization) >... As with many tools in this domain, for effective use they > require more knowledge than many of their users
2008 Jun 26
1
Question about Constraint Optimization
Dear All, I am having trouble in using R function "constrOptim" to do constraint optimization. It seems that "constrOptim" calls function "optim" when it does the optimization, and "optim" allows us to set "method" to be "SANN" if we want to use simulated annealing. In "optim", the function allows us to set gradient to be
2001 Feb 20
0
dyn.load() and dyn.unload() under Windows
Hello: I am having some difficulty with a DLL, using > version _ platform i386-pc-mingw32 arch x86 os Win32 system x86, Win32 status major 1 minor 2.1 year 2001 month 01 day 15 language R I have a library called
2002 Aug 13
1
Rcmd SHLIB under NT
Hello: I'm trying to use Rcmd SHLIB to compile a single file, sann.c, to get sann.dll. I was able to get make libR.a to work, after going into MkRules and changing the line DLLTOOL=$(BINPREF)dlltool -k --as $(AS) to read DLLTOOL=C:/MINGW-1.1/bin/dlltool -k --as $(AS) But now I get: C:\rw1051\src\gnuwin32>Rcmd SHLIB sann.c make: make: Command not found make: *** [libR] Error 127
2011 Apr 18
3
how to extract options for a function call
Hi, I'm having some difficulties formulating this question. But what I want, is to extract the options associated with a parameter for a function. e.g. method = c("Nelder-Mead", "BFGS", "CG", "L-BFGS-B", "SANN") in the optim function. So I would like to have a vector with c("Nelder-Mead", "BFGS", "CG",
2009 Feb 12
0
Sign differences amoung QR solutions.
I was noticing mainly sign differences amoung the solutions to QR decomposition. For example R: > x <- matrix(c(12,-51,4,6,167,-68,-4,24,-41),nrow=3,byrow=T) > x [,1] [,2] [,3] [1,] 12 -51 4 [2,] 6 167 -68 [3,] -4 24 -41 > r <- qr(x) > r$qr [,1] [,2] [,3] [1,] -14.0000000 -21.0000000 14 [2,] 0.4285714 -175.0000000 70 [3,]
2007 Feb 17
1
Solve in maximum likelihood estimation
Hi, I got the following problem. I am doing a maximum likelihood estimation for a Kalman Filter. For this purpose, I have to invert an error matrix Ffast of dimension "no. parameters X no.parameters". The usualy optim methods often find only local minima, so I decided to make the optimization using the SANN algorithm, which is very slow already. However, this becomes a real problem
2011 Jun 02
0
allowing individual level correlations to differ by cluster in lme in R
Dear R-listers, I am fitting bivariate mixed models for cost-effectiveness data of cluster randomized trials using lme in R. So I have individuals nested within clusters. My response variable is a vector with bivariate response (individual level costs and effects) stacked into a single column. The covariates in my models are a constant and a treatment term. They are response-specific, e.g. a
2004 Oct 02
1
constraints in optim?
> optim(c(1,1),LL,method="SANN",control=list(fnscale=-1),trans=trans,times=times) $par [1] 17.422635 -1.606859 How could i constraint that the parameters should be both positive in my maximizing problem? I check constrOptim but here i could only constraint the variables trans and times and not my parameters? many thanks, regards Christian
2009 Oct 22
2
Advice on how to arrange fix of buglet
Recently I reported a small bug in optim's SANN method failing to report that it had exceeded the maximum function evaluation limit in the convergence code. This is a small enough matter that I was reluctant to create a full-blown bug report. Indeed in the optimx package Ravi Varadhan and I have been developing on r-forge (under the OptimizeR project) it was a minimal work around to fix
2007 Aug 02
1
constraint in constrOptim
I'm using the function constrOptim together with the "SANN" method and my objective function (f) has two parameters. One of the parameters needs be into (2^(-10), 2^4) range and the other into (2^(-2), 2^12) range. How can I do it using constrOptim?? Thank you André Rossi Alertas do Yahoo! Mail em seu celular. Saiba mais em http://br.mobile.yahoo.com/mailalertas/