[Gmm-commits] r60 - in pkg: gmm gmm/R gmm/man gmmExtra/R gmmExtra/man

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Mon Aug 20 19:56:42 CEST 2012


Author: chaussep
Date: 2012-08-20 19:56:42 +0200 (Mon, 20 Aug 2012)
New Revision: 60

Modified:
   pkg/gmm/DESCRIPTION
   pkg/gmm/NEWS
   pkg/gmm/R/FinRes.R
   pkg/gmm/R/getModel.R
   pkg/gmm/R/gmm.R
   pkg/gmm/R/momentEstim.R
   pkg/gmm/man/gmm.Rd
   pkg/gmmExtra/R/KConfig.R
   pkg/gmmExtra/man/KConfid.Rd
Log:
Added an option to gmm(), see NEWS

Modified: pkg/gmm/DESCRIPTION
===================================================================
--- pkg/gmm/DESCRIPTION	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmm/DESCRIPTION	2012-08-20 17:56:42 UTC (rev 60)
@@ -1,6 +1,6 @@
 Package: gmm
-Version: 1.4-2
-Date: 2012-05-30
+Version: 1.4-3
+Date: 2012-07-02
 Title: Generalized Method of Moments and Generalized Empirical
         Likelihood
 Author: Pierre Chausse <pchausse at uwaterloo.ca>

Modified: pkg/gmm/NEWS
===================================================================
--- pkg/gmm/NEWS	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmm/NEWS	2012-08-20 17:56:42 UTC (rev 60)
@@ -1,3 +1,9 @@
+Changes in version 1.4-3
+
+o Added the option "constrOptim" to optfct for nonlinear models
+o Added the option "eqConstFullVcov" to gmm() to allow the computation the covariance matrix of all coefficients including 
+  the constrained ones (see ?gmm for details and examples).
+
 Changes in version 1.4-2
 
 o Bugs fixed when running gel() with smooth=T and g() begina nonlinear function

Modified: pkg/gmm/R/FinRes.R
===================================================================
--- pkg/gmm/R/FinRes.R	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmm/R/FinRes.R	2012-08-20 17:56:42 UTC (rev 60)
@@ -24,6 +24,39 @@
   x <- z$dat
   n <- ifelse(is.null(nrow(z$gt)),length(z$gt),nrow(z$gt))
 
+  if (!is.null(attr(x,"eqConst")) & P$allArg$eqConstFullVcov)
+	{
+	eqConst <- attr(x,"eqConst")$eqConst
+	coef <- rep(0,length(eqConst[,1])+length(z$coefficients))
+	ncoef <- rep("",length(eqConst[,1])+length(z$coefficients))
+	coef[-eqConst[,1]] <- z$coefficients
+	ncoef[-eqConst[,1]] <- names(z$coefficients)
+	coef[eqConst[,1]] <- eqConst[,2]
+	ncoef[eqConst[,1]] <- rownames(eqConst)
+	names(coef) <- ncoef
+	z$coefficients <- coef
+	if (!is.null(z$initTheta))
+		{
+		initTheta <- rep(0,length(z$coefficients))
+		initTheta[eqConst[,1]] <- eqConst[,2]
+		initTheta[-eqConst[,1]] <- z$initTheta
+		z$initTheta <- initTheta
+		}
+	z$df <- z$df+nrow(eqConst)
+	z$k <- z$k2+nrow(eqConst)
+	z$k2 <- z$k+nrow(eqConst)
+	z$gradv <- attr(x,"eqConst")$unConstgradv
+	z$g <- attr(x,"eqConst")$unConstg 
+	z$specMod <- paste(z$specMod, "** Note: Covariance matrix computed for all coefficients based on restricted values **\n\n")
+	}  
+	
+  if (length(as.list(args(z$gradv))) == 2)
+        z$G <- z$gradv(x)
+  else if (length(as.list(args(z$gradv))) == 3)
+	z$G <- z$gradv(z$coefficients, x)
+  else
+        z$G <- z$gradv(z$coefficients, x, g = z$g)
+
   G <- z$G
   iid <- z$iid 	
 

Modified: pkg/gmm/R/getModel.R
===================================================================
--- pkg/gmm/R/getModel.R	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmm/R/getModel.R	2012-08-20 17:56:42 UTC (rev 60)
@@ -67,7 +67,7 @@
 	      k <- ncol(x)
 	      ny <- 1
 	      dat$x <- cbind(y,x,dat$x[, dat$ny+dat$k+(1:nh)])
