Betweenness for Weighted Network

Computing metrics, community detection and data handling
Post Reply [phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable
fishbacp
Posts:1
Joined:19 Jan 2017 19:51
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable
Betweenness for Weighted Network

Post by fishbacp » 19 Jan 2017 20:15

I'm having a little difficulty determining the method Gephi uses for calculating node betweenness centrality for a weighted, undirected network. As a simple example, I'm looking at a 5 node network with adjacency matrix, A, whose rows are

A=
{0,3,7,0,0}
{3,0,6,0,0}
{7,6,0,2,1}
{0,0,2,0,4}
{0,0,1,4,0}

When the nonzero entries are converted to 1, the betweenness centrality (BC) is easy to compute by hand: Node 3 has BC 8 and the rest are zero. These values are confirmed by Gephi and make sense when one draws the graph itself.

However, when I use the weighted version of the network, Gephi returns the same BC values. This seems counter intuitive to me. If the edge weights are converted to link distances by taking reciprocals, the BC values are 0,0,10,6,0, respectively. That node 4 has a nonzero BC makes sense because the shortest distance path from 3 to 5 must now pass through 4.

I should point out that my intuition is supported by using Matlab's Brain Connectivity Toolbox, which also returns 0,0,10,6,0.

User avatar
eduramiba
Gephi Code Manager
Posts:1064
Joined:22 Mar 2010 15:30
Location:Madrid, Spain
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable

Re: Betweenness for Weighted Network

Post by eduramiba » 19 Jan 2017 23:49

Hi,
The current implemented algorithm does not take edge weight into account: https://github.com/gephi/gephi/blob/mas ... tance.java

Post Reply
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1275: count(): Parameter must be an array or an object that implements Countable