R/predict.cv.relaxnet.R

################################################################################

predict.cv.relaxnet <- function(object,
                                newx,
                                which.model = object$which.model.min,
                                s = object$overall.lambda.min,
                                type = c("link", "response", "coefficients",
                                         "nonzero", "class"),
                                exact = FALSE,
                                ...) {

  type = match.arg(type)

  if(!identical(exact, FALSE))
    stop("In this version, only exact = FALSE has been implemented")
  
  predict(object$relaxnet.fit,
          newx,
          which.model,
          s,
          type,
          exact,
          ...)
  
}

Try the relaxnet package in your browser

Any scripts or data that you put into this service are public.

relaxnet documentation built on May 2, 2019, 12:39 p.m.