Weighted edge force directed layout

Oct 22, 2011 at 5:18 PM

Hi Team,

Firstly big kudos to NodeXL team as always - loving it and all the recent developments!

Is there any current functionality or planned functionality for layout algorithm that accomodates weighted edges in the layout so there are unequal forces between nodes based on edge weight?

All the best,

Daniel

Oct 22, 2011 at 6:06 PM

As a matter of fact, yes.  I will be modifying the Fruchterman-Reingold layout to respect an optional Edge Weight column on the Edges worksheet so that edges with higher weight will exert stronger attractive forces on their vertices.  I'm not sure if it will be in the next release (around October 27) or the one after that (about two weeks later).

If you want to be notified of new NodeXL releases, go to the Downloads tab at http://nodexl.codeplex.com/releases and look for "Release Notification."

-- Tony

Oct 25, 2011 at 8:38 AM
Hi Tony,
Great news! Are there also any plans / possibilities for applying a clustering algorithm that respects the edge weights?
Many thanks,
Daniel

Sent from my iPhone

On 22 Oct 2011, at 18:07, "tcap479" <notifications@codeplex.com> wrote:

From: tcap479

As a matter of fact, yes. I will be modifying the Fruchterman-Reingold layout to respect an optional Edge Weight column on the Edges worksheet so that edges with higher weight will exert stronger attractive forces on their vertices. I'm not sure if it will be in the next release (around October 27) or the one after that (about two weeks later).

If you want to be notified of new NodeXL releases, go to the Downloads tab at http://nodexl.codeplex.com/releases and look for "Release Notification."

-- Tony

Oct 25, 2011 at 4:18 PM

Daniel:

The Fruchterman-Reingold change will be in the next release, due out sometime this week.  Changes to the clustering algorithms might be in the following release (two weeks later), depending on how difficult they are to modify.

-- Tony

Oct 25, 2011 at 6:31 PM
Awesome Thank you Tony!

Sent from my iPhone

On 25 Oct 2011, at 16:18, "tcap479" <notifications@codeplex.com> wrote:

From: tcap479

Daniel:

The Fruchterman-Reingold change will be in the next release, due out sometime this week. Changes to the clustering algorithms might be in the following release (two weeks later), depending on how difficult they are to modify.

-- Tony

Jan 15, 2012 at 2:25 PM

Hi Tony,

Has there been any progress with these developments? Could'nt spot them in recent releases.

Many thanks,

Daniel

Coordinator
Jan 15, 2012 at 4:17 PM

We have not yet implemented edge strength aware clustering.  The Fruchterman-Reingold layout now does respect edge weights.

1.0.1.193 (2011-10-27)

  • The Fruchterman-Reingold layout algorithm now uses an optional Edge Weight column on the Edges worksheet to determine the attractive forces between vertices. An edge with a larger Edge Weight exerts a greater attractive force on its vertices. Edge Weight values should be greater than zero. A value of zero or less is ignored and 1.0 is used instead.

Regards,

Marc

Feb 2, 2012 at 5:59 PM

How do I use the Edg Weight in code? I tried to set the weight when I create the edges like this:

  e.SetValue(ReservedMetadataKeys.EdgeWeight, Math.Abs(item.RelationshipValue));

My RelationShipValue is a correlation coefficient between 0.7 and 1. I couldn't really see a difference in the resulting graphs. Do I have to set a special flag for the Fruchterman-Reingold layout to take the EdgeWeight into account?

 

Thanks

Jan

Feb 3, 2012 at 7:02 AM

Jan,

No, it should just work.  The results vary widely with the graph and the edge weights involved.  Your particular range of edge weights is not very large, which I'm guessing is why you're not seeing much of an effect.  You might try transforming your edge weights to a larger range.

-- Tony

Feb 3, 2012 at 5:48 PM

Hi Tony,

I just tried some transformation and I can see some difference. But here is very simple example where I can't see the weigth being applied. https://dl-web.dropbox.com/get/Photos/screenshots/network_0002_C3-ADR1.png?w=9fd7a2d9

Here the correlation values between those vertice:

Ps_Amax_10                     Ps_Transpiration_10              0.702512400400152 
Ps_Amax_10                     Ps_Conductance_10              0.700119863655117  
Ps_Conductance_10         Ps_Transpiration_10               0.998936745166694

I also do scaling of the alpha channel of the edges. So I would expect shorter darker edges and longer lighter edges in my graphs.

Cheers

Jan

 

 

 

Feb 3, 2012 at 9:27 PM

Hi Tony,

which clustering algorithm takes teh edge weight into account?

Cheers

Jan

Feb 4, 2012 at 5:19 AM

Jan:

I can't get to your file and I don't understand what your correlation values mean, but if you'd like to post a simple problematic edge list with edge weights that don't seem to be working for you, I can try those edges in our Excel Template and try to see what's going on.

When I try this simple edge list in the Excel Template, edge CD is much shorter than edge AB, as expected:

A, B, 1
C, D, 100

-- Tony

 

Feb 4, 2012 at 5:23 AM

Jan:

Unfortunately, none of our clustering algorithms currently take edge weight into account.

-- Tony

Feb 4, 2012 at 7:19 AM

This link should work. http://dl.dropbox.com/u/32658643/screenshots/network_0002_C3-ADR1.png

1 : 100 is a pretty large scale. So what would be a good scale have a nice effect on the layout. Correlation values are never bigger than 1.

Feb 6, 2012 at 4:17 PM

Try some experiments, starting with 1:100.

-- Tony