Advanced sorting: hierarchical sorting
Let’s explore how to Sort and Group data along with the creation of Hierarchies. We have used the Sample EU Superstore data set which is provided by Tableau by default. Let’s explore them one by one. Creating Groups on Tableau Simplification of dimension levels into higher level sub-groups is referred to as Grouping. It helps in highlighting of multiple data points or header names. Right click on Category variable from the Dimensions section. Then click on Create from the drop down menu and click on group as shown by the arrows in the diagram below : Select the components in the group. Here, we have selected Furniture and Office Supplies by clicking ‘ctrl’ from the variable Category and then click on ‘Group’ and thereafter ‘OK’. The diagram below shows the step. The group is now created out of Category as pointed by the arrow in the diagram below. Let’s create a visualisation for the same. Drag the group created [Category (group)] from Dimensions section to Columns and Sales from Measures section to Rows and click on bars from ‘Show Me’. The diagram below shows that the graph contains only the components selected in the sub group. Let’s move on to next topic. Sorting of Data The re-organisation of data into a meaningful order for better understanding and analysis of data is known as sorting of data. Data can be sort from the sort options given at the top. Just by clicking on either of the ascending or descending order sort option, the data or the graph can get sort. The below diagram explains the step.We have clicked on the descending sort option and the diagram below shows the result.
We can also do it in a different way. Select Sub Category and Quantity simultaneously and click on Text Tables chart. Then right click on sub category from rows and click on ‘sort’ as shown in the diagram below.
Go to Sort By and click on the little arrow and from the drop down list, click on field. Also, explore the other options as well. The diagram below explains the step. Now click on Descending or Ascending from Sort Order as shown below in the diagram. The values would get arrange in descending order as per the values of Quantity. The diagram below demonstrates the step. Let’s now move on to the last topic, i.e., Hierarchy Hierarchy Right click on Category, select Hierarchy, and click on Create Hierarchy as shown in the diagram below. Again, right click on Sun Category, click on Hierarchy and then click and Add to Hierarchy and then select Category as shown in the diagram below. The Hierarchy of Category and Sub Category is created as shown below in the diagram.