R/model-methods.R

setMethod(f="model",signature="MAIT",function(x,type){if(is.null(type)==TRUE){
stop("No type was specified (PCA or PLS).")
}

  out <- switch(type,
         "PCA" = pcaModel(x),
         "PLS" = plsModel(x))

  return(out)})

Try the MAIT package in your browser

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

MAIT documentation built on Nov. 8, 2020, 5:43 p.m.