loads the data to an undirected graph by default
#defines the data file path as data data = r'datafile.datafileextension' #Loads to a directed graph by default G1 = nx.read_edgelist(data, nodetype=str , data=(('weight', float),))