|
chart.ravenbrook.com (contact: chart@ravenbrook.com) is a server for converting graph specifications into images in either png or pdf format. It's being used to generate all but one of the images you see here. |
|||
|
Here's an example of a graph. It has five nodes (or vertices) and ten edges. |
|
And here's a larger example. Click on the image to see it drawn to a larger scale. |
|
| Both of the above graphs were drawn in circular style - we try to expose the structure of the graph by grouping related nodes and displaying them in circles. This is one of the three layout styles you can use. | |||
|
In the hierarchical style, we place the nodes so that edge sources will be nearer the top of the image than destinations. |
Finally, in spring-embedded layouts you can think of edges as springs and nodes as repelling magnets. |
||
The API for controlling all this is very
straightforward. The image to the right was generated with
this URL:
http://chart.ravenbrook.com/chart? |
|||
|
Five basic parameters define the graph its size, layout style, and output format. Each one is optional (although the image you'll get from drawing a graph which has no nodes or edges won't be very exciting).
|
|||
|
Two further parameters give finer control over node and edge appearance, by defining sequences of "node classes" and "edge classes". Each class has an implicit number, from 0 upwards. The current class number for nodes is initially 0 and this is changed by appending a colon and a number to the end of any node label. So "chl=foo|bar|baz" defines three nodes in class 0; and "chl=foo:42|bar:13|baz" defines one node in class 42 and two in class 13. Edges are configured in exactly the same way with their own sequence of classes. In the class specifications, you can miss components out and get their default values instead, you can abbreviate the values for node shape and edge style (so long as you're not ambiguous), and you can drop trailing commas. A colour is either a name such as green or orange or mediumorchid, or 6 hexadecimal digits representing RRGGBB values (e.g. ff0000 for red). |
|||
|
|||
|
|||
|
Limitations: 16k data for any request; no more than 500 nodes or 500 edges; no more than 1 megapixel for the image. |
|||
|
Your request data will be kept in temporary logs, for no more than one week, to allow us to monitor traffic and debug problems. It will not be made available to anybody else. |
|||
|
Please feel welcome to submit your favourite graphs to the user gallery which we're assembling. We'd be interested to know how useful you find this site, and what might be done to improve it. For example (but not limited to), we might:
By the way, in the last year and partially as a result of user feedback, we've made the following changes: improved spring-embedded layout, node and edge drawing styles and classes, arrowheads on edges, UTF-8 support for character sets beyond Latin-1, and output to pdf. |
|||
|
We'd be really happy to talk to you about other uses for our graph layout and display libraries, and about the licenses under which they might be released. We have support for several features which make more sense in an interactive desktop application, such as the improvements listed above and also:
Click on the lizard. Contact us by writing to chart@ravenbrook.com. |
|
||