7.2.1.5. get_unused_node_id¶
-
get_unused_node_id
(graph, initial_guess='unknown', _format='{}<%d>')[source]¶ Finds an unused node id in graph.
Parameters: - graph (networkx.classes.digraph.DiGraph) – A directed graph.
- initial_guess (str, optional) – Initial node id guess.
- _format (str, optional) – Format to generate the new node id if the given is already used.
Returns: An unused node id.
Return type: