networkx对图进行可视化

networkx对图进行可视化

Creating a graph — NetworkX 1.9 documentation

Software for Complex Networks — NetworkX 2.8.5 documentation

import networkx as nx

import matplotlib.pyplot as plt
fig, ax = plt.subplots()
nx.draw(g, ax=ax)
plt.show()

 

posted @ 2022-07-22 15:02  bH1pJ  阅读(35)  评论(0编辑  收藏  举报