Operations on graphs; including union, intersection, difference, complement, subgraph.
The following operator functions provide standard relabeling and combining operations for networks.
| create_empty_copy(G[, with_nodes]) | Return a copy of the graph G with all of the edges removed. |
| subgraph(G, nbunch[, copy]) | Return the subgraph induced on nodes in nbunch. |
| cartesian_product(G, H[, create_using]) | Return the Cartesian product of G and H. |
| compose(G, H[, create_using, name]) | Return a new graph of G composed with H. |
| complement(G[, create_using, name]) | Return graph complement of G. |
| union(G, H[, create_using, rename, name]) | Return the union of graphs G and H. |
| disjoint_union(G, H) | Return the disjoint union of graphs G and H, forcing distinct integer |
| intersection(G, H[, create_using]) | Return a new graph that contains only the edges that exist in |
| difference(G, H[, create_using]) | Return a new graph that contains the edges that exist in |
| symmetric_difference(G, H[, create_using]) | Return new graph with edges that exist in |
| line_graph(G) | Return the line graph of the graph or digraph G. |
| ego_graph(G, n[, center]) | Returns induced subgraph of neighbors centered at node n. |
| stochastic_graph(G[, copy]) | Return a right-stochastic representation of G. |
| convert_node_labels_to_integers(G[, ...]) | Return a copy of G node labels replaced with integers. |
| relabel_nodes(G, mapping) | Return a copy of G with node labels transformed by mapping. |