Extra Learners for mlr3
This mlr3 extension contains all mlr3 learners that are not in
mlr3learners or the core packages. Besides, it contains helper functions to list all learners from the mlr3verse and install their required packages. See the interactive learner list for the full list of learners in the mlr3verse.
list_mlr3learners(select = c("id", "mlr3_package", "required_packages")) #> id mlr3_package required_packages #> 1: classif.AdaBoostM1 mlr3extralearners RWeka #> 2: classif.bart mlr3extralearners dbarts #> 3: classif.C50 mlr3extralearners C50 #> 4: classif.catboost mlr3extralearners catboost #> 5: classif.cforest mlr3extralearners partykit,sandwich,coin #> --- #> 128: surv.ranger mlr3learners ranger #> 129: surv.rfsrc mlr3extralearners randomForestSRC,pracma #> 130: surv.rpart mlr3proba rpart,distr6,survival #> 131: surv.svm mlr3extralearners survivalsvm #> 132: surv.xgboost mlr3learners xgboost
mlr3extralearners lives on GitHub and will not be on CRAN. This enables us to include packages such as catboost, which is not on CRAN either.
The package includes functionality for detecting if you have the required packages installed to use a learner, and ships with the function
install_learner which can install all required learner dependencies.
lrn("regr.gbm") #> Package 'gbm' required but not installed for Learner 'regr.gbm'
New learners can be created with the
create_learner function. This assumes you have a local copy of
mlr3extralearners. This function will automatically create the learner, learner tests, parameter tests and update the DESCRIPTION if required. Once all tests are passing locally, open a pull request with the “New Learner” template. More detailed instructions can be found in the mlr3 book.