Combining multiple dimensions
In this blog I would like to show you how to build a combined field to perform quick calculations over multiple dimensions. Let’s start from an easy example. Let’s say you have 2 or more dimensions and a measure, from which you’d quickly like to perform some aggregations on. Let’s take the dataset of medal counts of athletes from different countries from the 2014 Greek Olympics.
With this data, you’d like to quickly see the overall total number of medals won by athletes who participated in that Olympics. Let’s exclude for a moment the use of calculated fields. Tableau would only show the total n. of medals won: per sport, per country, per sex, but not per all 3 dimensions at the same time.
This is the result you would typically get:
From the view above, it is hard to quickly spot the overall highest n. of medals won by these 3 dimensions.
How to create a Combined Field
So how can you get the overall total no of medals won by the 3 dimensions combined? The Combined Field in Tableau comes to the rescue. The Combined Field creates from different dimensions you select, a cross product of members of these dimensions.
To combine the fields, select multiple dimensions in the Data pane that you want to combine. Then right-click (control-click on a Mac) the fields and select Create > Combined Field.
As a result, you will get a new dimension that is a result of the dimensions you chose to combine. Now you can use this newly created combined fields (dimensions) to visualize your data:
The results are much clearer as a result of using the combined field (in this case a dimension). Now we can easily view the most games played overall, across all 3 dimensions at the first glance. Using the Combined Field can save you time in performing calculations on multiple dimensions.