| igraph Reference Manual |
|---|
int igraph_motifs_randesu(const igraph_t *graph, igraph_vector_t *hist, int size, const igraph_vector_t *cut_prob);
Motifs are small subgraphs of a given structure in a graph. It is argued that the motif profile (ie. the number of different motifs in the graph) is characteristic for different types of networks and network function is related to the motifs in the graph.
This function is able to find the different motifs of size three and four (ie. the number of different subgraphs with three and four vertices) in the network. (This limitation is the result of the lack of code to decide graph isomorphism for larger graphs.)
In a big network the total number of motifs can be very large, so
it takes a lot of time to find all of them, a sampling method can
be used. This function is capable of doing sampling via the
cut_prob argument. This argument gives the probability that
a branch of the motif search tree will not be explored. See
S. Wernicke and F. Rasche: FANMOD: a tool for fast network motif
detection, Bioinformatics 22(9), 1152--1153, 2006 for details.
Set the cut_prob argument to a zero vector for finding all
motifs.
Directed motifs will be counted in directed graphs and undirected motifs in undirected graphs.
Arguments:
|
The graph to find the motifs in. |
|
The result of the computation, it gives the number of
motifs found for each isomorphism class. See
|
|
The size of the motifs to search for. Only three and four are implemented currently. The limitation is not in the motif finding code, but the graph isomorphism code. |
|
Vector of probabilities for cutting the search tree
at a given level. The first element is the first level, etc.
Supply all zeros here (of length |
Returns:
Error code. |
See also:
|
Time complexity: TODO.
| << 3. Graph motifs | 3.2. igraph_motifs_randesu_no — Count the total number of motifs in a graph >> |