| cla_bagging | R Documentation |
Bagging classifier using ipred::bagging.
cla_bagging(attribute, nbagg = 25)
attribute |
target attribute name |
nbagg |
number of bootstrap aggregations |
returns a cla_bagging object
if (requireNamespace("ipred", quietly = TRUE)) {
data(iris)
model <- cla_bagging("Species", nbagg = 25)
model <- fit(model, iris)
pred <- predict(model, iris)
table(pred, iris$Species)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.