aboutsummaryrefslogtreecommitdiff
path: root/R/predict.gensvm.R
diff options
context:
space:
mode:
Diffstat (limited to 'R/predict.gensvm.R')
-rw-r--r--R/predict.gensvm.R6
1 files changed, 3 insertions, 3 deletions
diff --git a/R/predict.gensvm.R b/R/predict.gensvm.R
index 133b40e..558f80b 100644
--- a/R/predict.gensvm.R
+++ b/R/predict.gensvm.R
@@ -54,7 +54,7 @@ predict.gensvm <- function(fit, x.test, ...)
if (ncol(x.test) != fit$n.features) {
cat("Error: Number of features of fitted model and testing",
"data disagree.\n")
- return(NULL)
+ invisible(NULL)
}
x.train <- fit$X.train
@@ -62,12 +62,12 @@ predict.gensvm <- function(fit, x.test, ...)
cat("Error: The training data is needed to compute predictions for ",
"nonlinear GenSVM. This data is not present in the fitted ",
"model!\n", sep="")
- return(NULL)
+ invisible(NULL)
}
if (!is.null(x.train) && ncol(x.train) != fit$n.features) {
cat("Error: Number of features of fitted model and training",
"data disagree.\n")
- return(NULL)
+ invisible(NULL)
}
if (fit$kernel == 'linear') {