【发布时间】:2015-03-11 04:24:00
【问题描述】:
我使用 RandomForest 来解决回归问题。我使用importance(rf,type=1) 来获取变量的%IncMSE,其中一个变量的%IncMSE 为负。这是否意味着这个变量对模型不利?我在互联网上搜索了一些答案,但没有找到明确的答案。
我还在模型摘要中发现了一些奇怪的东西(附在下面),虽然我将ntrees定义为800,但似乎只使用了一棵树。
型号:
rf<-randomForest(var1~va2+var3+..+var35,data=d7depo,ntree=800,keep.forest=FALSE, importance=TRUE)
summary(rf)
Length Class Mode
call 6 -none- call
type 1 -none- character
predicted 26917 -none- numeric
mse 800 -none- numeric
rsq 800 -none- numeric
oob.times 26917 -none- numeric
importance 70 -none- numeric
importanceSD 35 -none- numeric
localImportance 0 -none- NULL
proximity 0 -none- NULL
ntree 1 -none- numeric
mtry 1 -none- numeric
forest 0 -none- NULL
coefs 0 -none- NULL
y 26917 -none- numeric
test 0 -none- NULL
inbag 0 -none- NULL
terms 3 terms call
【问题讨论】:
标签: r statistics random-forest prediction