Determining the appropriate layout algorithm

When using the graph layout package, you need to determine which of the ready-to-use layout algorithms is appropriate for your particular needs. Some layout algorithms can handle a wide range of graphs. Others are designed for particular classes of graphs and give poor results or reject graphs that do not belong to these classes. For example, a Tree Layout algorithm is designed for tree graphs, but not cyclic graphs. Therefore, it is important to lay out a graph using the appropriate layout algorithm.
The following tables can help you determine which of the layout algorithms is best suited for a particular type of graph.
  • Across the top of the table are various classifications of different types of graphs.
  • The layout algorithms appear in the first column of the tables.
  • Table cells containing illustrations indicate when a layout algorithm is applicable for a particular type of graph.
By identifying the general characteristics of the graph you want to lay out, you can see from the tables whether a layout algorithm is suited for that particular type of graph.
For example, if you know that the structure of the graph is a tree, you can look at the column headed Domain-independent graphs to see which layout algorithms are appropriate. The Force-directed Layout, Tree Layout, and Hierarchical Layout could all be used. Use the illustrations in the table cells to help you further narrow your choice.
Layout algorithms and common types of graphs
Layout
Domain-independent graphs
Trees
Cyclic Graphs
Any Graph
Force-directed Layout
Example
of uniform tree
Example
of uniform cyclic graph
Preferable to avoid heavily interconnected graphs (large number of links)
Example
of uniform graph
Tree Layout
Example
of tree with orthogonal links
Example
of tree in radial layout mode with aspect ratio 1.5
 
Example
of tree with cycles
Hierarchical Layout
Example
of hierarchical tree
Example
of horizontal hierarchical layout of a cyclic graph
Example
of hierarchical tree with cycles
Short Link Layout
   
Example
of orthogonal links
Long Link Layout
   
Long
link layout
Grid Layout
   
Example
of grid
The algorithm does not take into account the links between the nodes.
Telecom-oriented representations
Layout
Telecom-oriented representations
Circular Layout
Example
of graph with rings and stars
For interconnected ring and star topologies.