Module Expr Str Import alias identifier Assign NameStore Call AttributeLoad Str attr ListLoad Str Str Str Assign NameStore ListLoad Str Str FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If CompareIs NameLoad NameLoad body Assign NameStore BinOpMod Str AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr GeneratorExp TupleLoad NameLoad NameLoad comprehension TupleStore NameStore NameStore Call AttributeLoad NameLoad attr comprehension NameStore NameLoad CompareNotIn NameLoad NameLoad CompareNotEq NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If UnaryOpNot Call AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr Str orelse Return Call AttributeLoad NameLoad attr keyword NameLoad decorator_list
N/A N/A Unary operations on graphs N/A networkx nx N/A __author__ N/A N/A join N/A Aric Hagberg <aric.hagberg@gmail.com> Pieter Swart (swart@lanl.gov) Dan Schult(dschult@colgate.edu) N/A __all__ N/A complement reverse complement N/A N/A G name N/A None N/A N/A Return the graph complement of G.

    Parameters
    ----------
    G : graph
       A NetworkX graph

    name : string
       Specify name for new graph

    Returns
    -------
    GC : A new graph.

    Notes
    ------
    Note that complement() does not create self-loops and also
    does not produce parallel edges for MultiGraphs.

    Graph, node, and edge data are not propagated to the new graph.
     N/A N/A name None N/A N/A name N/A complement(%s) N/A G name N/A R N/A N/A G __class__ N/A N/A R name name N/A N/A N/A R add_nodes_from G N/A N/A N/A R add_edges_from N/A N/A n n2 N/A N/A n nbrs N/A N/A G adjacency N/A n2 G N/A n2 nbrs N/A n n2 N/A R N/A reverse N/A N/A G copy N/A True N/A N/A Return the reverse directed graph of G.

    Parameters
    ----------
    G : directed graph
        A NetworkX directed graph
    copy : bool
        If True, then a new graph is returned. If False, then the graph is
        reversed in place.

    Returns
    -------
    H : directed graph
        The reversed G.

     N/A N/A N/A N/A G is_directed N/A N/A N/A N/A nx NetworkXError Cannot reverse an undirected graph. N/A N/A N/A N/A G reverse copy copy N/A