Select Page

More specifically, how to arrange a number of charts by dimension as a table instead of as a row.

For this example, I am arranging donut charts I made using Tableau’s Superstore dataset.

Above is the original chart. As you can see (overuse of donut charts aside), the single row arrangement could be improved. Follow along to see how to do this!

Step 1

We will use calculated fields and parameters to create a Column and Row coordinate for each of our donut charts. In a new Sheet, creating the following Parameter.

As its name suggests, this parameter will dictate our number of columns to arrange the charts by – I have chosen 5.

Step 2

Next, we will create calculated fields for Column and Row, based on the above parameter. First, we need an index to base these on. Create a Calculated Field as follows.

While it may seem useless to create a calculated field just for index, this field is particularly important. It will determine the order of your table (as determined left-to-right and top-to-bottom). If you would like to change the order, use a different function to create your index, such as the RANK() function to order by a particular measure.

Next, create Column and Row calculated fields as follows.

These calculations separate our one index field into columns and rows. The inclusion of -0.01 in the Row calculation is a slight hack; since the INT() function always rounds down, subtracting a small amount from a whole number will cause the INT() function to round it down to the nearest integer.

Step 3

Now to build our Sheet. Place Column and Row on your sheet columns and rows. Convert both to be discrete. Also, place the dimension that you will use to distinguish your charts into the marks tab as a detail. I am using Sub-Category. I have also changed the mark type to pie, since I will be making pie charts. The result should look something like this.

Step 4

Right click your Column and Row dimensions in your respective columns and rows tabs, and for each click “edit table calculation”. Then, use the following settings to create the calculation.

This will compute the Column and Row calculations at the level of the dimension that you want to organise your charts by – I have chosen Sub-Category. This way, the coordinates will be at the right aggregation to act as a table for your charts. The result should look like this.

Step 5

Now all that is left to do is make your chart! I converted these blue circles into donut charts, but your result will depend on your chosen data and chart type. After building the chart, and some removing of borders and axis marks, I get the following result.

And that is all there is to it! If you want to download my tableau workbook to see how I made the donut charts, or to explore the layout, the link to the project in my tableau public gallery is here: How to Arrange Multiple Charts in One Sheet | Tableau Public.