-	      dgb <- -(t(x[,(ny+k+1):(ny+k+nh)]) %*% x[,(ny+1):(ny+k)]) %x% diag(rep(1,ny))/nrow(x)
+	      dgb <- -(t(dat$x[,(ny+k+1):(ny+k+nh)]) %*% dat$x[,(ny+1):(ny+k)]) %x% diag(rep(1,ny))/nrow(x)
 	      return(dgb)
 	      }
 	attr(obj$x,"eqConst") <- list(unConstg = obj$g2, unConstgradv = obj$gradv2, eqConst = object$eqConst, 
@@ -100,6 +100,8 @@
 			attr(dat,"eqConst")$unConstgradv(tet2, dat)[,-resTet[,1]]
 		}
 	}
+  
+  obj$eqConst <- object$eqConst
   obj$namesCoef <- obj$namesCoef[-object$eqConst[,1]]
   obj$type <- paste(obj$type,"(with equality constraints)",sep=" ")	
   mess <- paste(rownames(object$eqConst), " = " , object$eqConst[,2], "\n",collapse="")

Modified: pkg/gmm/R/gmm.R
===================================================================
--- pkg/gmm/R/gmm.R	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmm/R/gmm.R	2012-08-20 17:56:42 UTC (rev 60)
@@ -13,8 +13,9 @@
 
 gmm <- function(g,x,t0=NULL,gradv=NULL, type=c("twoStep","cue","iterative"), wmatrix = c("optimal","ident"),  vcov=c("HAC","iid","TrueFixed"), 
 	      kernel=c("Quadratic Spectral","Truncated", "Bartlett", "Parzen", "Tukey-Hanning"),crit=10e-7,bw = bwAndrews, 
-	      prewhite = FALSE, ar.method = "ols", approx="AR(1)",tol = 1e-7, itermax=100,optfct=c("optim","optimize","nlminb"),
-	      model=TRUE, X=FALSE, Y=FALSE, TypeGmm = "baseGmm", centeredVcov = TRUE, weightsMatrix = NULL, traceIter = FALSE, data, eqConst = NULL, ...)
+	      prewhite = FALSE, ar.method = "ols", approx="AR(1)",tol = 1e-7, itermax=100,optfct=c("optim","optimize","nlminb", "constrOptim"),
+	      model=TRUE, X=FALSE, Y=FALSE, TypeGmm = "baseGmm", centeredVcov = TRUE, weightsMatrix = NULL, traceIter = FALSE, data, eqConst = NULL, 
+	      eqConstFullVcov = FALSE, ...)
 {
 
 type <- match.arg(type)
@@ -35,8 +36,9 @@
 	data<-NULL
 all_args<-list(data = data, g = g, x = x, t0 = t0, gradv = gradv, type = type, wmatrix = wmatrix, vcov = vcov, kernel = kernel,
                    crit = crit, bw = bw, prewhite = prewhite, ar.method = ar.method, approx = approx, 
-                   weightsMatrix = weightsMatrix, centeredVcov = centeredVcov,
-                   tol = tol, itermax = itermax, optfct = optfct, model = model, X = X, Y = Y, call = match.call(), traceIter = traceIter, eqConst = eqConst)
+                   weightsMatrix = weightsMatrix, centeredVcov = centeredVcov, tol = tol, itermax = itermax, 
+		   optfct = optfct, model = model, X = X, Y = Y, call = match.call(), traceIter = traceIter, 
+		   eqConst = eqConst, eqConstFullVcov = eqConstFullVcov)
 class(all_args)<-TypeGmm
 Model_info<-getModel(all_args, ...)
 z <- momentEstim(Model_info, ...)

Modified: pkg/gmm/R/momentEstim.R
===================================================================
--- pkg/gmm/R/momentEstim.R	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmm/R/momentEstim.R	2012-08-20 17:56:42 UTC (rev 60)
@@ -55,10 +55,24 @@
       allArgOptim <- list(par = P$t0, fn = .obj1, gr = gr2, x = P$x, w = w, gf = P$g, INV = TRUE)
       allArgOptim <- c(allArgOptim,argDots)
       res <- do.call(optim,allArgOptim)
