Skip to content
Advertisement

add_star function not adding attributes in Networkx

For some reason add_star() is not inputting the attributes to the nodes.

JavaScript

Any idea what’s going on??

Versions: Python 2.7 Networkx 2.2

Advertisement

Answer

If by attributes you mean the edge weights, the weights are added as edge attributes:

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