Skip to main content Build the future with Agentforce at TDX in San Francisco or on Salesforce+ on March 5–6. Register now.

Ihr Browser ist zu klein

Bitte ändern Sie die Größe Ihres Browsers, um weiterhin interaktiv lernen zu können. Wir empfehlen eine Breite von mindestens 900 px.

Learning Objectives

  • Configure a dashboard action
  • Modify vizzes to support interactivity
  • Add and configure a filter

Dive Deeper Into Interactivity

Now you've made a dashboard with a single viz and given it some polish and context for the consumer. But one of the most amazing things about visual data analysis in Tableau is interactivity. We have that with tooltips to provide more information, but it can go a lot deeper than that. Let's look at how to make this dashboard interactive.

Check: Connect Your Tableau Public Account

If you haven’t already, or if the playground has timed out, log into your Tableau Public account in the Playground window to the right. If you don’t already have a Tableau Public account, sign up for one now, and be sure to activate your account before starting this interactive unit. You can find more detailed instructions in the Tableau Data Model.

Note

The playground resets if your Tableau Public login session expires or if you refresh the page before completing the unit. We recommend completing this unit in one sitting.

Add Dashboard Actions

Actions tie it all together. These next few steps set up an action so that whenever we hover over baker, it highlights their data in the other vizzes.

  1. Open the Dashboard menu at the top of the workspace and select Actions.
  2. Click the Add Action button.
  3. Then, select Highlight… Why Highlight? The goal is to spotlight related data, not filter anything.
  4. Name the action Baker highlight
  5. Under Source Sheets, uncheck Handshakes so the action only comes from the bakers or the line chart.
  6. Change the selection for Run action on to Hover. This ensures that the highlight only happens if the user hovers over a baker.
  7. Under Target Sheets, leave everything checked so the highlight applies to every viz.
  8. Under Target Highlighting, change the selection to Selected Fields.
  9. For the field options, scroll down and check the box next to Baker. This means the highlighting happens whenever the Baker value matches across vizzes.
  10. Click OK, then click OK again.

Test the highlighting by hovering over a couple bakers and hovering around the line chart. Between the tooltip and the highlighting, you don’t need a name label in the viz to figure out who the line is for. Pretty nifty.

Add an Action to the Handshake

Now that you understand how useful highlight actions are for connecting the dots, wouldn’t it be nice if hovering over a handshake showed which episode that was in the line chart? Easy!

Here's the setup.

  1. Dashboard menu | Actions…
  2. Add Action | Highlight…
  3. Name: Handshake spotlight
  4. Source Sheets: Handshakes
  5. Run action on: Hover
  6. Target Sheets: leave both selected
  7. Target Highlighting: Selected FieldsBaker and Episode. Uh oh, Episode isn’t there.

To configure this properly, we want to highlight when both Baker and Episode are the same. That way, the specific mark in the line chart highlights rather than the whole line. Add Episode to the Handshake viz.

  1. Click OK and click OK again to save what we have for this action.
  2. Using the tabs at the bottom of the screen, go to the Handshakes tab.
  3. From the Data pane, drag Episode to the Detail shelf.

A field must be part of the structure of the viz (for example, on Columns, Rows, or Detail) if it’s going to be used in an action.

  1. Click back to the Baker Performance tab to get back to the dashboard.

Edit an Existing Action

Now go back and finish that half-started action.

  1. Click on the Baker Performance tab.
  2. Dashboard menu | Actions…
  3. Click the Handshake spotlight action in the table.
  4. Then click Edit.
  5. Back in the Target Highlighting section, check the box next to Episode.
  6. Click OK, and OK again.
  7. Hover over each handshake icon to test the action.

It’s a little hard to see when the mark is a yellow star, but when you hover over the handshake for Paul you can see it’s working fine for the Performance in Technical viz. But this is all for a single season.

Add a Filter

Do the vizzes look OK for every season? How do we navigate between seasons, anyway? Time for a filter.

  1. Click into the Performance in Technical viz to bring up its border.
  2. Open the Analysis dropdown menu and select Filters | Season.

