search for: kmsnc2

Displaying 1 result from an estimated 1 matches for "kmsnc2".

Did you mean: amsdc2
2012 Jun 27
1
Error: figure margins too large
...clusters wss <- (nrow(mydataSNc)-1)*sum(apply(mydataSNc,2,var)) for (i in 2:15) wss[i] <- sum(kmeans(mydataSNc, centers=i)$withinss) plot(1:15, wss, type="b", xlab="Number of Clusters",ylab="Within groups sum of squares") #perform Kmeans with 2 clusters kmSNc2 <- kmeans(mydataSNc,2) #print conponents of kmSNc2 print(kmSNc2) #plot 2 clusters plot(mydataSNc, col = kmSNc2$cluster) #plot 2 centers points(kmSNc2$centers,col = 1:2, pch = 8) After the above bolded code, I get this following error: > #plot 2 clusters > plot(mydataSNc, col = k...