-      }
-    else
+      } else {
       res <- optim(P$t0, .obj1, x = P$x, w = w, gf = P$g, ...)
+	}
     }
+  if (P$optfct == "constrOptim")
+	{
+	if (!any(c("ui","ci") %in% names(list(...))))
+		stop("You must specify ui and ci when optfct is set to constrOptim")
+	argDots <- list(...)
+	ui <- argDots$ui
+	ci <- argDots$ci
+	argDots$ui <- NULL
+	argDots$ci <- NULL
+      	allArgOptim <- list(theta = P$t0, f = .obj1, grad = NULL, ui = ui, ci = ci, x = P$x, w = w, gf = P$g, INV = TRUE)
+        allArgOptim <- c(allArgOptim,argDots)
+	res <- do.call(constrOptim,allArgOptim)
+	}
+
   if (P$optfct == "nlminb")
     {
     res <- nlminb(P$t0, .obj1, x = P$x, w = w, gf = P$g, ...)
@@ -114,7 +128,19 @@
       else
         res2 <- optim(P$t0, .obj1, x = P$x, w = w, gf = P$g, ...)
       }
-
+  if (P$optfct == "constrOptim")
+	{
+	if (!any(c("ui","ci") %in% names(list(...))))
+		stop("You must specify ui and ci when optfct is set to constrOptim")
+	argDots <- list(...)
+	ui <- argDots$ui
+	ci <- argDots$ci
+	argDots$ui <- NULL
+	argDots$ci <- NULL
+      	allArgOptim <- list(theta = P$t0, f = .obj1, grad = NULL, ui = ui, ci = ci, x = P$x, w = w, gf = P$g, INV = TRUE)
+        allArgOptim <- c(allArgOptim,argDots)
+	res2 <- do.call(constrOptim,allArgOptim)
+	}
     if (P$optfct == "nlminb")
       {
       res2 <- nlminb(P$t0, .obj1, x = P$x, w = w, gf = P$g, ...)
@@ -135,11 +161,6 @@
 	z$algoInfo <- list(convergence = res2$convergence, counts = res2$evaluations, message = res2$message)
     }
 
- if (length(as.list(args(P$gradv))) == 3)
-	    z$G <- P$gradv(z$coefficients, P$x)
- else
-	    z$G <- P$gradv(z$coefficients, P$x, g = P$g)
-
   z$dat <- P$x
   z$gt <- P$g(z$coefficients, P$x)
   z$gradv <- P$gradv
@@ -207,7 +228,6 @@
   z$gradv <- P$gradv
   z$iid <- P$iid
   z$g <- P$g
-  z$G <- P$gradv(dat) 
   z$WSpec <- P$WSpec
   z$w0 <- w
 
@@ -284,7 +304,6 @@
   z$gradv <- P$gradv
   z$iid <- P$iid
   z$g <- P$g
-  z$G <- P$gradv(dat) 
   z$WSpec <- P$WSpec
   z$w0 <- w
 
@@ -339,7 +358,20 @@
     else
       res <- optim(P$t0, .obj1, x = P$x, w = w, gf = P$g, ...)
     }
-    
+ if (P$optfct == "constrOptim")
+    {
+	if (!any(c("ui","ci") %in% names(list(...))))
+		stop("You must specify ui and ci when optfct is set to constrOptim")
+	argDots <- list(...)
+	ui <- argDots$ui
+	ci <- argDots$ci
+	argDots$ui <- NULL
+	argDots$ci <- NULL
+      	allArgOptim <- list(theta = P$t0, f = .obj1, grad = NULL, ui = ui, ci = ci, x = P$x, w = w, gf = P$g, INV = TRUE)
+        allArgOptim <- c(allArgOptim,argDots)
+	res <- do.call(constrOptim,allArgOptim)
+    }
+ 
   if (P$optfct == "nlminb")
     {
     res <- nlminb(P$t0, .obj1, x = P$x, w = w, gf = P$g, ...)
@@ -403,7 +435,19 @@
         else
           res <- optim(tet, .obj1, x = P$x, w = w, gf = P$g, ...)
         }
