igraph-help
[Top][All Lists]
Advanced

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

[igraph] Still having issues with weighted betweenness calculations usin


From: Alex Upton
Subject: [igraph] Still having issues with weighted betweenness calculations using igraph in 64-bit windows
Date: Wed, 16 May 2012 20:21:22 +0100

Dear all,

I was kindly provided with a windows package for igraph 0.6, thank you Gábor 
Csárdi, to calculate the weighted betweenness centrality, however I am getting 
the error message: 

Error in betweenness(g1, weights = TRUE) : 
At centrality.c:1454 : Weight vector length does not match, Invalid value

I entered some of the code in the function manually: weights <- E(graph)$weight 

to check what the variable weights called is and the length, and it is:

length(weights)
[1] 31996000

Which is the same as:

ecount(g1)
[1] 31996000

I previously read that this error was due to the weights vector length not 
being equal to the number of edges in the graph, however this would not seem to 
be the case, using the code:  , which is contained within the betweenness 
function. I am calling the function as such:

wb1 <- betweenness(g1, weights = TRUE)

which I believe is the correct way. I am a little confused now as to why there 
is an error, could anyone help me with this?


Regards

Alex

___________________________________________________________________

         

Alex Upton, BEng, MRes, PG Cert Business Administration
PhD Researcher Biomedical Informatics, Signals and Systems 
School of Electronic, Electrical and Computer Engineering, 
College of Engineering and Physical Sciences, University of Birmingham
Edgbaston, Birmingham, B15 2TT, United Kingdom

Fax: +44 121 4144291 (school general office)
Email: address@hidden

Personal Web: http://postgrad.eee.bham.ac.uk/uptona/
__________________________________________________________________


reply via email to

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