This view is primarily used to iterate over the edges reporting edges as node-tuples with edge data optionally reported. The argument nbunch
allows restriction to edges incident to nodes in that container/singleton. The default (nbunch=None) reports all edges. The arguments :None:None:`data`
and default
control what edge data is reported. The default :None:None:`data is False`
reports only node-tuples for each edge. If :None:None:`data is True`
the entire edge data dict is returned. Otherwise :None:None:`data`
is assumed to hold the name of the edge attribute to report with default default
if that edge attribute is not present.
A EdgeDataView class for edges of Graph
>>> G = nx.path_graph(3)
... G.add_edge(1, 2, foo="bar")
... list(G.edges(data="foo", default="biz")) [(0, 1, 'biz'), (1, 2, 'bar')]
>>> assert (0, 1, "biz") in G.edges(data="foo", default="biz")See :
The following pages refer to to this document either explicitly or contain code examples using this.
networkx.classes.reportviews.EdgeView
networkx.classes.reportviews.OutEdgeView.data
Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.
Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)
SVG is more flexible but power hungry; and does not scale well to 50 + nodes.
All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them