I am using R 3.6.1, RStudio 1.2.5019 and mlr 2.15.0. Mlr ist installed and loaded. Only mlr and the packages mlr is built on are loaded.
Now, I have trained a model using train
and would like to test it on new data.
Therefore, I want to use the predict.WrappedModel
function from mlr.
If I call
?predict.WrappedModel
I get all the information in the help window.
However, if I want to run predict.WrappedModel
R throws an error indicating that the function cannot be found:
my_test = predict.WrappedModel(object = my_model, task = my_task)
konnte Funktion "predict.WrappedModel" nicht finden
Even when specifying mlr as the package to look in for the function:
my_test = mlr::predict.WrappedModel(object = my_model, task = my_task)
Fehler: 'predict.WrappedModel' ist kein von 'namespace:mlr' exportiertes Objekt
I also tried using ?predict
, but here I also got an error:
my_test = mlr::predict(object = my_model, task = my_task)
Fehler: 'predict' ist kein von 'namespace:mlr' exportiertes Objekt
I've already spent a lot of time trying to fix this issue and read all the related questions I had found here and on the mlr forum on github, but could not find a solution.
What am I missing here?
Thanks a lot in advance :)