Entering edit mode
5.0 years ago
pierre.jorcin
•
0
need to do an ANOVA on a random forest model. Calling the same code I use for glm and gam models doesn't with my rf model. What code shall I use to make it work?
I am using the sdm package from R to build my rf model. The rf model runs ok, however, I can't use the ANOVA function on the results.
MRF <- sdm(presence~.,data=dM,methods='rf',replication='sub',test.percent=20)
anova(MRF)
Error in UseMethod("anova") : no applicable method for 'anova' applied to an object of class "sdmModels
I have also tried this option :
m <-MRF@models$presence$rf$1
@object
anova(m)
Error in UseMethod("anova") : no applicable method for 'anova' applied to an object of class "c('randomForest.formula', 'randomForest')"
Crossposted. Do not crosspost or at the very least link the posts.