diff --git a/doc/python/sankey-diagram.md b/doc/python/sankey-diagram.md index cf6bfbfc3ce..9a10d2074fd 100644 --- a/doc/python/sankey-diagram.md +++ b/doc/python/sankey-diagram.md @@ -73,7 +73,7 @@ response = urllib.request.urlopen(url) data = json.loads(response.read()) # override gray link colors with 'source' colors -opacity = 0.4 +opacity = 0.2 # change 'magenta' to its 'rgba' value to add opacity data['data'][0]['node']['color'] = ['rgba(255,0,255, 0.8)' if color == "magenta" else color for color in data['data'][0]['node']['color']] data['data'][0]['link']['color'] = [data['data'][0]['node']['color'][src].replace("0.8", str(opacity)) @@ -199,4 +199,4 @@ fig.show() ### Reference -See [https://plotly.com/python/reference/#sankey](https://plotly.com/python/reference/#sankey) for more information and options! \ No newline at end of file +See [https://plotly.com/python/reference/#sankey](https://plotly.com/python/reference/#sankey) for more information and options!