-
+      if (P$optfct == "constrOptim")
+        {
+	if (!any(c("ui","ci") %in% names(list(...))))
+		stop("You must specify ui and ci when optfct is set to constrOptim")
+	argDots <- list(...)
+	ui <- argDots$ui
+	ci <- argDots$ci
+	argDots$ui <- NULL
+	argDots$ci <- NULL
+      	allArgOptim <- list(theta = tet, f = .obj1, grad = NULL, ui = ui, ci = ci, x = P$x, w = w, gf = P$g, INV = TRUE)
+        allArgOptim <- c(allArgOptim,argDots)
+	res <- do.call(constrOptim,allArgOptim)
+        }
       if (P$optfct == "nlminb")
         {
         res <- nlminb(tet, .obj1, x = P$x, w = w, gf = P$g, ...)
@@ -433,12 +477,6 @@
 
     }
 
-  
- if (length(as.list(args(P$gradv))) == 3)
-	    z$G <- P$gradv(z$coefficients, P$x)
- else
-	    z$G <- P$gradv(z$coefficients, P$x, g = P$g)
-
   z$dat <- P$x
   z$gt <- P$g(z$coefficients, P$x)
   z$gradv <- P$gradv
@@ -495,6 +533,19 @@
 
     if (P$optfct == "optim")
       res2 <- optim(P$t0,.objCue, x = dat, P = P, ...)
