Learn R Programming

bst (version 0.3-2)

cv.msvm: Cross-Validation

Description

Cross-validated estimation of the empirical multi-class hinge loss for boosting parameter selection.

Usage

cv.msvm(x, y, balance=FALSE, K = 10, cost = NULL, family = "hinge", 
learner = c("tree", "ls", "sm"), ctrl = bst_control(), 
type = c("risk","misc"), plot.it = TRUE, se = TRUE, ...)

Arguments

x
a data frame containing the variables in the model.
y
vector of responses. y must be integers from 1 to C for C class problem.
balance
logical value. If TRUE, The K parts were roughly balanced, ensuring that the classes were distributed proportionally among each of the K parts.
K
K-fold cross-validation
cost
price to pay for false positive, 0 < cost < 1; price of false negative is 1-cost.
family
family = "hinge" for hinge loss.
learner
a character specifying the component-wise base learner to be used: ls linear models, sm smoothing splines, tree regression trees.
ctrl
an object of class bst_control.
type
for family="hinge", type="risk" is hinge risk.
plot.it
a logical value, to plot the estimated risks if TRUE.
se
a logical value, to plot with standard errors.
...
additional arguments.

Value

  • object with
  • residmatempirical risks in each cross-validation at boosting iterations
  • fractionabscissa values at which CV curve should be computed.
  • cvThe CV curve at each value of fraction
  • cv.errorThe standard error of the CV curve
  • ...

See Also

msvm