R语言ROCR包 performance函数使用说明 |
您所在的位置:网站首页 › r语言performance › R语言ROCR包 performance函数使用说明 |
返回R语言ROCR包函数列表 功能\作用概述:所有类型的预测评估都使用此函数执行。 语法\用法:performance(prediction.obj, measure, x.measure = "cutoff", ...) 参数说明:prediction.obj : 阶级预测的对象。 measure : 用于评估的性能度量。可用于度量的性能度量的完整列表和x.measure在“细节”部分给出。 x.measure : 第二个绩效指标。如果与默认值不同,将创建一条二维曲线,其中x.measure为x轴方向的单位,measure为y轴方向的单位。此曲线用截止参数化。 ... : 可选参数(特定于单个性能度量)。 示例\实例:# computing a simple ROC curve (x-axis: fpr, y-axis: tpr)library(ROCR)data(ROCR.simple)pred < - prediction( ROCR.simple$predictions, ROCR.simple$labels)predperf < - performance(pred,"tpr","fpr")perfplot(perf) # precision/recall curve (x-axis: recall, y-axis: precision)perf < - performance(pred, "prec", "rec")perfplot(perf) # sensitivity/specificity curve (x-axis: specificity,# y-axis: sensitivity)perf < - performance(pred, "sens", "spec")perfplot(perf) |
今日新闻 |
推荐新闻 |
CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3 |