Skip to content

Instantly share code, notes, and snippets.

@prateekjoshi565
Created October 11, 2019 06:59
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save prateekjoshi565/09e330170de52e1a38fd5a9680eaa222 to your computer and use it in GitHub Desktop.
G=nx.from_pandas_edgelist(kg_df[kg_df['edge']=="released in"], "source", "target",
edge_attr=True, create_using=nx.MultiDiGraph())
plt.figure(figsize=(12,12))
pos = nx.spring_layout(G, k = 0.5)
nx.draw(G, with_labels=True, node_color='skyblue', node_size=1500, edge_cmap=plt.cm.Blues, pos = pos)
plt.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment