script for getting edges in shortest path

User's perspective on software quality
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
Ramonero
Posts:9
Joined:19 Aug 2013 16:46
[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
script for getting edges in shortest path

Post by Ramonero » 19 Aug 2013 17:02

i am new in this exciting aplication and also i am trying to learn programation languages for being able to do the things i want, but this is going to be a long process i guess.
The first i am trying is to get a list of the edges taking part in a shortest path between 2 nodes in a DIRECTED graph, using scripting console (from scripting plugin).
For example, i would like to define a function shortest_path(v1, v2) and get a list of the edges [e1, e4, e5] that are in this path.
Some help please??

GuillaumeVGeo
Posts:6
Joined:03 Nov 2017 14:17
[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: script for getting edges in shortest path

Post by GuillaumeVGeo » 13 Nov 2017 19:02

Up :)

Is there a particular filter to display only the nodes of the shortest path between two nodes ? With others requests like Ego-network ?

Guillaume

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: script for getting edges in shortest path

Post by eduramiba » 14 Nov 2017 13:00

Hi,
I don't think there is a filter for that, but filters can be extended with plugins.

Start a new plugin: https://github.com/gephi/gephi-plugins
Filter plugins examples: https://github.com/gephi/gephi-plugins- ... ple/filter

GuillaumeVGeo
Posts:6
Joined:03 Nov 2017 14:17
[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: script for getting edges in shortest path

Post by GuillaumeVGeo » 14 Nov 2017 22:01

Thanks for these new tools, they will be helpul.

Anyway that's a bit of a pity that the shortest path can be selected or colored but not to be found with filters.

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: script for getting edges in shortest path

Post by eduramiba » 15 Nov 2017 10:19

Yeah, that would be a great core filter feature. Can you create an issue in github? https://github.com/gephi/gephi/issues

GuillaumeVGeo
Posts:6
Joined:03 Nov 2017 14:17
[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: script for getting edges in shortest path

Post by GuillaumeVGeo » 28 Nov 2017 18:15

Will do :)

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