TopologyDiagram.split_edge
- TopologyDiagram.split_edge(u, v, t=0.5)[source]
Split and edge by inserting a node along its length.
- Parameters:
u (str) – The key of the first node of the edge.
v (str) – The key of the second node of the edge.
t (float, optional) – The position of the inserted node on the edge.
- Returns:
hashable – The key of the inserted node.
- Raises:
ValueError – If t is not in the range 0-1.
Exception – If u and v are not neighbors.