By default, the filter control is added to a new container to the right, and it’s formatted as a multiselect list. We want to keep the vizzes from getting cluttered by limiting the filter to just season’s data at a time, and we also want to move the filter to that space we built for it in the last unit.

  1. Click the filter to bring up its border, then open the dropdown menu.
  2. Select Edit title… Adding a verb to the title of an interactive element lets folks know they can take an action.
  3. Replace what’s there with Choose a season:
  4. Click OK.
  5. Open the menu again. Select Customize | uncheck Show "All" Value.
  6. Open the menu again and choose Single Value (slider).
  7. Open the menu again and choose Floating. Now the filter control is set up, but its old container is still messing with the layout.
  8. Click into the white space at the right side of the dashboard to bring up the container's border (it should be blue if you've selected the correct thing).
  9. Then, click the X to remove the element from the dashboard. The vizzes should shift back to fill up the entire space.
  10. Adjust the location of the filter control so it sits well in the white space (whatever looks good to you). Speaking of shifting vizzes and how much space elements take up—it's always a good idea to check that filters don't add odd behavior when their value changes.
  11. Click through the Season filter control and, for each season, check to make sure the three vizzes look OK.

Update Formatting As You Go

Season 9 had the most handshakes and looks a bit crowded. Let's add more room by hiding the viz title.

  1. Right-click the title Handshakes.
  2. Select Hide Title.
  3. With the viz selected, drag the border to make sure the viz is wide and tall enough to not look too crowded.

Without the title, the border lines look a little odd. Turning them off is easy.

  1. Click into the Handshake viz to bring up its border.
  2. Click the Go to Sheet icon Go to Sheet icon .
  3. Open the Format menu and choose Worksheet…
  4. Open the Borders section and turn off the toggle for Row Dividers.
  5. Close the Format pane and click back to the Baker Performance dashboard.
  6. Play with the size and position, checking between season 9 and season 3. Set the filter to season 3 and verify the viz isn't too big when there's only one handshake.

Finding the exact right size and location for this floating viz is a balancing act, but you'll find a way to make it work!

Add Additional Filters

As you test the layout of your dashboard, did you notice there weren’t any handshakes for seasons 1 and 2? And season 1 didn’t have star bakers, either. The dashboard doesn’t look great for those seasons. (And they also had fewer episodes than later seasons.) Let’s filter them out entirely.

You’re already using Season for a filter to keep for a dashboard control, so you’ll need to get creative. Year is a field from the Seasons.csv table that has a single value per season. You can use that as an alternate way to filter out those first two seasons.

  1. Using the tabs at the bottom of the screen, go to the Tracking Star Bakers tab.
  2. Drag Year to the Filters shelf.
  3. Select the checkboxes next to 2010 and 2011
  4. Check the Exclude selected values box. Otherwise you’d keep only those two years rather than filtering them out.
  5. Click OK.
  6. Right-click the Year pill on the Filters shelf to open the menu.
  7. Click Apply to Worksheets | All Using This Data Source. The pill on the filter shelf should now have a data source icon in front of it.

What do we do next? Test the dashboard!

Test the Dashboard

Testing is the name of the game when building dashboards. Test test test.

  1. Click back to the Baker Performance dashboard tab.
  2. Set the filter to season 2 or 1. Oh no, it looks even worse! Now everything is just blank! The data is filtered out but the option to pick those seasons is still there. Hmm. Do we want the Seasons filter to even offer season 1 and 2 as options? Not really. We can hide those with a handy feature of the filter control.
  3. Open the menu for the filter control.
  4. Click Only Relevant Values.

No more pesky seasons 1 and 2 mucking up the works. Season 3 is now the earliest season. (You may have to play with the filter to get it to update.)

Everything looks great! With the filter on season 3, hover over the handshake icon and let that sweet, sweet highlight action tell its story! It looks like Ryan got a handshake in episode 7, but since his line ends there we also know he was eliminated in that episode. A handshake doesn't keep you safe, after all.

Resources