A function various measures of similarity between two classifications
clustComp(c1, c2)
a vector containing the labels of the first classification. Must be a vector of characters, integers, numerics, or a factor, but not a list.
a vector containing the labels of the second classification.
a list with the RI, ARI, NMI, NVI and NID.
data(iris)
cl <- cutree(hclust(dist(iris[,-5])), 4)
clustComp(cl,iris$Species)
#> $RI
#> [1] 0.821745
#>
#> $ARI
#> [1] 0.5894567
#>
#> $MI
#> [1] 0.8035825
#>
#> $AMI
#> [1] 0.6378145
#>
#> $VI
#> [1] 0.7395331
#>
#> $NVI
#> [1] 0.4792468
#>
#> $ID
#> [1] 0.4445033
#>
#> $NID
#> [1] 0.356148
#>
#> $NMI
#> [1] 0.643852
#>
#> $Chi2
#> [1] 209.1143
#>
#> $MARI
#> [1] 0.5894345
#>
#> $MARIraw
#> [1] 0.1279572
#>