+    if (P$optfct == "constrOptim")
+      {
+	if (!any(c("ui","ci") %in% names(list(...))))
+		stop("You must specify ui and ci when optfct is set to constrOptim")
+	argDots <- list(...)
+	ui <- argDots$ui
+	ci <- argDots$ci
+	argDots$ui <- NULL
+	argDots$ci <- NULL
+      	allArgOptim <- list(theta = P$t0, f = .objCue, grad = NULL, ui = ui, ci = ci, x = dat, P = P)
+        allArgOptim <- c(allArgOptim,argDots)
+	res <- do.call(constrOptim,allArgOptim)
+      }
     if (P$optfct == "nlminb")
       {
       res2 <- nlminb(P$t0,.objCue, x = dat, P = P, ...)
@@ -529,7 +580,6 @@
   z$gradv <- P$gradv
   z$iid <- P$iid
   z$g <- P$g
-  z$G <- P$gradv(dat) 
   z$specMod <- P$specMod
   z$cue <- list(weights=P$fixedKernW,message=P$weightMessage)
   z$WSpec <- P$WSpec
@@ -579,6 +629,19 @@
       {
       res2 <- optim(P$t0, .objCue, x = x, P = P, ...)
       }
+   if (P$optfct == "constrOptim")
+      {
+	if (!any(c("ui","ci") %in% names(list(...))))
+		stop("You must specify ui and ci when optfct is set to constrOptim")
+	argDots <- list(...)
+	ui <- argDots$ui
+	ci <- argDots$ci
+	argDots$ui <- NULL
+	argDots$ci <- NULL
+      	allArgOptim <- list(theta = P$t0, f = .objCue, grad = NULL, ui = ui, ci = ci, x = x, P = P)
+        allArgOptim <- c(allArgOptim,argDots)
+	res2 <- do.call(constrOptim,allArgOptim)
+      }
     if (P$optfct == "nlminb")
       {
       res2 <- nlminb(P$t0, .objCue, x = x, P = P, ...)
@@ -598,11 +661,6 @@
 
     }
 
-  if (length(as.list(args(P$gradv))) == 3)
-	    z$G <- P$gradv(z$coefficients, P$x)
-  else
-	    z$G <- P$gradv(z$coefficients, P$x, g = P$g)
-
   z$dat <- P$x
   z$gradv <- P$gradv
   z$gt <- P$g(z$coefficients, P$x)
@@ -857,7 +915,6 @@
   z$gradv <- P$gradv
   z$iid <- P$iid
   z$g <- P$g
-  z$G <- P$gradv(dat) 
   z$WSpec <- P$WSpec
 
   names(z$coefficients) <- P$namesCoef
@@ -941,11 +998,6 @@
   else if(P$optfct == "nlminb")
      z$algoInfo <- list(convergence = res2$convergence, counts = res2$evaluations, message = res2$message)
 
-  if (length(as.list(args(P$gradv))) == 3)
-	    z$G <- P$gradv(z$coefficients, P$x)
-  else
-	    z$G <- P$gradv(z$coefficients, P$x, g = P$g)
-
   z$dat <- P$x
   z$gt <- P$g(z$coefficients, P$x)
   z$gradv <- P$gradv

Modified: pkg/gmm/man/gmm.Rd
===================================================================
--- pkg/gmm/man/gmm.Rd	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmm/man/gmm.Rd	2012-08-20 17:56:42 UTC (rev 60)
@@ -9,13 +9,11 @@
  Function to estimate a vector of parameters based on moment conditions using the GMM method of Hansen(82). 
 }
 \usage{
-gmm(g, x, t0 = NULL, gradv = NULL, type = c("twoStep","cue","iterative"), 
-wmatrix = c("optimal","ident"), vcov = c("HAC","iid","TrueFixed"), 
-kernel = c("Quadratic Spectral","Truncated", "Bartlett", 
-"Parzen", "Tukey-Hanning"), crit = 10e-7, bw = bwAndrews, 
-prewhite = FALSE, ar.method = "ols", approx = "AR(1)", tol = 1e-7, 
-itermax = 100, optfct = c("optim","optimize","nlminb"), model=TRUE, X=FALSE, Y=FALSE, 
-TypeGmm = "baseGmm", centeredVcov = TRUE, weightsMatrix = NULL, traceIter = FALSE, data, eqConst = NULL, ...)
+gmm(g,x,t0=NULL,gradv=NULL, type=c("twoStep","cue","iterative"), wmatrix = c("optimal","ident"),  vcov=c("HAC","iid","TrueFixed"),
+kernel=c("Quadratic Spectral","Truncated", "Bartlett", "Parzen", "Tukey-Hanning"),crit=10e-7,bw = bwAndrews,
+prewhite = FALSE, ar.method = "ols", approx="AR(1)",tol = 1e-7, itermax=100,optfct=c("optim","optimize","nlminb", "constrOptim"),
+model=TRUE, X=FALSE, Y=FALSE, TypeGmm = "baseGmm", centeredVcov = TRUE, weightsMatrix = NULL, traceIter = FALSE, data, eqConst = NULL, 
+eqConstFullVcov = FALSE, ...)
 gmmWithConst(obj, which, value)
 }
 \arguments{
@@ -49,7 +47,7 @@
 
 \item{itermax}{The maximum number of iterations for the iterative GMM. It is unlikely that the algorithm does not converge but we keep it as a safety.}
 
-\item{optfct}{Only when the dimension of \eqn{\theta} is 1, you can choose between the algorithm \code{\link{optim}} or \code{\link{optimize}}. In that case, the former is unreliable. If \code{\link{optimize}} is chosen, "t0" must be \eqn{1\times 2} which represents the interval in which the algorithm seeks the solution. It is also possible to choose the \code{\link{nlminb}} algorithm. In that case, boundaries for the coefficients can be set by the options \code{upper=} and \code{lower=}.}
+\item{optfct}{Only when the dimension of \eqn{\theta} is 1, you can choose between the algorithm \code{\link{optim}} or \code{\link{optimize}}. In that case, the former is unreliable. If \code{\link{optimize}} is chosen, "t0" must be \eqn{1\times 2} which represents the interval in which the algorithm seeks the solution. It is also possible to choose the \code{\link{nlminb}} algorithm. In that case, boundaries for the coefficients can be set by the options \code{upper=} and \code{lower=}. The \code{\link{constrOptim}} is only available for nonlinear models for now. The standard errors may have to be corrected if the estimtes reach the boundary set by ui and ci.}
 
 \item{model, X, Y}{logical.  If \code{TRUE} the corresponding components of the fit (the model frame, the model matrix, the response) are returned if g is a formula.}
 
@@ -69,6 +67,8 @@
 
 \item{obj}{Object of class "gmm"}
 
+\item{eqConstFullVcov}{If FALSE, the constrained coefficients are assumed to be fixed and only the covariance of the unconstrained coefficients is computed. If TRUE, the covariance matrix of the full set of coefficients is computed.}
+
 \item{...}{More options to give to \code{\link{optim}}.}
 }
 
@@ -277,14 +277,14 @@
 # Brent should be used
 
 # without named vector
-gmm(g, x, c(4, 0), grad = Dg, eqCons=1)
+gmm(g, x, c(4, 0), grad = Dg, eqConst=1)
 # with named vector
-gmm(g, x, c(mu=4, sig=2), grad = Dg, eqCons="sig")
+gmm(g, x, c(mu=4, sig=2), grad = Dg, eqConst="sig")
 
 ## End(Not run)
 
