Computes betweenness of an igraph object that already has duplicated nodes
betweenness.with.duplicated.nodes.Rd
This is an implementation of the method published in the paper "Intra-family links in the analysis of marital networks" mm24:intra_family_linksdupNodes, which proposed a duplication of nodes that includes self-loops to get a reflect better (and include all information about) the status of all nodes in the network, computing betweenness ignoring the duplicated nodes.
Details
This method computes betweenness centrality in the regular way for the graph that includes duplicated nodes; it will only return values for the "original" nodes, however.
This object should be created with the function dup.nodes.from.data.frame
or dup.nodes.from.graph
Examples
library(igraph)
V1 <- c("A", "A","B","C","D","E")
V2 <- c("A", "B","C","D","E","A")
df <- data.frame(V1, V2)
dup.graph <- dup.nodes.from.data.frame(df)
print(betweenness.with.duplicated.nodes(dup.graph))
#> A B C D E
#> 0.5 2.0 1.0 1.0 2.0