Cluster Stability

library(clustAnalytics)
#> Loading required package: igraph
#> 
#> Attaching package: 'igraph'
#> The following objects are masked from 'package:stats':
#> 
#>     decompose, spectrum
#> The following object is masked from 'package:base':
#> 
#>     union

Here we perform a nonparametric bootstrap to the karate club graph and the same selection of algorithms. For each instance, the set of vertices is resampled, the induced graph is obtained by taking the new set of vertices with the induced edges from the original graph, and the clustering algorithms are applied. Then, these results are compared to the induced original clusterings using several metrics: the variation of information (VI), normalized reduced mutual information (NRMI) and both adjusted and regular Rand index (Rand and adRand):

data(karate, package="igraphdata")
boot_alg_list(g=karate, return_data=FALSE, R=99,
              alg_list=list(Louvain=cluster_louvain, 
                            "label prop"= cluster_label_prop, 
                            walktrap=cluster_walktrap)) 
#> This graph was created by an old(er) igraph version.
#>   Call upgrade_graph() on it to use with the current igraph version
#>   For now we convert it on the fly...
#>              Louvain label prop  walktrap
#> VI         0.2783177  0.2893696 0.2640412
#> AMI        0.6157207  0.4956266 0.6276684
#> NRMI       0.5604656  0.5592462 0.5933546
#> Rand       0.8427591  0.7809467 0.8507175
#> AdRand     0.6247283  0.5635196 0.6448232
#> n_clusters 5.2828283  5.1414141 5.7474747