-gmm(g, x, c(4, 0), grad = Dg, eqCons=1,method="Brent",lower=0,upper=6)
-gmm(g, x, c(mu=4, sig=2), grad = Dg, eqCons="sig",method="Brent",lower=0,upper=6)
+gmm(g, x, c(4, 0), grad = Dg, eqConst=1,method="Brent",lower=0,upper=6)
+gmm(g, x, c(mu=4, sig=2), grad = Dg, eqConst="sig",method="Brent",lower=0,upper=6)
 
 # Example with formula
 # first coef = 0 and second coef = 1
@@ -299,6 +299,15 @@
 res3 <- gmm(z ~ f1 + f2 + f3, ~ f1 + f2 + f3, t0=c(0,1,.5,.5), type="cue", eqConst = c(1,2))
 res3
 
+### Examples with equality constraints, where the constrained coefficients is used to compute the covariance matrix.
+### Useful when some coefficients have been estimated before, they are just identified in GMM and don't need to be re-estimated
+### To use with caution because the covariance won't be valid if the coefficients do not solve the GMM FOC.
+######################################
+
+res4 <- gmm(z ~ f1 + f2 + f3, ~ f1 + f2 + f3, t0=c(0,1,.5,.5), eqConst = c(1,2), eqConstFullVcov=TRUE)
+summary(res4)
+
+
 ### Examples with equality constraint using gmmWithConst
 ###########################################################
 

Modified: pkg/gmmExtra/R/KConfig.R
===================================================================
--- pkg/gmmExtra/R/KConfig.R	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmmExtra/R/KConfig.R	2012-08-20 17:56:42 UTC (rev 60)
@@ -44,13 +44,13 @@
 		test <- KTest(res)
 		if (type == "K")
 		   {
-		      ifelse(alpha > test$test[1,2], 1, -1)
+		      test$test[1,2]-alpha
 		   } else {
 		      if (test$test[2,2]<alphaJ) 
 		         {
-			    return(1)
+			    test$test[2,2] - alphaJ
 			 } else {
- 			    ifelse(test$test[1,2]<alphaK, 1, -1) 
+ 			    test$test[1,2] - alphaK
 			 }
 		   }	
 	}
@@ -109,13 +109,15 @@
 	# get the four points of the cross
 	selectf <- list(f,f,f2,f2)
 	selectd <- c(1,-1,1,-1)
-	xy12 <- theApply(1:4, function(i) try(uniroot(selectf[[i]],c(x0,x0+selectd[i]*b[1]),y0=y0,tol=tol)$root,silent=TRUE))
+	xy12 <- theApply(1:2, function(i) try(uniroot(selectf[[i]],c(x0,x0+selectd[i]*b[1]),y0=y0,tol=tol)$root,silent=TRUE))
+	xy34 <- theApply(3:4, function(i) try(uniroot(selectf[[i]],c(y0,y0+selectd[i]*b[2]),y0=x0,tol=tol)$root,silent=TRUE))
 
 	x1 <- xy12[[1]]
 	x2 <- xy12[[2]]
-	y1 <- xy12[[3]]
-	y2 <- xy12[[4]]
+	y1 <- xy34[[1]]
+	y2 <- xy34[[2]]
 
+print(c(x1,x2,y1,y2))
 	getAll <- function(lambda, dir=1, x)
 		{
 		yi <- y1*lambda + y0*(1-lambda)

Modified: pkg/gmmExtra/man/KConfid.Rd
===================================================================
--- pkg/gmmExtra/man/KConfid.Rd	2012-05-30 18:38:41 UTC (rev 59)
+++ pkg/gmmExtra/man/KConfid.Rd	2012-08-20 17:56:42 UTC (rev 60)
@@ -8,7 +8,7 @@
 KConfid(obj, which, type = c("K", "KJ"), alpha = 0.05, alphaJ = 0.01, n = 4)
 }
 \arguments{
- \item{obj}{Object of class "gmm" returned by \code{\link{gmm}} (not restricted)}
+ \item{obj}{Object of class "gmm" returned by \link{gmm} (not restricted)}
  \item{type}{Should we base the confidence interval on the K or K-J statistics.}
  \item{which}{A 2x1 vector or a scalar. The interval is computed for \code{coef(obj)[which]}. }
  \item{alpha, alphaJ}{The overall size and the size for the J-test when type is "KS".}



More information about the Gmm-commits mailing list