Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Tiago Peixoto
graph-tool
Commits
a993433c
Commit
a993433c
authored
May 21, 2014
by
Tiago Peixoto
Browse files
Improve documentation of subgraph_isomorphism() and motifs()
parent
6fcf0f1b
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/graph_tool/clustering/__init__.py
View file @
a993433c
...
...
@@ -286,9 +286,9 @@ def extended_clustering(g, props=None, max_depth=3, undirected=False):
def
motifs
(
g
,
k
,
p
=
1.0
,
motif_list
=
None
,
return_maps
=
False
):
r
"""
Count the occurrence of k-size subgraphs (motifs). A tuple with
two lists is
returned: the list of motifs found, and the list with their
respective
counts.
Count the occurrence of k-size
node-induced
subgraphs (motifs). A tuple with
two lists is
returned: the list of motifs found, and the list with their
respective
counts.
Parameters
----------
...
...
@@ -358,6 +358,7 @@ def motifs(g, k, p=1.0, motif_list=None, return_maps=False):
motifs", IEEE/ACM Transactions on Computational Biology and
Bioinformatics (TCBB), Volume 3, Issue 4, Pages 347-359, 2006.
:doi:`10.1109/TCBB.2006.51`
.. [induced-subgraph-isomorphism] http://en.wikipedia.org/wiki/Induced_subgraph_isomorphism_problem
"""
sub_list
=
[]
...
...
src/graph_tool/topology/__init__.py
View file @
a993433c
...
...
@@ -222,6 +222,11 @@ def subgraph_isomorphism(sub, g, max_n=0, vertex_label=None, edge_label=None,
Notes
-----
Here "subgraph" does not mean "node-induced subgraph", i.e. there may exist
an edge in the matched subgraph in `g` that does not exist in `sub`. For
node-induced subgraph isomorphism, see the :func:`+graph_tool.clustering.motifs`
function.
The algorithm used is described in [ullmann-algorithm-1976]_. It has a
worse-case complexity of :math:`O(N_g^{N_{sub}})`, but for random graphs it
typically has a complexity of :math:`O(N_g^\gamma)` with :math:`\gamma`
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment