search for: iterlim

Displaying 14 results from an estimated 14 matches for "iterlim".

Did you mean: iteri
2011 Aug 24
1
problema de selección de valores iniciales en nlm
Hola a todos, Necesito estimar dos parametros utilizando la función nlm; fit<-nlm(hood2par,c(x01[i],x02[j]),iterlim=300, catch=x[,c(3,4,5)],sp=.5) donde hood2par es una logística modificada. Pero en mi caso, la convergencia de nlm depende de los valores iniciales de dichos parámetros. Para buscar dichos valores iniciales de manera automática, genero dos vectores de valores iniciales posibles, x01=seq(-10,-...
2011 Apr 10
0
maxLik package.
Dear Sir/ Madam,   I have some enquiry in R about maxLik package where, in this package we have the usage  maxLik(logLik, grad, hess, start, method, iterlim, print.level)   when I used this with print.level equals to 3 I could have estimates of parameters at each iteration but I do not know how can I call the information in the level. Is there any way can help me to call the information within the print. level argument?. Also when I changed the num...
2007 Apr 09
1
R:Maximum likelihood estimation using BHHH and BFGS
...r = Inf, control = list(), hessian = FALSE, ...) (c) > optim(c(c,1,0),fn, method="BFGS", control=list(c=c))* Error: argument "psi" is missing, with no default *(3a) maxBHHH{micEcon} (b) Usage: maxBHHH(fn, grad = NULL, hess=NULL, theta, print.level = 0, iterlim = 100, ...)* * * *(c) > maxBHHH(fn(c,psi,alpha),theta=list(psi=1,alpha=0))* Error in psi^(-1/alpha) * (lag(c[i], -1)) : time-series/vector length mismatch (4a) maxBFGS{micEcon} (b) Usage: maxBFGS(fn, grad = NULL, theta, print.level = 0, iterlim = 200, tol = 1...
2010 Mar 25
1
*** caught segfault *** address 0x18, cause 'memory not mapped'
...ainsimbiasP" > > ptm<-proc.time() > sink("out22031001.txt") > > fmainsimbiasP(10000,100) proc.time()-ptm *** caught segfault *** address 0x18, cause 'memory not mapped' Traceback: 1: nlm(f = fprof_deriv, x = x, p = parHInt, b = parFIX, hessian = T, iterlim = 2000, check.analyticals = F, stepmax = 10) 2: doTryCatch(return(expr), name, parentenv, handler) 3: tryCatchOne(expr, names, parentenv, handlers[[1]]) 4: tryCatchList(expr, classes, parentenv, handlers) 5: tryCatch(expr, error = function(e) { call <- conditionCall(e) if (!is.null(call)...
2011 Sep 15
2
Tobit Fixed Effects
Hi there, I need to run a Tobit Fixed Effects in a panel data with 4500 units for 8 years. It is a huge data set, my dependent variable is left truncated at zero, the distribution is skewed and my panel is balanced. Any suggestions on how to do that in R? I tried stuff like survreg, censReg, and tobit but none of them were satisfactory. Thanks, *Felipe Nunes* CAPES/Fulbright Fellow PhD
2008 Jan 15
1
Viewing source code for .Internal functions
...trying to view the source code of the function nlm in the stats package of R 2.4.1. I downloaded the source from CRAN and opened nlm.R, and it calls a .Internal function: .Internal(nlm(function(x) f(x, ...), p, hessian, typsize, fscale, msg, ndigit, gradtol, stepmax, steptol, iterlim)) This is the same thing I saw when entering the function name at the R command prompt. Where will I find the actual code? Thanks.
2007 Feb 17
1
Constraint maximum (likelihood) using nlm
...at[i,1] - params[1])^2/ (params[2]^2 + dat[i,2]^2)) } ll <- -0.5 * llsum + constant return(-ll) } Using (find data attached): data.osl <- read.table("osl.dat",header=TRUE) data.matrix <- as.matrix(data.frame(data.osl$de,data.osl$se)) nlm(negll,c(0.75,0.5),dat=data.matrix,iterlim=200) I get estimates for mu and sigma of: 3.629998e+00 -4.975368e-07 However, sigma obviously has to be >= 0. Therefore I am trying to transform sigma: negll.trans <- function(params,...) { params[2] <- log(params[2]) negll(params,...) } where nlm(negll.trans,c(0.75,0.5),dat=data....
2011 Sep 05
3
function censReg in panel data setting
Hello all, I have a problem estimating Random Effects model using censReg function. small part of code: UpC <- censReg(Power ~ Windspeed, left = -Inf, right = 2000,data=PData_In,method="BHHH",nGHQ = 4) Error in maxNRCompute(fn = logLikAttr, fnOrig = fn, gradOrig = grad, hessOrig = hess, : NA in the initial gradient ...then I tried to set starting values myself and here is
2009 May 16
1
maxLik pakage
...t(omega^2+lambda2*(x-ksi)^2)) /(pnorm(lambda1*(x-ksi)/(sqrt(omega^2+lambda2*(x-ksi)^2))*sqrt((omega^2+lambda2*(x-ksi)^2)^3))))))) } n<- length(x) # the final command is : res<- maxLik(G2StNV178,grad=gradlik,start=c(4.666484 ,4603.399055 , 4603.399055   ,-0.016674 ,19.055865),tol=1e-16,iterlim =3000) summary(res) [[alternative HTML version deleted]]
2011 Nov 23
6
Incomplete final line (Antonio José Sáez)
...] logL1<-function(p){ l1<-exp(p[1]) l2<-l1 s<-exp(p[2]) -(n.neg*log(l1)+n.pos*log(l2) -l1*sum(log(1-x.neg/s))-l2*sum(log(1+x.pos/s)) -sum(log(1+abs(x)/s)) -n*log(s)+n*log(0.5) ) } if (method==1){ p0<-c(log(p0l),log(p0s)) fit<-nlm(logL1,p=p0,hessian= TRUE,iterlim=iters,print.level=print.level) fit$value<-fit$minimum fit$par<-fit$estimate fit$convergence<-fit$code method="hessian nlm" l.est<-exp(fit$par[1]) s.est<-exp(fit$par[2]) } #Resultados resultados<-list( coefficients=c(l.est,s.est), se="Mejor por bootstrapi...
2004 Aug 21
0
Convergence code in nlm function
...the optional parameters in the nlm call but this does not help to achieve code=1. What may be a reason for such situation? Could I think that the obtained estimates are what I am looking for? I am using R 1.9.1: nlm(N.Loglik,initial.values,fscale=1,print.level = 1, gradtol = 1e-6,steptol = 1e-6,iterlim = 500,y=y) Much thanks, Victoria. [[alternative HTML version deleted]]
2013 May 10
1
PGLM Package: Starting Values for Within-Model
...in panel regression. I am using the example data set from the PGLM package: library(pglm) data('Unions', package = 'pglm') anb <- pglm(union~wage+exper+rural, Unions, family=binomial('probit'), model="within", method = "bfgs", print.level=0, R = 5, iterlim=2) The pglm-function needs the argument start for starting values. What do I use? Thank you very much! -- View this message in context: http://r.789695.n4.nabble.com/PGLM-Package-Starting-Values-for-Within-Model-tp4666739.html Sent from the R help mailing list archive at Nabble.com...
2012 May 15
6
Curva dosis-respuesta
Buenos dias R-help-es, Estoy interesado en estimar una curva dosis-respuesta para un conjunto de datos y para ello, estoy utilizando la libreria "drm". Hasta ahi todo bien. Me gustaria automatizar algunas cosas y el primer paso para ello es la estimacion del modelo. Si la estimacion funciona, todo lo demas funciona; de lo contrario, todo fallara. Tengo algunas lineas que mitigan un
2008 Nov 23
0
why this function give error message
...lik -l } par0<- c(0.008134136, 0.005701749, 0.084139263, -0.039, 0.210580086, 0.038085728, 0.103540999, 0.8355774957, 0.00, 0.001, 0.001, 0.001, 0.070029653, -0.386212925, -0.073624190, -0.232775269, -0.253785415, 0.117517450) a<-nlm(garch.gjr.d,par0,y=y,X=X,Z=X,hessian=TRUE, iterlim=200) se <- sqrt(diag(solve(a$hessian))) a$estimate 2*(1-pnorm(abs(a$estimate/se))) ################ # # To get estimated variance and residuals# # ############### garch.gjr.d0 <- function(par,y,X=0,Z=0,iterate=TRUE) { T<-length(y) mu0<-par[1] g1<-par[2] g2<-par[3] g3<-p...