Graph.add_edge
- Graph.add_edge(u, v, attr_dict=None, **kwattr)[source]
Add an edge and specify its attributes.
- Parameters:
- uhashable
The identifier of the first node of the edge.
- vhashable
The identifier of the second node of the edge.
- attr_dictdict[str, Any], optional
A dictionary of edge attributes.
- **kwattrdict[str, Any], optional
A dictionary of additional attributes compiled of remaining named arguments.
- Returns:
- tuple[hashable, hashable]
The identifier of the edge.
See also
Examples
>>>