Learn R Programming

migraph (version 0.9.3)

census: Census by nodes or clusters

Description

These functions include ways to take a census of the positions of nodes in a network. These include a triad census based on the triad profile of nodes, but also a tie census based on the particular tie partners of nodes. Included also are group census functions for summarising the profiles of clusters of nodes in a network.

Usage

node_tie_census(object)

node_triad_census(object)

node_quad_census(object)

group_tie_census(object, clusters, decimals = 2)

group_triad_census(object, clusters, decimals = 2)

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

clusters

a vector of cluster assignment.

decimals

Number of decimal points to round to.

Functions

  • node_quad_census: Returns a census of nodes' positions in motifs of four nodes.

Details

The quad census uses the {oaqc} package to do the heavy lifting of counting the number of each orbits. See vignette('oaqc'). However, our function relabels some of the motifs to avoid conflicts and improve some consistency with other census-labelling practices. The letter-number pairing of these labels indicate the number and configuration of ties. For now, we offer a rough translation:

migraph Ortmann and Brandes
E4 co-K4
I40, I41 co-diamond
H4 co-C4
L42, L41, L40 co-paw
D42, D40 co-claw
U42, U41 P4
Y43, Y41 claw
P43, P42, P41 paw
04 C4
Z42, Z43 diamond
X4 K4

References

Ortmann, Mark, and Ulrik Brandes. 2017. <U+201C>Efficient Orbit-Aware Triad and Quad Census in Directed and Undirected Graphs.<U+201D> Applied Network Science 2(1):13. https://doi.org/10.1007/s41109-017-0027-2

Examples

Run this code
# NOT RUN {
task_eg <- to_named(to_uniplex(ison_algebra, "task_tie"))
(tie_cen <- node_tie_census(task_eg))
(triad_cen <- node_triad_census(task_eg))
(quad_cen <- node_quad_census(ison_southern_women))
group_tie_census(task_eg, cutree(cluster_structural_equivalence(task_eg), 4))
group_triad_census(task_eg, cutree(cluster_regular_equivalence(task_eg), 4))
# }

Run the code above in your browser using DataLab