
getLamb(g, tet, x, type = c('EL','ET','CUE'), tol_lam = 1e-12, maxiterlam = 1000, tol_obj = 1e-7, k = 1)
tol_lam
tol_obj
. It helps the gel
algorithm to select the right space to look for $\theta$conv_mes
: A message with details about the convergence.Smith, R.J. (2004), GEL Criteria for Moment Condition Models. Working paper, CEMMAP.
g <- function(tet,x)
{
n <- nrow(x)
u <- (x[7:n] - tet[1] - tet[2]*x[6:(n-1)] - tet[3]*x[5:(n-2)])
f <- cbind(u, u*x[4:(n-3)], u*x[3:(n-4)], u*x[2:(n-5)], u*x[1:(n-6)])
return(f)
}
n = 500
phi<-c(.2, .7)
thet <- 0.2
sd <- .2
x <- matrix(arima.sim(n = n, list(order = c(2, 0, 1), ar = phi, ma = thet, sd = sd)), ncol = 1)
getLamb(g, c(0, phi), x, type = "EL")
Run the code above in your browser using DataLab