[Top][All Lists]

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

[igraph] Inter and intra vertices' attribute value using subgraph

From: S.M. Ali Abbas
Subject: [igraph] Inter and intra vertices' attribute value using subgraph
Date: Fri, 26 Aug 2011 15:17:16 +0100

Dear All,
I am trying to calculate the percentage of inter and intra attribute level links from a graph, but somehow the subgraph is not returning what I would like to have. I have a graph, g, with vertices having an attribute, group. If I understand Sugraphs correctly, it returns vertices with attributes and edges which satisfy some rule based on either the index or the regular _expression_ of any kind. I don't seem to have the desired results when I run the following code over my graph.

celticgroup <- which(V(g)$group == "CELTIC")
subg <- subgraph(g, celticgroup)

It also returns vertices with other group values. I only want those set of vertices which have just this attribute value. How can I achieve that?

As I am interested in inter attribute level links as well, I would like to know how to do that - all edges which have "CELTIC" in either the source or the target vertex. I do not know how to get this calculated.
Could anyone please share some insight here?



reply via email to

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