I am using:
- the cluster::pam function in R for clustering
- distance matrix computed using Gower distance in cluster::daisy in R
The issue I am having is that I run pam 2 times, with a different distance matrix in each run, but I get the same cluster assignment in both runs!!
If I run PAM for each distance matrix I get different average silhouette widths as expected. So far so good. Although it is strange to get such high numbers close to 1!
The problem is the unexpeted results I get when I look at the clustering assignement in each run. Both clustering assignments give the same results! Even though the average widths are different as shown above. Can someone please explain what am I missing. How can they be different? Thanks in advance
You can see below also the scatter plot between the 2 distances. Curiously the distance in the 2nd run is one of 3 values (0 or 0.5 or 1). Any ideas why this would happen?