From 0179fa5f3565159dd3400a89b5762f9a1ba63fd4 Mon Sep 17 00:00:00 2001 From: Gertjan van den Burg Date: Wed, 4 Apr 2018 13:34:47 -0400 Subject: Add importFrom statements --- NAMESPACE | 10 ++++++++++ R/coef.gensvm.R | 3 +++ R/coef.gensvm.grid.R | 3 +++ R/gensvm.R | 3 +++ R/gensvm.grid.R | 2 ++ R/plot.gensvm.R | 4 ++++ R/predict.gensvm.R | 5 ++++- R/predict.gensvm.grid.R | 4 ++++ man/predict.gensvm.Rd | 1 - 9 files changed, 33 insertions(+), 2 deletions(-) diff --git a/NAMESPACE b/NAMESPACE index a9bf594..43eb632 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -21,4 +21,14 @@ export(gensvm.refit) export(gensvm.train.test.split) export(gensvm.validate.param.grid) export(gensvm.validate.params) +importFrom(grDevices,rgb) +importFrom(graphics,legend) +importFrom(graphics,par) +importFrom(graphics,plot) +importFrom(graphics,polygon) +importFrom(graphics,segments) +importFrom(stats,coef) +importFrom(stats,predict) +importFrom(stats,runif) +importFrom(stats,sd) useDynLib(gensvm_wrapper, .registration = TRUE) diff --git a/R/coef.gensvm.R b/R/coef.gensvm.R index e34bba6..8f60fd4 100644 --- a/R/coef.gensvm.R +++ b/R/coef.gensvm.R @@ -26,8 +26,11 @@ #' \code{\link{predict.gensvm}}, \code{\link{gensvm-package}} #' #' @method coef gensvm +#' #' @export #' +#' @importFrom stats coef +#' #' @examples #' x <- iris[, -5] #' y <- iris[, 5] diff --git a/R/coef.gensvm.grid.R b/R/coef.gensvm.grid.R index 3765c32..48b2a76 100644 --- a/R/coef.gensvm.grid.R +++ b/R/coef.gensvm.grid.R @@ -20,8 +20,11 @@ #' \code{\link{gensvm.grid}}, \code{\link{gensvm-package}} #' #' @method coef gensvm.grid +#' #' @export #' +#' @importFrom stats coef +#' #' @examples #' x <- iris[, -5] #' y <- iris[, 5] diff --git a/R/gensvm.R b/R/gensvm.R index d59c7e0..6e73295 100644 --- a/R/gensvm.R +++ b/R/gensvm.R @@ -79,6 +79,9 @@ #' \code{\link{plot}}, \code{\link{gensvm.grid}}, \code{\link{gensvm-package}} #' #' @export +#' +#' @importFrom stats runif +#' #' @useDynLib gensvm_wrapper, .registration = TRUE #' #' @examples diff --git a/R/gensvm.grid.R b/R/gensvm.grid.R index 62add19..7be065b 100644 --- a/R/gensvm.grid.R +++ b/R/gensvm.grid.R @@ -124,6 +124,8 @@ #' #' @export #' +#' @importFrom stats sd +#' #' @examples #' x <- iris[, -5] #' y <- iris[, 5] diff --git a/R/plot.gensvm.R b/R/plot.gensvm.R index d0c1eb2..d490c1e 100644 --- a/R/plot.gensvm.R +++ b/R/plot.gensvm.R @@ -37,8 +37,12 @@ #' \code{\link{gensvm}}, \code{\link{gensvm-package}} #' #' @method plot gensvm +#' #' @export #' +#' @importFrom grDevices rgb +#' @importFrom graphics legend par plot polygon segments +#' #' @examples #' x <- iris[, -5] #' y <- iris[, 5] diff --git a/R/predict.gensvm.R b/R/predict.gensvm.R index 2cf7401..0b5fa91 100644 --- a/R/predict.gensvm.R +++ b/R/predict.gensvm.R @@ -25,8 +25,11 @@ #' \code{\link{plot.gensvm}}, \code{\link{predict.gensvm.grid}}, #' \code{\link{gensvm}}, \code{\link{gensvm-package}} #' +#' @method predict gensvm +#' #' @export -#' @aliases predict +#' +#' @importFrom stats predict #' #' @examples #' x <- iris[, -5] diff --git a/R/predict.gensvm.grid.R b/R/predict.gensvm.grid.R index 7555368..df48d76 100644 --- a/R/predict.gensvm.grid.R +++ b/R/predict.gensvm.grid.R @@ -28,8 +28,12 @@ #' \code{\link{gensvm}}, \code{\link{predict.gensvm.grid}}, #' \code{\link{plot.gensvm}}, \code{\link{gensvm-package}} #' +#' @method predict gensvm.grid +#' #' @export #' +#' @importFrom stats predict +#' #' @examples #' x <- iris[, -5] #' y <- iris[, 5] diff --git a/man/predict.gensvm.Rd b/man/predict.gensvm.Rd index 52c2395..015623f 100644 --- a/man/predict.gensvm.Rd +++ b/man/predict.gensvm.Rd @@ -2,7 +2,6 @@ % Please edit documentation in R/predict.gensvm.R \name{predict.gensvm} \alias{predict.gensvm} -\alias{predict} \title{Predict class labels with the GenSVM model} \usage{ \method{predict}{gensvm}(fit, newdata, add.rownames = FALSE, ...) -- cgit v1.2.3