I have a data set that has an instance of 6497, 12 attributes and a class variable q (quality). Class values can vary from 3 to 9. Data can be downloaded in CSV format from here
I use k-mean to split data into 3 clusters
set.seed(1234)
nr <- NROW(wine$.row)
ind <- sample(nr, 0.66 * nr, replace = FALSE)
w_clus3 <- kmeans(wine[ind, 2:12], 3)
matrix3 <- table(cl_predict(w_clus3, wine[-ind,2:12 ]),wine$q[-ind])
Is there a way I can use clusplot or any other visual graph to show how the data was divided between the three clusters?
I tried, but I was getting errors.
clusplot(wine[2:12], w_clus3$cluster, color=TRUE, shade=TRUE,labels=2, lines=0)
If there are too many dimensions ... how can I just show a few attributes and how they were separated in clusters.
source
share