我有一个161X911的数据矩阵,其中包含0、1、2以及一些NaN值。我尝试对该数据运行内置函数 kmeans,但是当我设置K(聚类数)大于5时,它会返回以下结果:
Warning: Ignoring rows of X with missing data.
> In kmeans at 128
??? Error using ==> kmeans at 284
X must have more rows than the number of clusters.
有没有办法绕过这个问题?我猜只有5行中没有任何NaN。