Expand and collapse hierarchy members

Contents[Hide]

1. Overview

This article shows you how to use the Expand and Collapse functionality to see more detailed breakdowns or step back to a summary view.

Examples are shown for tables, charts, and treemaps, and the same functionality is available for relationship diagrams including the tree diagram.

2. Expand and collapse

Expanding a member is similar to performing a Drill Down in-place, without filtering out other members. In the same manner, collapsing a member is similar to performing a Drill Up in-place.

These options are available when selecting data using a multi-level hierarchy, or when multiple hierarchies are selected in the Data Analysis Panel.

2.1. Charts

All of the chart types support the Expand/Collapse option, which is available when you right-click (context menu) a data point.

For example, switch to View mode, right-click the Bikes member in this pie/sunburst chart, and then select Expand.

Expand the Bikes member in this chart
Expand the Bikes member in this chart

The chart now shows an exploded view of that member but the other members are not filtered out. They are still displayed in order to provide context.

Bikes member is expanded into the next level
Bikes member is expanded into the next level

You can continue expanding members, or collapse members using the Collapse option.

Right-click on a member and click Collapse to collapse that member
Right-click on a member and click Collapse to collapse that member

Charts can also display expander buttons similar to those in tables when there is a categorical axis displayed.

2.2. Treemaps

Expand and collapse works similarly for a treemap visualization. Just right-click a treemap node and select Expand.

Right-click on a treemap node and click Expand
Right-click on a treemap node and click Expand

The Bikes node is expanded while leaving the other nodes unchanged. 

Bikes node is expanded
Bikes node is expanded

Right-click the Road Bikes node and click Expand to further expand that node into the next hierarchy level. Or, click Collapse to go back to the original view.

2.3. Tables

Table visualizations support expand and collapse functionality through the use of expander buttons (triangles) in row header and column header cells. These are toggle buttons that can be used to expand or collapse. Alternatively, you can right-click a cell and use Expand or Collapse from the context menu.

Tables have expander buttons in addition to context menu options
Tables have expander buttons in addition to context menu options

If you have a table visualization that displays multiple row hierarchies, and one of the row hierarchies is single-level, you'll still see expander buttons in the corresponding column, as long as the row hierarchy is not the last one. These expander buttons allow you to collapse the other corresponding hierarchy members even though they belong to a separate hierarchy.

Click expander button for single-level hierarchy member in View mode to collapse the other hierarchy too
Click expander button for single-level hierarchy member in View mode to collapse the other hierarchy too

Members of other hierarchy are collapsed too
Members of other hierarchy are collapsed too

If you don't want this functionality, you can disable it (that is, don't show expanders for collapsing one hierarchy into another) by going to the table's Properties. Under the HEADERS section, uncheck the Allow Collapsing Separate Hierarchies property.

Allow Collapsing Separate Hierarchies property
Allow Collapsing Separate Hierarchies property

3. Expand/collapse on click

If you want to be able to simply click on data to expand or collapse it, you can easily set up this interaction for any visualization that supports expanding and collapsing.

When editing, choose Set Up Interactions in the toolbar, and choose Expand / Collapse.

Set up an expand/collapse interaction
Set up an expand/collapse interaction

In the dialog that appears, you typically don't need to change any settings, and you can click the Submit button at the bottom to confirm.

Expand/collapse action dialog
Expand/collapse action dialog

Choose View in the toolbar, and click a data point. If there is data in a hierarchy or level below, it will be expanded; otherwise, it will be collapsed into the hierarchy or level above.

Clicking to expand a pie chart into a sunburst
Clicking to expand a pie chart into a sunburst

4. Collapse all

Every hierarchy has an All or Grand total value above the first level of the hierarchy. You can use the Collapse All option of the context menu to collapse all of the values of the hierarchy you clicked all the way to this level. This can be used to leave out the details of that hierarchy and view the data broken down only by other hierarchy values.

When editing, you can also set a hierarchy to be collapsed this way initially, as follows:

From the Data Analysis Panel, edit the hierarchy.

Edit the hierarchy
Edit the hierarchy

Tick the Collapse All checkbox.

Select the Collapse All option
Select the Collapse All option

Click Submit. The ProductID hierarchy in the visualization will now be initially collapsed to the All value. You or viewers can use the Expand All option from the context menu to view the first level of the hierarchy.

Right-click the cell and select Expand All
Right-click the cell and select Expand All

5. Notes

  • Expanding and collapsing requires the Change Data privilege. This can be disabled for users or groups, on the dashboard or other view, or on the visualization.
  • The Collapse All option may cause a pie chart to disappear if Hide Grand Total is selected in the chart properties. You will still be able to use Expand All from the context menu.
  • Unknown indicates data outside of the hierarchy. This is not a member of the hierarchy and cannot be expanded. You can see data under Unknown by selecting an additional hierarchy or by changing the hierarchy level.
  • Filters applied to the standard hierarchy will be ignored on the expanded members. The filtering will still be maintained on the aggregated hierarchy levels.

6. See also

Dundas Data Visualization, Inc.
500-250 Ferrand Drive
Toronto, ON, Canada
M3C 3G8

North America: 1.800.463.1492
International: 1.416.467.5100

Dundas Support Hours: 7am-6pm, ET, Mon-Fri