Creating a custom hierarchy

Using hierarchies is another way of slicing and dicing our data. This gives us the ability to be able to drill up and drill down into the data at various granularities. We have already seen an example of a default hierarchy in Tableau when we use any Date field.

When we get any Date field in either the Rows or Columns shelf, Tableau automatically aggregates it to the highest possible level. For example, if the date field includes multiple years, the default level is year. But, if the date field contains data for just one year but includes multiple months, then the default level is month.

In our data, if we get the Order Date field in the Rows shelf, then Tableau aggregates it at the Year level and gives us a field called ...

Get Tableau Cookbook – Recipes for Data Visualization now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.