igraph-help
[Top][All Lists]
Advanced

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

Re: [igraph] Selecting vertices for centrality analysis in R


From: Gábor Csárdi
Subject: Re: [igraph] Selecting vertices for centrality analysis in R
Date: Mon, 17 Dec 2012 22:45:38 -0500

Hi Jorge,

On Mon, Dec 17, 2012 at 10:22 AM, Jorge Gil <address@hidden> wrote:
[...]
    bet<-betweenness(lg,v=V(lg)[name %in% lo$road_id],directed=F,normalized=T,weights=E(lg)$metric)

This seems to be bug. The workaround is to calculate the betweenness for all vertices and then select the ones you want, manually. (It won't be any slower, betweenness is calculated for all vertices anyway, even if you only request a single vertex.)
 
[...]
As a final point: I would like the weight to be selected dynamically so that I can repeat the analysis in a loop for different weights. How can I refer to the Edge attributes dynamically, using an index for example.

get.edge.attribute(lg, "weight1")
get.edge.attribute(lg, "weight2")
etc.

Thanks for the bug report!

Best,
Gabor
 


Thank you in advance,
Jorge

--
Jorge Gil
PhD Candidate

TU Delft / Faculty of Architecture
Department of Urbanism
Chair of Spatial Planning and Strategy

Julianalaan 134
2628 BL Delft
P.O. Box 5043
2600 GA Delft
The Netherlands

www.tudelft.nl


_______________________________________________
igraph-help mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/igraph-help




--
Gabor Csardi <address@hidden>     MTA KFKI RMKI


reply via email to

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