9.13.1. networkx.algorithms.triads.triadic_census¶
-
networkx.algorithms.triads.triadic_census(G)[source]¶ Determines the triadic census of a directed graph.
The triadic census is a count of how many of the 16 possible types of triads are present in a directed graph.
Parameters: G : digraph
A NetworkX DiGraph
Returns: census : dict
Dictionary with triad names as keys and number of occurrences as values.
See also
triad_graphNotes
This algorithm has complexity O(m) where m is the number of edges in the graph.
References
[R823] Vladimir Batagelj and Andrej Mrvar, A subquadratic triad census algorithm for large sparse networks with small maximum degree, University of Ljubljana, http://vlado.fmf.uni-lj.si/pub/networks/doc/triads/triads.pdf