How to display the row name in K means cluster plot in R?

前端 未结 1 1429
醉梦人生
醉梦人生 2021-01-22 06:54

I am trying to plot the K-means cluster. The below is the code i use.

library(cluster)
library(fpc)

data(iris)
dat <- iris[, -5] # without known classificati         


        
相关标签:
1条回答
  • 2021-01-22 07:46

    for me it worked, when you rename the row names in a way like row.names(dat) <- paste("flower",row.names(dat)). This means if your row names are in the way you want them to be, they'll be properly displayed.

    Hope that'll help!

    0 讨论(0)
提交回复
热议问题