Warning

This documents an unmaintained version of NetworkX. Please upgrade to a maintained version and see the current NetworkX documentation.

networkx.MultiDiGraph.fresh_copy

MultiDiGraph.fresh_copy()[source]

Return a fresh copy graph with the same data structure.

A fresh copy has no nodes, edges or graph attributes. It is the same data structure as the current graph. This method is typically used to create an empty version of the graph.

Notes

If you subclass the base class you should overwrite this method to return your class of graph.