SOM Toolbox Online documentation http://www.cis.hut.fi/projects/somtoolbox/

som_cldist

Cd = som_cldist(D,clinds1,clinds2,cldist,q,mask)

 SOM_CLDIST Distances between two clusters.
 
   Cd = som_cldist(Md,c1,c2,'single')
   Cd = som_cldist(Md,c1,c2,'average')
   Cd = som_cldist(Md,c1,c2,'complete')
   Cd = som_cldist(Md,c1,c2,'neighf',H)
   Cd = som_cldist(Md,c1,[],...)
   Cd = som_cldist(D,c1,c2,'centroid',q,mask)
   Cd = som_cldist(D,c1,c2,'ward',q,mask)
   Cd = som_cldist(D,c1,[],...)

  Input and output arguments ([]'s are optional):
   D        (matrix) size dlen x dim, the data set
            (struct) map or data struct
   Md       (matrix) size dlen x dlen, mutual distance matrix, see SOM_MDIST
   c1       (cell array) size n1 x 1, indices of clusters from which 
                     the distances should be calculated, each cell
                     contains indices of vectors that belong to that
                     cluster (indices are between 1...dlen)
   c2       (cell array) size n2 x 1, same as c1 but have the clusters
                     to which the distances should be calculated
            (empty)  c1 is used in place of c2
   [q]      (scalar) distance norm, default = 2
   [mask]   (vector) size dim x 1, the weighting mask, a vector of ones
                     by default
   H        (matrix) size dlen x dlen, neighborhood function values

   Cd       (matrix) size n1 x n2, distances between the clusters

 See also SOM_MDIST. 



[ SOM Toolbox online doc ]