braintools.analysis.graph.MotifCounts

braintools.analysis.graph.MotifCounts#

class braintools.analysis.graph.MotifCounts(triads, dyads, reciprocity)[source]#

Result of motif_counts().

Variables:
  • triads (dict of str to int) – Number of node triples in each of the 16 directed triad classes, keyed by the MAN codes in the order of networkx.triadic_census: '003', '012', '102', '021D', '021U', '021C', '111D', '111U', '030T', '030C', '201', '120D', '120U', '120C', '210', '300'. The counts sum to \(\binom{N}{3}\).

  • dyads (dict of str to int) – Dyad census: number of node pairs that are 'mutual' (i <-> j), 'asymmetric' (one direction) or 'null' (unconnected). The counts sum to \(\binom{N}{2}\).

  • reciprocity (float) – Fraction of edges whose reverse edge also exists, 2 * mutual / (2 * mutual + asymmetric + self_loops) (nan without edges). As in networkx.reciprocity, a self-loop counts as an unreciprocated edge.

__init__()#

Methods

__init__()

count(value, /)

Return number of occurrences of value.

index(value[, start, stop])

Return first index of value.

Attributes

dyads

Alias for field number 1

reciprocity

Alias for field number 2

triads

Alias for field number 0