Skip to content
Advertisement

module ‘networkx’ has no attribute ‘from_pandas_edgelist’

here is my code:

JavaScript

and there is an error:AttributeError: module ‘networkx’ has no attribute ‘from_pandas_edgelist’* however, this the documents of networx we could find networkx has the attribute. here is the link of the documents:from_pandas_edgelist

why did this question happen?

Advertisement

Answer

Are you defining the alias nx as follows:

JavaScript

If yes, try calling the required function as follows:

JavaScript
User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement