Subway network

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Subway network

Pierrick Doreau
Hello,

Is graphviz adapted to generate a subway network graph correctly ?

I have to generate the graph of the Subway network of Paris. They are about 315 nodes, therefore it doesn't work very well (see files subway.dot and subway.svg). Is a trick exists to get a correct output ?

Thanks.

_______________________________________________
[hidden email]
https://mailman.research.att.com/mailman/listinfo/graphviz-interest

subway.zip (163K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Subway network

Cyril Brulebois
On 02/04/2008, Pierrick Doreau wrote:
> Is graphviz adapted to generate a subway network graph correctly ?
>
> I have to generate the graph of the Subway network of Paris. They are about
> 315 nodes, therefore it doesn't work very well (see files subway.dot and
> subway.svg). Is a trick exists to get a correct output ?

You could try and use neato to render the graph, which should improve
the situation.

I'm sure there are other tricks that you could use to make it even
better, but I'm a bit short of time right now.

Cheers,

--
Cyril Brulebois

_______________________________________________
[hidden email]
https://mailman.research.att.com/mailman/listinfo/graphviz-interest

attachment0 (196 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Subway network

Ken Meltsner
You may want to track down a copy of:

"Automatic visualisation of metro maps" by Seok-Hee Honga, Damian
Merricka, Hugo A.D. do Nascimentob.

http://www.sciencedirect.com/science?_ob=ArticleURL&_udi=B6WMM-4JP9FWT-1&_user=10&_rdoc=1&_fmt=&_orig=search&_sort=d&view=c&_acct=C000050221&_version=1&_urlVersion=0&_userid=10&md5=9c6746cd06067b008345e8703c192bd4

Ken Meltsner
Visualization Dilettante
_______________________________________________
[hidden email]
https://mailman.research.att.com/mailman/listinfo/graphviz-interest
Reply | Threaded
Open this post in threaded view
|

Re: Subway network

Emden R. Gansner
>
> Is graphviz adapted to generate a subway network graph correctly ?

Depending on your definition of correctly, not really. Because of the
inherent geographical nature of the
systems, most algorithms try to simulate the types of layouts seen in
major subway systems, which
attempt to preserve the local geographical relations among stations. The
paper mentioned by Ken is a good
place to start. There was also related work done Brandes and Wagner on
laying out intercity train maps.

    Emden

_______________________________________________
[hidden email]
https://mailman.research.att.com/mailman/listinfo/graphviz-interest
Reply | Threaded
Open this post in threaded view
|

Re: Subway network

Pierrick Doreau
In reply to this post by Cyril Brulebois
Thanks for these advices,

I have tried to use neato instead of dot. Moreover, I added these lines at the begening of my subway.dot :

edge [arrowhead=none];
graph [fontsize=24];
edge  [fontsize=60];
node  [fontsize=24];

The output is not so bad. However, some nodes are overlayed (see subway.svg). How can I "stretch" the center part of the graph ?

Thanks again



_______________________________________________
[hidden email]
https://mailman.research.att.com/mailman/listinfo/graphviz-interest

subway.dot (9K) Download Attachment
subway.svg (213K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Subway network

Sebastien Tricaud-5
Hello Pierrick,

    |
    | The output is not so bad. However, some nodes are overlayed (see
subway.svg).
    | How can I "stretch" the center part of the graph ?
    |

How about adding the following properties to your graph for a better neato
rendering:

overlap="scale";
labelfloat=true;
splines=true;


You may also enjoy using python and gvgen and activate the smart mode to avoid
things like double linking when a node points back and forth to an other node:
http://software.inl.fr/trac/wiki/GvGen#Activatesmartmode


Have fun!
Sebastien.


_______________________________________________
[hidden email]
https://mailman.research.att.com/mailman/listinfo/graphviz-interest
Reply | Threaded
Open this post in threaded view
|

Re: Subway network

Pierrick Doreau
Hello,

overlap="scale";
labelfloat=true;
splines=true;

Ok, indeed, it's much better ! The problems now are :
 * We can't see the text of each node (too small). How to delete nodes and replace them by points ? How to add the text beside theses points (see the attatched png extracted from a real map)
 * with the overlap="scale", 36 minuts are needed to get the output ! Without, it takes only 7 seconds. Is it normal ?

Thanks


_______________________________________________
[hidden email]
https://mailman.research.att.com/mailman/listinfo/graphviz-interest

subway-example.png (17K) Download Attachment