Guia do Usuário do Cliente Web Spotfire®

Defining hierarchies

When working with hierarchies, you can either create a temporary hierarchy or you can define one. You can edit a temporary hierarchy anytime by adding or removing columns, or by switching the order of the columns.

For an example of a temporary hierarchy, see Hierarchies.

In a defined hierarchy, the columns and their relative positions are fixed. A defined hierarchy is shown in the Data in analysis flyout and behaves like a column. This means that it can be used in any visualization by adding it to an axis.

There are three major ways of defining a hierarchy:

The created hierarchy is associated with a hierarchy filter which becomes available in the Data in analysis flyout and in the Filters panel. For more information, see Using hierarchy filters.

Adding a defined hierarchy to a visualization axis will display a hierarchy slider that makes it possible to easily switch between the levels in the hierarchy.

Example

Suppose you have a defined hierarchy called Sales per year which contains Year/Category/Type. Add this hierarchy to the axis selector of the category axis of a bar chart as you would select a column.

Note: For more clarity, coloring has been applied.


The labels underneath the bar chart state which bars represent the sales for each separate type, but they also show which types are part of which category, and which categories have been sold in a certain year.

There is only one axis selector, unlike in the example where many columns are used on the axes to build a hierarchy. Note that there is a slider on top of the axis selector. This hierarchy slider appears for all defined hierarchies and you can use it to change the level of detail of the visualization. If you drag the handle of the hierarchy slider one step to the left, this is what happens to the bar chart:



The bars are now automatically updated to show the total sales for each category per year, instead of for each type. Dragging the handle yet another step updates the bar chart to show the total sales for each year.