These functions create a vector of nodes' memberships in components or degrees of coreness:

  • node_components() assigns nodes' component membership using edge direction where available.

  • node_weak_components() assigns nodes' component membership ignoring edge direction.

  • node_strong_components() assigns nodes' component membership based on edge direction.

  • node_roulette()

In graph theory, components, sometimes called connected components, are induced subgraphs from partitioning the nodes into disjoint sets. All nodes that are members of the same partition as i are reachable from i.

For directed networks, strongly connected components consist of subgraphs where there are paths in each direction between member nodes. Weakly connected components consist of subgraphs where there is a path in either direction between member nodes.

Coreness captures the maximal subgraphs in which each vertex has at least degree k, where k is also the order of the subgraph. As described in igraph::coreness, a node's coreness is k if it belongs to the k-core but not to the (k+1)-core.

node_components(.data)

node_weak_components(.data)

node_strong_components(.data)

Arguments

.data

An object of a {manynet}-consistent class:

  • matrix (adjacency or incidence) 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

See also

Other memberships: cliques, community, core, equivalence

Examples

node_components(mpn_bristol)
#>   `101` `102` `103` `104` `105` `106` `107` `108` `109` `110` `111` `112` `113`
#> 1     1     1     1     1     1     1     1     1     1     1     1     1     1
#> # ... with 137 more values from this nodeset unprinted. Use `print(..., n = Inf)` to print all values.
#>   AddReAg AfrInit AvonBat OrganicCoop Wildlife BACEN BangladAss Barnardos
#> 1       1       1       3           1        1     1          1         1
#> # ... with 106 more values from this nodeset unprinted. Use `print(..., n = Inf)` to print all values.