FreeMat

- Main Page
- Related Pages

vtkConeLayoutStrategy

Section: Visualization Toolkit Infovis Classes

# Usage

vtkConeLayoutStrategy positions the nodes of a tree(forest) in 3D space based on the cone-tree approach first described by Robertson, Mackinlay and Card in Proc. CHI'91. This implementation incorporates refinements to the layout developed by Carriere and Kazman, and by Auber.

The input graph must be a forest (i.e. a set of trees, or a single tree); in the case of a forest, the input will be converted to a single tree by introducing a new root node, and connecting each root in the input forest to the meta-root. The tree is then laid out, after which the meta-root is removed.

The cones are positioned so that children lie in planes parallel to the X-Y plane, with the axis of cones parallel to Z, and with Z coordinate increasing with distance of nodes from the root.

.SECTION Thanks Thanks to David Duke from the University of Leeds for providing this implementation.

To create an instance of class vtkConeLayoutStrategy, simply invoke its constructor as follows

      obj = vtkConeLayoutStrategy

# Methods

The class vtkConeLayoutStrategy has several methods that can be used. They are listed below. Note that the documentation is translated automatically from the VTK sources, and may not be completely intelligible. When in doubt, consult the VTK website. In the methods listed below, `obj` is an instance of the vtkConeLayoutStrategy class.

- `string = obj.GetClassName ()`
- `int = obj.IsA (string name)`
- `vtkConeLayoutStrategy = obj.NewInstance ()`
- `vtkConeLayoutStrategy = obj.SafeDownCast (vtkObject o)`
- `obj.SetCompactness (float )` - Determine the compactness, the ratio between the average width of a cone in the tree, and the height of the cone. The default setting is 0.75 which (empirically) seems reasonable, but this will need adapting depending on the data.
- `float = obj.GetCompactness ()` - Determine the compactness, the ratio between the average width of a cone in the tree, and the height of the cone. The default setting is 0.75 which (empirically) seems reasonable, but this will need adapting depending on the data.
- `obj.SetCompression (int )` - Determine if layout should be compressed, i.e. the layout puts children closer together, possibly allowing sub-trees to overlap. This is useful if the tree is actually the spanning tree of a graph. For "real" trees, non-compressed layout is best, and is the default.
- `int = obj.GetCompression ()` - Determine if layout should be compressed, i.e. the layout puts children closer together, possibly allowing sub-trees to overlap. This is useful if the tree is actually the spanning tree of a graph. For "real" trees, non-compressed layout is best, and is the default.
- `obj.CompressionOn ()` - Determine if layout should be compressed, i.e. the layout puts children closer together, possibly allowing sub-trees to overlap. This is useful if the tree is actually the spanning tree of a graph. For "real" trees, non-compressed layout is best, and is the default.
- `obj.CompressionOff ()` - Determine if layout should be compressed, i.e. the layout puts children closer together, possibly allowing sub-trees to overlap. This is useful if the tree is actually the spanning tree of a graph. For "real" trees, non-compressed layout is best, and is the default.
- `obj.SetSpacing (float )` - Set the spacing parameter that affects space between layers of the tree. If compression is on, Spacing is the actual distance between layers. If compression is off, actual distance also includes a factor of the compactness and maximum cone radius.
- `float = obj.GetSpacing ()` - Set the spacing parameter that affects space between layers of the tree. If compression is on, Spacing is the actual distance between layers. If compression is off, actual distance also includes a factor of the compactness and maximum cone radius.
- `obj.Layout ()` - Perform the layout.