Learn R Programming

migraph (version 0.9.3)

connectedness: Network connectedness

Description

These functions return values or vectors relating to how connected a network is and where the nodes or edges that would increase fragmentation are.

Usage

graph_components(object, method = c("weak", "strong"))

graph_cohesion(object)

graph_adhesion(object)

graph_length(object)

graph_diameter(object)

node_components(object, method = c("weak", "strong"))

node_cuts(object)

edge_bridges(object)

Arguments

object

An object of a migraph-consistent class:

  • matrix, from base R

  • edgelist, a data frame from base R or tibble from tibble

  • igraph, from the igraph package

  • network, from the network package

  • tbl_graph, from the tidygraph package

method

For directed networks, either weak if edge direction is irrelevant, or strong if edge direction is salient. Ignored if network undirected.

Functions

  • graph_components: Returns number of components in the network.

  • graph_cohesion: Returns the minimum number of nodes needed to remove from the network to increase the number of components.

  • graph_adhesion: Returns the minimum number of edges needed to remove from the network to increase the number of components.

  • graph_length: Returns the average path length in the network.

  • graph_diameter: Returns the maximum path length in the network.

  • node_components: Returns nodes' component membership.

  • node_cuts: Returns logical of which nodes cut or act as articulation points in a network.

  • edge_bridges: Returns logical of which nodes cut or act as articulation points in a network.

References

White, Douglas R and Frank Harary 2001. The Cohesiveness of Blocks In Social Networks: Node Connectivity and Conditional Density. Sociological Methodology 31 (1) : 305-359.

Examples

Run this code
# NOT RUN {
graph_cohesion(ison_marvel_relationships)
graph_cohesion(to_main_component(ison_marvel_relationships))
graph_adhesion(ison_marvel_relationships)
graph_adhesion(to_main_component(ison_marvel_relationships))
graph_length(ison_marvel_relationships)
graph_length(to_main_component(ison_marvel_relationships))
graph_diameter(ison_marvel_relationships)
graph_diameter(to_main_component(ison_marvel_relationships))
# }

Run the code above in your browser using DataLab