Commit 2f7a47ca authored by Tiago Peixoto's avatar Tiago Peixoto
Browse files

Fix edge/vertex normalization option in graph_draw()

parent f257d426
......@@ -288,6 +288,8 @@ def graph_draw(g, pos=None, size=(15, 15), pin=False, layout= "neato",
minmax[1] += 1
if vnorm:
vnorm = matplotlib.colors.normalize(vmin=minmax[0], vmax=minmax[1])
else:
vnorm = lambda x: x
if ecolor != None and not isinstance(ecolor, str):
minmax = [float("inf"), -float("inf")]
......@@ -299,6 +301,8 @@ def graph_draw(g, pos=None, size=(15, 15), pin=False, layout= "neato",
minmax[1] += 1
if enorm:
enorm = matplotlib.colors.normalize(vmin=minmax[0], vmax=minmax[1])
else:
enorm = lambda x: x
nodes = []
edges = []
......
Markdown is supported
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