0
0
Tableaubi_tool~8 mins

Dynamic measure swap in Tableau - Dashboard Guide

Choose your learning style9 modes available
Dashboard Mode - Dynamic measure swap
Dashboard Goal

Help users compare different sales metrics dynamically by selecting which measure to display in the chart and KPI cards.

Sample Data
RegionProductSalesProfitQuantity Sold
EastWidget100020050
WestWidget150030070
EastGadget120025060
WestGadget130027065
EastDoohickey90018040
WestDoohickey110022055
Dashboard Components
  • Parameter: Choose Measure with options: Sales, Profit, Quantity Sold
  • Calculated Field: Selected Measure with formula:
    CASE [Choose Measure]
    WHEN 'Sales' THEN SUM([Sales])
    WHEN 'Profit' THEN SUM([Profit])
    WHEN 'Quantity Sold' THEN SUM([Quantity Sold])
    END
  • KPI Card: Shows total Selected Measure across all data.
    Example: If 'Sales' selected, KPI shows 7000 (sum of all Sales)
  • Bar Chart: Displays Selected Measure by Region.
    Bars show sum of selected measure per region.
  • Table: Shows Product, Region, and Selected Measure values for detailed view.
Dashboard Layout
+----------------------+----------------------+
|      KPI Card        |      Parameter       |
|  (Total Selected     |    (Choose Measure)  |
|   Measure Value)     |                      |
+----------------------+----------------------+
|                      Bar Chart (Selected Measure by Region)                      |
+-------------------------------------------------------------------------------+
|                         Detailed Table (Product, Region, Selected Measure)     |
+-------------------------------------------------------------------------------+
Interactivity

The Choose Measure parameter lets users pick which metric to analyze: Sales, Profit, or Quantity Sold.

When the parameter changes, the Selected Measure calculated field updates accordingly.

This update refreshes the KPI card, bar chart, and detailed table to show the chosen measure's values.

All visuals stay synchronized, providing a seamless dynamic measure swap experience.

Self Check

If you select Profit in the Choose Measure parameter, what is the total value shown in the KPI card?

Answer: 200 + 300 + 250 + 270 + 180 + 220 = 1420

Which regions show the highest and lowest bars in the bar chart?

Answer: West region has higher total profit (300 + 270 + 220 = 790) than East (200 + 250 + 180 = 630).

Key Result
Interactive dashboard allowing users to swap between Sales, Profit, and Quantity Sold measures dynamically across KPI, bar chart, and table.