2020
09-23
09-23
利用python画出AUC曲线的实例
以load_breast_cancer数据集为例,模型细节不重要,重点是画AUC的代码。直接上代码:fromsklearn.datasetsimportload_breast_cancerfromsklearnimportmetricsfromsklearn.ensembleimportRandomForestClassifierfromsklearn.model_selectionimporttrain_test_splitimportpylabaspltimportwarnings;warnings.filterwarnings('ignore')dataset=load_breast_cancer()data=dataset.datatarget=dataset.targetX_tr...
继续阅读 >