to_motif_matrix#

to_motif_matrix(motifs, data_type=<class 'int'>)[source]#

Converts a 40d vector of global motifs to a 2d grid of motifs corresponding to the layout in Motifs in Temporal Networks (Paranjape et al)

Parameters:

motifs (list | np.ndarray) – 1 dimensional length-40 array of motifs.

Returns:

6x6 array of motifs whose ijth element is M_ij in Motifs in Temporal Networks (Paranjape et al).

Return type:

np.ndarray