misvm_orova | R Documentation |
This function uses the one-vs-all multiclass classification strategy to fit a series of MI-SVM models for predictions on ordinal outcome data. For an ordinal outcome with K levels, we fit K MI-SVM models to predict an individual level vs not.
## Default S3 method: misvm_orova( x, y, bags, cost = 1, method = c("heuristic", "mip", "qp-heuristic"), weights = TRUE, control = list(kernel = "linear", sigma = if (is.vector(x)) 1 else 1/ncol(x), nystrom_args = list(m = nrow(x), r = nrow(x), sampling = "random"), max_step = 500, type = "C-classification", scale = TRUE, verbose = FALSE, time_limit = 60, start = FALSE), ... ) ## S3 method for class 'formula' misvm_orova(formula, data, ...) ## S3 method for class 'mi_df' misvm_orova(x, ...)
x |
A data.frame, matrix, or similar object of covariates, where each
row represents an instance. If a |
y |
A numeric, character, or factor vector of bag labels for each
instance. Must satisfy |
bags |
A vector specifying which instance belongs to each bag. Can be a string, numeric, of factor. |
cost |
The cost parameter in SVM. If |
method |
The algorithm to use in fitting (default |
weights |
named vector, or |
control |
list of additional parameters passed to the method that control computation with the following components:
|
... |
Arguments passed to or from other methods. |
formula |
a formula with specification |
data |
If |
An object of class misvm_orova
The object contains at least the
following components:
fits
: a list of misvm
objects with length equal to the number of
classes in y
. See misvm()
for details on the misvm
object.
call_type
: A character indicating which method misvm_orova()
was
called with.
features
: The names of features used in training.
levels
: The levels of y
that are recorded for future prediction.
default
: Method for data.frame-like objects
formula
: Method for passing formula
mi_df
: Method for mi_df
objects, automatically handling bag
names, labels, and all covariates.
Sean Kent
Andrews, S., Tsochantaridis, I., & Hofmann, T. (2002). Support vector machines for multiple-instance learning. Advances in neural information processing systems, 15.
predict.misvm_orova()
for prediction on new data.
data("ordmvnorm") x <- ordmvnorm[, 3:7] y <- ordmvnorm$bag_label bags <- ordmvnorm$bag_name mdl1 <- misvm_orova(x, y, bags) predict(mdl1, x, new_bags = bags)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.