rf2 <- train(variable ~.,
data,
method = "rf",
trControl =
importance = TRUE)
What is the purpose of the "importance = TRUE" argument. Is it necessary, or optional?
rf2 <- train(variable ~.,
data,
method = "rf",
trControl =
importance = TRUE)
What is the purpose of the "importance = TRUE" argument. Is it necessary, or optional?
In train an argument comes either from caret::train or from the model used in method and for which argument are passed through ...
In you can't find it as a argument of train, (in help page or the book), you can assume it is from the model.
Here method = 'rf' means randomForest from the
randomForest and importance is an argument from randomForest::randomForest. See the help page.
importanceShould importance of predictors be assessed?
It is FALSE by default.
You might already have gotten your answer from @cderv, but if you're looking for the meaning of (variable/feature) importance, check out this awesome book.
thank you!
Do we use importance = TRUE in order to use varImp(randomforest)? It looks like we can still use varImp() even if importance = FALSE.
This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.