These functions return logical vectors the length of the nodes in a network identifying which hold certain properties or positions in the network.

  • node_is_independent() marks nodes that are members of the largest independent set, aka largest internally stable set.

  • node_is_cutpoint() marks nodes that cut or act as articulation points in a network, increasing the number of connected components when removed.

  • node_is_fold() marks nodes that are in a structural fold between two or more triangles that are only connected by that node.

  • node_is_mentor() marks a proportion of high indegree nodes as 'mentors' (see details).

  • node_is_neighbor() marks nodes that are neighbours of a given node.

node_is_independent(.data)

node_is_cutpoint(.data)

node_is_fold(.data)

node_is_mentor(.data, elites = 0.1)

node_is_neighbor(.data, node, cutoff = 1)

Arguments

.data

A network object of class stocnet, igraph, tbl_graph, network, or similar. Internally any of these will be coerced to an efficient implementation. For more information on possible coercions, see e.g. manynet::as_stocnet().

elites

The proportion of nodes to be selected as mentors. By default this is set at 0.1. This means that the top 10% of nodes in terms of degree, or those equal to the highest rank degree in the network, whichever is the higher, will be used to select the mentors. In a two-mode network the mentors are selected within each mode.

Note that if nodes are equidistant from two mentors, they will choose one at random. If a node is without a path to a mentor, for example because they are an isolate, a tie to themselves (a loop) will be created instead. Note that this is a different default behaviour than that described in Valente and Davis (1999).

node

A node ID or name for which neighbors are to be marked.

cutoff

Integer scalar, the maximum path length considered. Paths longer than this are ignored, which restricts the measure to a node's local neighbourhood. Where a measure is defined over all paths by default, a negative value or NULL imposes no limit.

Value

A node_mark logical vector the length of the nodes in the network, giving either TRUE or FALSE for each node depending on whether the condition is matched.

Details

For signed networks, node_is_fold() considers only the positive ties. It reads a tie as a distance, and a negative tie is hostility rather than a channel along which cohesion travels.

For multilevel networks, node_is_independent() marks the network whole, as net_by_independence() does. A multilevel network reports itself as two-mode, but holds ties within a mode as well as between them, so it cannot be projected onto one mode.

Neighbourhoods

By default, node_is_neighbor() marks the nodes that node has a tie to. Given a cutoff, it instead marks every node that can be reached from node along a path no longer than cutoff, but not node itself. Where the ties have a 'length' attribute, such as manynet::read_geojson() measures along each line, a path is as long as the sum of the lengths of its ties, so that cutoff can be, for example, a travel distance or time (an isochrone); otherwise a path is as long as the number of ties it crosses. Weights are strengths and not distances, so they are not read.

References

On independent sets

Tsukiyama, Shuji, Mikio Ide, Hiromu Ariyoshi, and Isao Shirawaka. 1977. "A new algorithm for generating all the maximal independent sets". SIAM Journal on Computing, 6(3):505–517. doi:10.1137/0206036

On articulation or cut-points

Tarjan, Robert E. and Uzi Vishkin. 1985. "An Efficient Parallel Biconnectivity Algorithm", SIAM Journal on Computing 14(4): 862-874. doi:10.1137/0214061

On structural folds

Vedres, Balazs, and David Stark. 2010. "Structural folds: Generative disruption in overlapping groups", American Journal of Sociology 115(4): 1150-1190. doi:10.1086/649497

On mentoring

Valente, Thomas, and Rebecca Davis. 1999. "Accelerating the Diffusion of Innovations Using Opinion Leaders", Annals of the American Academy of Political and Social Science 566: 56-67.

Examples

node_is_independent(ison_adolescents)
#>   Betty Sue   Alice Jane  Dale  Pam   Carol Tina 
#> 1 TRUE  FALSE FALSE FALSE TRUE  TRUE  FALSE TRUE 
node_is_cutpoint(ison_brandes)
#>   V1    V2    V3    V4    V5    V6    V7    V8    V9    V10   V11  
#> 1 FALSE FALSE TRUE  TRUE  FALSE FALSE FALSE FALSE TRUE  FALSE FALSE
node_is_fold(create_explicit(A-B, B-C, A-C, C-D, C-E, D-E))
#>   A     B     C     D     E    
#> 1 FALSE FALSE TRUE  FALSE FALSE
node_is_neighbor(ison_adolescents, "Betty", cutoff = 2)
#>   Betty Sue   Alice Jane  Dale  Pam   Carol Tina 
#> 1 FALSE TRUE  TRUE  FALSE TRUE  TRUE  FALSE FALSE