Select a Chart

Select a Chart

//

One of the requests we get quite often is can you set Tableau to have interchangeable charts on a dashboard so that when the user can select which chart to show in a particular place on a dashboard. Whilst not out of the box this is something that is very much possible using parameters and virtual layout containers. Take a look at this example:

The front page visualisation is a dashboard with a single chart on display.  By selecting a chart in the drop down the chart on display is changed. 

How is this achieved?

The technique for achieving this is actually quite straight forward. You will notice there are four other tabs. Three of these are for the charts that are shown on the dashboard. You will also notice that only the chart selected on the front page is shown the other tabs are blank. This is because each graph/tab has a filter linked to the parameter that allows the user to select the chart. The filter on the bar chart is a calculated field that is only true (and therefore only shows data) when the parameter is set to ‘Sales By Customer’. If the calculated field returns a false no data is returned and the visualisation is not rendered.

When I created the dashboard I used a vertical layout container and dropped all three charts into it. A layout container automatically resizes the charts within it based on the amount of data returned. As for two of the charts there is no data they are compressed down and not shown. When the parameter selected is ‘Sales By Customer’ the bar chart filter is true and that chart is returned, the line chart and map filters are false and those charts do not render and are compressed in the layout container. I removed the titles for the two bottom charts in the container and amended the title in the top chart to read the same parameter as the drop down menu so that the title is correct for the chart on display.

Feel free to download this file and have a play, if you have any questions drop them in the comments. Darren

Need Expert Help?

See Our Full Menu of Data Services

InterWorks uses cookies to allow us to better understand how the site is used. By continuing to use this site, you consent to this policy. Review Policy OK

×

Interworks GmbH
Ratinger Straße 9
40213 Düsseldorf
Germany
Geschäftsführer: Mel Stephenson

Kontaktaufnahme: markus@interworks.eu
Telefon: +49 (0)211 5408 5301

Amtsgericht Düsseldorf HRB 79752
UstldNr: DE 313 353 072

×

Love our blog? You should see our emails. Sign up for our newsletter!