# NOT RUN {
data(iris)
obj <- tune_wsvm(Species~., weight = c(rep(0.8, 50),rep(1,100)),
data = iris, ranges = list(gamma = 2^(-1:1), cost = 2^(2:4)),
tunecontrol = tune.control(sampling = "fix"))
# }
# NOT RUN {
set.seed(11)
obj <- tune_wsvm(Species~., weight = c(rep(1, 52),rep(0,98)),
data = iris, use_zero_weight = TRUE,
ranges = list(gamma = 2^(-1:1), cost = 2^(2:4)),
tunecontrol = tune.control(sampling = "bootstrap"))
# }
# NOT RUN {
summary(obj)
plot(obj, transform.x = log2, transform.y = log2)
plot(obj, type = "perspective", theta = 120, phi = 45)
best.tune_wsvm(Species~.,weight = c(rep(0.08, 50),rep(1,100)),
data = iris, ranges = list(gamma = 2^(-1:1), cost = 2^(2:4)),
tunecontrol = tune.control(sampling = "fix"))
# }
Run the code above in your browser using DataLab