Skip to content

Instantly share code, notes, and snippets.

@shubham-singh-ss
Created October 21, 2019 07:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shubham-singh-ss/2b1bf1815be47893ad65e4bd530284b1 to your computer and use it in GitHub Desktop.
Save shubham-singh-ss/2b1bf1815be47893ad65e4bd530284b1 to your computer and use it in GitHub Desktop.
import networkx as nx
df = nx.from_pandas_edgelist(data, source='Origin', target='Dest', edge_attr=True)
df.nodes()
df.edges()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment