Computed betweenness via duplication of nodes with self-loops (Duplicated Nodes with Self Loops)
DNSL.betweenness.Rd
Computes the betweenness of nodes in a graph that includes self-loops directly.
Details
This method computes betweenness centrality of a social network described by a data frame. Use it when you want to just apply the DNSLbetweenness method mm24:intra_family_linksdupNodes to a data set, without using the intermediate graph obtained by duplicating nodes.
Examples
library(igraph)
#>
#> Attaching package: ‘igraph’
#> The following objects are masked from ‘package:stats’:
#>
#> decompose, spectrum
#> The following object is masked from ‘package:base’:
#>
#> union
V1 <- c("A", "A","B","C","D","E")
V2 <- c("A", "B","C","D","E","A")
print(DNSL.betweenness(data.frame(V1,V2)))
#> A B C D E
#> 0.5 2.0 1.0 1.0 2.0