문제

I installed networkx by using pip, however I cannot use the example given because I cannot import graphviz_layout. Then I download networkx and unzip it by myself. Still I cannot find graphviz_layout in the folder. There is just layout.py. Does anybody knows why?

도움이 되었습니까?

해결책

The function for graphviz_layout() is in the nx_agraph.py file: http://networkx.github.io/documentation/latest/_modules/networkx/drawing/nx_agraph.html#graphviz_layout

In order to use it in NetworkX you need to also install PyGraphviz https://pypi.python.org/pypi/pygraphviz

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top