igraph-help
[Top][All Lists]
Advanced

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

Re: [igraph] Selecting edges if a node is present


From: Tamas Nepusz
Subject: Re: [igraph] Selecting edges if a node is present
Date: Fri, 27 Jan 2017 20:54:05 +0100

I presume this is a very simple question. If I have a directed network, how do I select edges that have a given node as sink?
Use incident(graph, vertex, mode="in") to get the indices of all the edges that terminate in a given node. Alternatively, you may use the [[ operator (see http://igraph.org/r/doc/sub-sub-.igraph.html):

graph[[, v, edges=TRUE]]
 
Further, how do I generate a subgraph comprised of all the edges that have a given node as sink?
Use subgraph.edges(); see: http://igraph.org/r/doc/subgraph.html

T.

reply via email to

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