4
我想绘制一个多类问题的ROC曲线,使用pROC包中的multiclass.roc函数,但是我得到这个错误:'x'是一个列表,但没有组件'x'和'y'
'x' is a list, but does not have components 'x' and 'y'
这个错误是什么意思在网上搜索没有帮助我找到答案。我可以打印roc对象,但不能绘制它。
谢谢!
我想绘制一个多类问题的ROC曲线,使用pROC包中的multiclass.roc函数,但是我得到这个错误:'x'是一个列表,但没有组件'x'和'y'
'x' is a list, but does not have components 'x' and 'y'
这个错误是什么意思在网上搜索没有帮助我找到答案。我可以打印roc对象,但不能绘制它。
谢谢!
如果列表l
上呼吁plot
:plot (l)
中,x坐标将被从l$x
采取和Y从l$y
坐标。您的列表没有元素x和y。
您需要改为拨打plot (l$your.x.coordinate, l$your.y.coordinate)
。
请提供一个可重现的例子。粘贴'dput(yourdata)'的输出和产生错误的代码。 – Backlin 2012-08-17 10:28:28