1

How can I use the function adaboost.M1? I am testing the following codes in R. But I always have the error message: Error: could not find function "adaboost.M1". What packages do I miss? Thanks

library(rpart)
library(mlbench)
library(adabag)
data(iris)
names(iris)<-c("LS","AS","LP","AP","Especies")
iris.adaboost <- adaboost.M1(Especies~LS +AS +LP+ AP, data=iris, boos=TRUE, mfinal=10)

1 Answers1

2

Please try:

iris.adaboost <- boosting(Species~., data=iris, boos=TRUE, mfinal=10)

Seems that in newer versions of adabag package you have to use method boosting.

milos.ai
  • 3,882
  • 7
  • 31
  • 33