intersection_all#

intersection_all(graphs)[source]#

Returns a new graph that contains only the nodes and the edges that exist in all graphs.

Parameters:
graphsiterable

Iterable of NetworkX graphs

Returns:
RA new graph with the same type as the first graph in list
Raises:
ValueError

If graphs is an empty list.

Notes

Attributes from the graph, nodes, and edges are not copied to the new graph.