Skip to content
GitLab
Menu
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
5c370c56
Commit
5c370c56
authored
Mar 10, 2018
by
Tiago Peixoto
Browse files
Fix issue with motif_significance()
This fixes issue #444.
parent
00de67ff
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/graph_tool/clustering/__init__.py
View file @
5c370c56
...
...
@@ -428,7 +428,7 @@ def _graph_sig(g):
"""return the graph signature, i.e., the in and out degree distribution as
concatenated as a tuple."""
bins
=
list
(
range
(
0
,
g
.
num_vertices
()
+
1
))
in_dist
=
vertex_hist
(
g
,
"in"
,
bins
=
bins
if
g
.
is_directed
()
else
[
0
],
in_dist
=
vertex_hist
(
g
,
"in"
,
bins
=
bins
if
g
.
is_directed
()
else
[
0
,
1
],
float_count
=
False
)
out_dist
=
vertex_hist
(
g
,
"out"
,
bins
=
bins
,
float_count
=
False
)
sig
=
tuple
([(
in_dist
[
1
][
i
],
in_dist
[
0
][
i
])
for
\
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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