Adjust Edge Length

Extensions and customization
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
User avatar
mortfrog
Posts:5
Joined:02 Jul 2010 15:52
[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
Adjust Edge Length

Post by mortfrog » 06 Jul 2010 15:34

Hi all,

I would like to write a plugin to adjust edge length based on some edge attribute, but I'm not quite sure which part of the program I should extend. I would like still be able to use all of the layout algorithms, and just have length of edges be be adjusted, in the same way that node size is adjusted when applying rankings.

Thanks!

User avatar
mbastian
Gephi Architect
Posts:728
Joined:10 Dec 2009 10:11
Location:San Francisco, CA
[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: Adjust Edge Length

Post by mbastian » 06 Jul 2010 22:36

Hi,

Edge length is determined by the layout algorithm, which takes in account the edge weight, in addition of the force calculation based on topology. By modifying the edge weight, the edge length will vary for layout that use it. ForceAtlas does, but not Yifan Hu.

Is that what you want ?

reyman
Posts:1
Joined:12 Jan 2011 16:20
[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: Adjust Edge Length

Post by reyman » 12 Jan 2011 16:23

Hello !
I have the same problem, i have a length attribute which contain distance between [nodes source] to [nodes target]
There are no tools to fix length between node in gephi with an attribute length ?

User avatar
mbastian
Gephi Architect
Posts:728
Joined:10 Dec 2009 10:11
Location:San Francisco, CA
[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: Adjust Edge Length

Post by mbastian » 12 Jan 2011 17:41

You can do that with the Data Laboratory

Go to the 'Edges' section in the 'Data Laboratory' and do 'Copy data to other column' with the attribute column that contains your numbers. Select 'Weight' as destination column.

That will set the edge weight to the values you want.

alp133sch
Posts:1
Joined:15 Jun 2011 20:31
[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: Adjust Edge Length

Post by alp133sch » 15 Jun 2011 20:33

So does ForceAtlas place nodes with a higher weight closer together or farther apart?

Thanks!

admin
Gephi Community Manager
Posts:964
Joined:09 Dec 2009 14:41
[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: Adjust Edge Length

Post by admin » 15 Jun 2011 20:47

They are closer.

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