1
votes

All papers about spectral clustering use similarity matrix as the input to spectral clustering algorithm.

Is it also possible to use pairwise distance matrix? I haven't seen any version of spectral clustering code which would use parwise distance. I am implementing spectral clustering in matlab and it has the function pdist and the output of this function is pairwise distance matrix.

1

1 Answers

1
votes

Similarity or Affinity Matrix gives an idea about the closeness of these data points with respect to each other. Distance on the other hand gives the measure of dis-similarity w.r.t each other. The easiest and most frequently used way of using pairwise distances for Similarity Matrix is to use a Gaussian kernel to get the affinity measure.

For points a and b, let D = pdist(a,b) give you the pairwise distance. Then the similarity for your matrix can be obtained as sim_ab = exp-(D/f) where f is a scaling factor.