Measures to compare the similarity of two clustering outcomes
first cluster identity matrix
second cluster identity matrix
This function calculates the Rand Index for two different clustering outcomes. The Rand Index gives a value between 0 and 1, where 1 means the two clustering outcomes match identicaly.
The Adjusted Rand Index rescales the index, taking into account that random chance will cause some objects to occupy the same clusters, so the Rand Index will never actually be zero.
a single value between 0 and 1
Rand, W.M. 1971. Objective criteria for the evaluation of clustering methods. Journal of the American Statistical Association 66: 846–850.
Hubert, L. and Arabie, P. 1985. Comparing partitions. Journal of Classification. 2: 193–218.
To cluster the data, use the function
1 2 3 4
Loading required package: sp Loading required package: maps Loading required package: shapefiles Loading required package: foreign Attaching package: 'shapefiles' The following objects are masked from 'package:foreign': read.dbf, write.dbf  0.4666667
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.