Part 9 Add a drilldown

Focus your data for one particular game across different visualizations with an interactive token. For this part of the tutorial, add a drilldown by setting a token on the pie chart.

  1. Select the pie chart visualization. Then, select + Add Drilldown in the Drilldown Settings section of the Configuration panel.
  2. In the On Click dropdown, select Set Tokens.
  3. Select + Set Another Token.
  4. Give your token the following name and values:
    1. Token Name: game
    2. Token Value: row.Game.value
    3. Default Value: SIM Cubicle
  5. Select Apply.
  6. In the configuration panel, change the pie chart's title to Revenue for $game$.
  7. Change the description to Select a game to display revenue.
  8. In the visual editor, select Save then View.
  9. Select a game from the pie chart and see the title update. The token sets when you select a specific slice of the pie chart.
  10. Return to Edit mode by selecting Edit in the top right corner.
  11. Select the single value visualization.
  12. In the Data Configurations section, select the edit icon (A pencil as an icon.) next to the Total Revenue data source.
  13. Add your drilldown token to the search by copying and pasting the following SPL before |stats sum(Revenue) as "Total Revenue":
    | search Game="$game$" 
    
  14. Select Apply & Close.
  15. Select the markdown inside the hole of the pie chart above the single value.
  16. Change the text box to #### Revenue.
  17. Select the pie chart. Then, select the layer icon (A cube made of three separate stacked layers from top to bottom.) and choose Bring to Front.

After completing Part 9, your dashboard looks similar to this: A dashboard with input dropdowns, a table chart, and a pie chart. A game on the pie chart is selected which highlights the slice of data for that game.