

def neighbors_iter(self, n):
    'Return an iterator over all neighbors of node n.\n\n        Examples\n        --------\n        >>> G = nx.Graph()   # or DiGraph, MultiGraph, MultiDiGraph, etc\n        >>> G.add_path([0,1,2,3])\n        >>> [n for n in G.neighbors_iter(0)]\n        [1]\n\n        Notes\n        -----\n        It is faster to use the idiom "in G[0]", e.g.\n\n        >>> G = nx.path_graph(4)\n        >>> [n for n in G[0]]\n        [1]\n        '
    try:
        return iter(self.adj[n])
    except KeyError:
        raise NetworkXError(('The node %s is not in the graph.' % (self,)))

dataset/ETHPy150Open networkx/networkx/networkx/classes/tests/timingclasses.py TimingGraph.neighbors_iter/VarMisuse@42/257 `n`->`self`