Commit 0285f00a authored by Tiago Peixoto's avatar Tiago Peixoto
Browse files

Check for vector property type in graph_draw()

parent 03248ef2
......@@ -48,7 +48,8 @@ import copy
from collections import defaultdict
from .. import GraphView, PropertyMap, ungroup_vector_property,\
group_vector_property, _prop
group_vector_property, _prop, _check_prop_vector
from .. stats import label_parallel_edges, label_self_loops
from .. dl_import import dl_import
......@@ -612,7 +613,9 @@ def graph_draw(g, pos=None, vprops=None, eprops=None, vorder=None, eorder=None,
kwargs["layout_K"] = _avg_edge_distance(g, pos) / 10
pos = sfdp_layout(g)
elif output is None:
_check_prop_vector(pos, name="pos", floating=True)
if output is None:
if "layout_K" not in kwargs:
kwargs["layout_K"] = _avg_edge_distance(g, pos)
if "update_layout" not in kwargs:
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment