[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [igraph] Traversing edges in sorted order

From: Tamás Nepusz
Subject: Re: [igraph] Traversing edges in sorted order
Date: Mon, 29 Jul 2013 22:36:54 +0200

> Would you mind explaining what order edges are returned in. I notice that 
> g.es (looking only at the edges that are outgoing from node v) and 
> g.neighbors(v, mode=OUT) seem to return edges in a different order. 
g.neighbors() returns the *node IDs* that are neighbors of a given node (and 
not the edge IDs), sorted by node ID.
g.incident() returns the *edge IDs* that are incident on a given node, but no 
specific ordering is guaranteed.
g.es.select(_source=v) or g.es.select(_form=v) returns the edge IDs that 
originate from the given node, sorted by edge ID, but this is implemented in 
pure Python so it's much less efficient than using g.incident().


reply via email to

[Prev in Thread] Current Thread [Next in Thread]