easygraph.functions.community.motif module#

easygraph.functions.community.motif.enumerate_subgraph(G, k: int)[source]#

Returns the motifs. Motifs are small weakly connected induced subgraphs of a given structure in a graph.

Parameters:
  • G (easygraph.Graph or easygraph.DiGraph.) –

  • k (int) – The size of the motifs to search for.

Returns:

k_subgraphs – The motifs.

Return type:

list

References

easygraph.functions.community.motif.random_enumerate_subgraph(G, k: int, cut_prob: list)[source]#

Returns the motifs. Motifs are small weakly connected induced subgraphs of a given structure in a graph.

Parameters:
  • G (easygraph.Graph or easygraph.DiGraph.) –

  • k (int) – The size of the motifs to search for.

  • cut_prob (list) – list of probabilities for cutting the search tree at a given level.

Returns:

k_subgraphs – The motifs.

Return type:

list

References

International Workshop on Algorithms in Bioinformatics. Springer, Berlin, Heidelberg, 2005.