search for: initpar

Displaying 2 results from an estimated 2 matches for "initpar".

2009 May 03
3
Optim function in the loop
...o some iterations to find the global optimal values, but the function does not execute properly. Every time codes stop after one iteration right after executing the optim() function. Does anyone could have me to take a look? Thanks. if (count>0){ k=k+0.05; mu0=c(83+k,0,0) Sigma0= diag(0.4,3) initpar=c(.1+10*k,10*k,10*k,10*k) # initial parameters for Phi[1,1], the 2 Q?s and R est=optim(initpar,Linn,NULL,method="BFGS",hessian=TRUE,control=list(trace=1,REPORT=1,maxit=300)) stderr=sqrt(diag(solve(est$hessian))) estimate=est$par u=cbind(estimate,stderr) if (u[1]>0 & u[2]>0...
2010 Sep 29
2
R crashes when loading rgl package before minqa package
...,35,36) yvals = c(857.7597,975.8624,978.2655,979.3034,965.5919,983.8946,992.2512,992.1178,979.5379,974.4269,968.4113,991.5210,977.3361,985.7800,975.5220,974.6880,973.8102,980.7295,982.0034,984.7993,978.4948,970.4351,969.0718,983.7892,976.3637,980.7833,987.1665,976.6000,975.1332,971.0757,989.4693) initpar = c(-5.1471384, -3861.8905839, 979.2616002, 0.2572355, 27.5705764) optimft <- function(x) { yft = x[2] + (x[3] - x[2])/((1 + exp(x[1] * (log(xvals) - log(x[4]))))^x[5]) return(sum((yvals - yft)^2)) } Sequence of commands needed to make the bug appear: <Start R> source('bugs.R...