apaClustering.Evaluation.SilhouetteValues(DataMatrix, ClusteringResult)
=apaClustering.Evaluation.SilhouetteValues(DataMatrix, ClusteringResult)Result
Evaluates the assignments of a clustering algorithm: silhouette values for all data points.
Syntax
DataMatrix: r x c data matrix
ClusteringResult: r x 1 vector of cluster labels. The labels can be any integer values; points labelled -1 (noise, e.g. from apaClustering.DBSCAN) are excluded.
Remarks
Returns three columns: the observation index (0-based row number in DataMatrix), the cluster label and the silhouette value. The rows are sorted by cluster label and, within each cluster, by ascending silhouette value.
The silhouette value of a point is (b - a) / max(a, b), where a is the mean distance to the other members of its own cluster and b the mean Euclidean distance to the members of the nearest other cluster. Points in single-member clusters have a silhouette value of 0.
