I am using the elbow method, silhouette and trying to find the optimal number of k m clusters from the data. Now with most packages it gives 3 with PAM, Kmeans, clara if I consider wss (within similarity scores) or silhouette. With Hubert analysis I am getting ideally 2 clusters. Only strange things is the below command gives me a plot which to me is a bit confusing. Should I consider it as 3 clusters or 4. If anyone can give me some feedbacks here.
code used
wss <- (nrow(scale(df))-1)*sum(apply(scale(df),2,var))
for (i in 2:10) wss[i] <- sum(kmeans(scale(df),
centers=i)$withinss)
fviz_nbclust(scale(df), kmeans, method = "wss")
I am also trying to put the image so that one can tell me if it's 3 or 4 that should be the cluster number here. Ideally, I think it should be 4 since the whole point of WSS is to select the k where the SSE is more or less flat.