rvm function currently supports only regression.## S3 method for class 'formula':
rvm(x, data=NULL, ..., subset, na.action = na.omit)## S3 method for class 'vector':
rvm(x, ...)
## S3 method for class 'matrix':
rvm(x, y, type="regression", kernel="rbfdot", kpar="automatic",
alpha= ncol(as.matrix(x)), var=0.1, var.fix=FALSE, iterations=100, verbosity=0, tol=
.Machine$double.eps,minmaxdiff = 1e-3, cross = 0, fit =TRUE,... , subset,
na.action = na.omit)
## S3 method for class 'list':
rvm(x, y, type = "regression", kernel = "stringdot", kpar = list(length = 4, lambda = 0.5),
alpha = 5, var = 0.1, var.fix = FALSE, iterations = 100, verbosity = 0,
tol = .Machine$double.eps, minmaxdiff = 1e-3, cross = 0, fit =TRUE,
... ,subset ,na.action = na.omit)
kernelMatrix of the training data
or a list of character vectors (for use wx. Can be either
a factor (for classification tasks) or a numeric vector (for
regression).rvm can only be used for regression at the moment.
sigmainverse kernel width for the Radial NAs are
found. The default action is na.omit, which leads to rejection of cases
with missing values on any required variable. An alternative
is na.fail<fit = TRUE)ksvm
# train relevance vector machine foo <- rvm(x, y) foo # print relevance vectors alpha(foo) RVindex(foo)
# predict and plot
ytest <- predict(foo, x)
plot(x, y, type ="l")
lines(x, ytest, col="red")