【发布时间】:2016-09-21 12:08:53
【问题描述】:
我正在计算一个使用 "ROC" 作为度量的 SVM-RFE 模型,使用 rfe 函数(caret 包)。据我所知,rfe 算法使用pROC 包的roc 函数及其预定义参数来优化AUC 值。但是,我想将direction 参数设置为"<" 而不是"auto",因为在某些情况下,得到的平均AUC 是反向计算的(我的数据不是很好......)。这个问题在这里的答案中有解释:Difference in average AUC computation using ROCR and pROC (R)
如何在rfe 计算中更改roc 函数的默认参数值?
我已经尝试过这个简单的选项,但它不起作用:
svmRFE_NG3 <- rfe(x = TAll[,2:50],
y = TAll[,1],
sizes = seq(1,42),
metric = "ROC",
levels = c("BREAST","LUNG"),
direction = "<",
rfeControl = FSctrl,
## Options to train()
method = "svmLinear",
tuneLength = 10,
preProc = c("center", "scale"),
## Inner resampling process
trControl = TRctrl)
【问题讨论】:
标签: r r-caret roc rfe proc-r-package