图解未生成调谐模型(SVM)的热图

时间:2018-09-06 04:57:10

标签: r

我正在将R-Studio和e1071软件包用于SVM(支持向量机)。虹膜数据集是R中使用的典型数据集。

代码如下:

tune_model <-tune(svm, Species~., data=iris,
             ranges= list(epsilon= seq(0, 1, 0.1)), #epsilon= 0, 0.1, 0.2 etc
             cost=2^(2:9)) #default cost=1
                           #if cost is too high--> high penalty for non-separable points--> will use too many support vectors-->overfitting
                           #if cost is too low--> underfitting
plot(tune_model)

但是我得到了:

Tuning output

我应该得到一个热点图: enter image description here

我在做什么错了?

0 个答案:

没有答案
相关问题