Returns the structural Hamming distance between multiple graphs
Examples
path <- system.file("cvnfit.RData", package = "CVN")
load(path)
hamming_distance_adj_matrices(fit$adj_matrices[[1]])
#> [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9]
#> [1,] 0 11 16 15 14 14 17 16 13
#> [2,] 11 0 7 10 5 9 12 11 12
#> [3,] 16 7 0 13 10 8 17 12 11
#> [4,] 15 10 13 0 7 9 4 7 10
#> [5,] 14 5 10 7 0 8 11 8 11
#> [6,] 14 9 8 9 8 0 13 10 9
#> [7,] 17 12 17 4 11 13 0 9 12
#> [8,] 16 11 12 7 8 10 9 0 5
#> [9,] 13 12 11 10 11 9 12 5 0
#> attr(,"class")
#> [1] "cvn:distancematrix"