Bird
Raised Fist0
Tableaubi_tool~10 mins

Sets for dynamic grouping in Tableau - Interactive Code Practice

Choose your learning style10 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to create a set that includes all customers with sales over $10,000.

Tableau
IF SUM([Sales]) [1] 10000 THEN 'High Value' ELSE 'Other' END
Drag options to blanks, or click blank then click option'
A>
B=
C<=
D<
Attempts:
3 left
💡 Hint
Common Mistakes
Using <= instead of > causes the set to include customers with sales less than or equal to 10,000.
Using = will only include customers with exactly 10,000 sales.
2fill in blank
medium

Complete the code to create a set that dynamically groups products with sales less than $5,000.

Tableau
IF SUM([Sales]) [1] 5000 THEN 'Low Sales' ELSE 'Others' END
Drag options to blanks, or click blank then click option'
A>=
B>
C=
D<
Attempts:
3 left
💡 Hint
Common Mistakes
Using >= includes products with sales equal or above 5,000, which is incorrect.
Using = only includes products with exactly 5,000 sales.
3fill in blank
hard

Fix the error in the set calculation to group customers with sales between $5,000 and $15,000.

Tableau
IF SUM([Sales]) [1] 5000 AND SUM([Sales]) [2] 15000 THEN 'Mid Value' ELSE 'Other' END
Drag options to blanks, or click blank then click option'
A>=
B<
C>
D<=
Attempts:
3 left
💡 Hint
Common Mistakes
Using > excludes sales exactly equal to 5,000.
Using < for the upper bound excludes sales exactly equal to 15,000.
4fill in blank
hard

Fill both blanks to create a set that groups products with sales between $1,000 and $4,999 inclusive.

Tableau
IF SUM([Sales]) [1] 1000 AND SUM([Sales]) [2] 4999 THEN 'Target Group' ELSE 'Others' END
Drag options to blanks, or click blank then click option'
A>=
B<
C<=
D>
Attempts:
3 left
💡 Hint
Common Mistakes
Using > excludes sales exactly equal to 1,000.
Using < excludes sales exactly equal to 4,999.
5fill in blank
hard

Fill the blanks to create a set that groups customers with sales above $20,000 and orders count greater than 50.

Tableau
IF SUM([Sales]) [1] 20000 AND COUNT([Order ID]) [2] 50 THEN 'Top Customers' ELSE 'Others' END
Drag options to blanks, or click blank then click option'
A>=
B>
C<=
D<
Attempts:
3 left
💡 Hint
Common Mistakes
Using >= includes customers with exactly 20,000 sales or 50 orders, which is incorrect here.
Using < or <= reverses the logic and excludes the intended customers.

Practice

(1/5)
1. What is the main purpose of using Sets in Tableau for dynamic grouping?
easy
A. To group data dynamically based on conditions or manual selection
B. To create static charts without interaction
C. To write SQL queries inside Tableau
D. To export data to Excel automatically

Solution

  1. Step 1: Understand the role of Sets in Tableau

    Sets allow grouping data dynamically, either by user selection or by conditions.
  2. Step 2: Compare with other options

    Options B, C, and D describe unrelated features not related to Sets.
  3. Final Answer:

    To group data dynamically based on conditions or manual selection -> Option A
  4. Quick Check:

    Sets = Dynamic grouping [OK]
Hint: Sets group data dynamically, not static or export tasks [OK]
Common Mistakes:
  • Confusing Sets with filters
  • Thinking Sets export data
  • Assuming Sets create static charts
2. Which of the following is the correct way to create a Set based on a condition in Tableau?
easy
A. Drag measure to Rows shelf and select Create Set
B. Right-click a dimension > Create > Set > Use condition tab to define criteria
C. Use Data > Export > Create Set
D. Write a calculated field with IF statements and save as Set

Solution

  1. Step 1: Recall how to create Sets by condition

    In Tableau, right-click a dimension, choose Create > Set, then use the Condition tab to set criteria.
  2. Step 2: Eliminate incorrect options

    Dragging measures or exporting data does not create Sets; calculated fields are different from Sets.
  3. Final Answer:

    Right-click a dimension > Create > Set > Use condition tab to define criteria -> Option B
  4. Quick Check:

    Create Set via dimension context menu [OK]
Hint: Sets come from dimensions, not measures or exports [OK]
Common Mistakes:
  • Trying to create Sets from measures
  • Confusing calculated fields with Sets
  • Looking for Sets in export menus
3. Given a Set named Top Customers created by condition on Sales > 10000, what will be the result when you drag this Set to Color on a bar chart of Customers?
medium
A. Bars for customers with sales over 10000 will be colored differently
B. All bars will have the same color
C. Only customers with sales under 10000 will be shown
D. The chart will show an error about invalid Set

Solution

  1. Step 1: Understand how Sets affect visualization

    Dragging a Set to Color colors members inside the Set differently from those outside.
  2. Step 2: Apply to the given condition

    Since the Set includes customers with sales > 10000, those bars get a distinct color.
  3. Final Answer:

    Bars for customers with sales over 10000 will be colored differently -> Option A
  4. Quick Check:

    Set on Color = highlights group [OK]
Hint: Set on Color splits members inside/outside group visually [OK]
Common Mistakes:
  • Expecting only Set members to show
  • Thinking all bars get same color
  • Assuming error occurs with valid Sets
4. You created a Set but it does not update when your data changes. What is the most likely cause?
medium
A. Sets never update automatically in Tableau
B. You forgot to refresh the data source
C. You used a measure instead of a dimension to create the Set
D. The Set was created as a fixed Set, not dynamic

Solution

  1. Step 1: Understand Set types in Tableau

    Sets can be fixed (static) or dynamic (condition-based). Fixed Sets do not update with data changes.
  2. Step 2: Identify the cause of no update

    If the Set was created as fixed, it won't reflect new data until manually updated.
  3. Final Answer:

    The Set was created as a fixed Set, not dynamic -> Option D
  4. Quick Check:

    Fixed Sets = no auto update [OK]
Hint: Fixed Sets don't auto-update; use condition Sets for dynamic [OK]
Common Mistakes:
  • Assuming all Sets auto-update
  • Blaming data refresh instead of Set type
  • Trying to create Sets from measures
5. You want to create a dynamic group of products that are either in the Top 10 Sales Set or manually selected by the user. Which Tableau feature allows combining these two Sets for analysis?
hard
A. Create a Calculated Field with IF statements for both Sets
B. Use a Filter to select products from both Sets separately
C. Create a Combined Set using the Union option
D. Create a Parameter to switch between Sets

Solution

  1. Step 1: Understand combining Sets in Tableau

    Tableau allows combining Sets using Union, Intersection, or Exclusion to create a Combined Set.
  2. Step 2: Apply to the scenario

    To include products in either Set, use Union to combine Top 10 Sales and manual selection Sets.
  3. Step 3: Eliminate other options

    Calculated fields or filters do not combine Sets dynamically; parameters switch but don't combine.
  4. Final Answer:

    Create a Combined Set using the Union option -> Option C
  5. Quick Check:

    Combined Set with Union merges groups [OK]
Hint: Use Combined Set with Union to merge dynamic and manual groups [OK]
Common Mistakes:
  • Trying to combine Sets with calculated fields
  • Using filters instead of Combined Sets
  • Confusing parameters with Set combination
Recommended

Ready to prove it?

Pass the test and this pattern moves unknown strong while earning +1 Grip toward your certificate.

10 questions~5 mineasy hard