我正在尝试使用我的数据集来绘制类似于此示例的聚类分析:
Why is the line of wss-plot (for optimizing the cluster analysis) looks so fluctuated?
使用之前的相关主题(How to draw the plot of within-cluster sum-of-squares for a cluster?)
当我按照线程的确切代码(Iris示例或询问问题的示例数据的人)时,我在尝试绘制输出时出错: " xy.coords(x,y,xlabel,ylabel,log)中的错误:( list)对象无法强制键入' double' "
我能想到的唯一错误就是换行功能可能无法正常工作。当我第一次尝试执行时,代码换行无法识别,因此我安装了ggally包,然后使用了示例代码中提供的wrap函数。
任何帮助都会受到赞赏,因为我觉得我有一些明显而简单的修复方法。