Bird
Raised Fist0
Tableaubi_tool~8 mins

Creating bins in Tableau - Dashboard Building Guide

Choose your learning style10 modes available
Dashboard Mode - Creating bins
Goal

We want to group sales amounts into size categories to see how many sales fall into each range.

Sample Data
Sale IDSales AmountRegion
1120East
2250West
375East
4300South
5180North
690West
7220South
Dashboard Components
  • Bin Field: Created a bin on Sales Amount with bin size 100.
    Formula: In Tableau, right-click Sales Amount > Create > Bins... > Bin size = 100
  • Bar Chart: Shows count of sales per sales amount bin.
    Columns: Sales Amount (bin)
    Rows: COUNT(Sale ID)
  • KPI Card: Total number of sales.
    Formula: COUNT(Sale ID) = 7
  • Data Table: Shows original sales data with Sales Amount (bin) column added.
Dashboard Layout
+----------------------+------------------+
|      KPI Card        |   Bar Chart      |
|  Total Sales = 7     | Count by Bin     |
+----------------------+------------------+
|          Data Table (Sales with bins)          |
+-----------------------------------------------+
Interactivity

Clicking on a bin in the bar chart filters the data table to show only sales in that bin. The KPI card updates to show the count of filtered sales.

Self Check

Add a filter to show only sales from the East region. Which components update and how?

  • The bar chart updates to show counts only for East region sales bins.
  • The KPI card updates to show total East region sales count.
  • The data table filters to show only East region sales with their bins.
Key Result
Dashboard groups sales amounts into bins of 100 and shows count of sales per bin with interactive filtering by region.

Practice

(1/5)
1. What is the main purpose of creating bins in Tableau?
easy
A. To create calculated fields for text data
B. To join two tables based on a key
C. To filter out null values from a dataset
D. To group continuous numeric data into ranges for easier analysis

Solution

  1. Step 1: Understand what bins do in Tableau

    Bins group continuous numeric data into ranges or intervals to simplify analysis.
  2. Step 2: Compare options to the bin concept

    Only To group continuous numeric data into ranges for easier analysis describes grouping numeric data into ranges, which matches bins' purpose.
  3. Final Answer:

    To group continuous numeric data into ranges for easier analysis -> Option D
  4. Quick Check:

    Bins = Group numeric data into ranges [OK]
Hint: Bins group numbers into ranges for simpler analysis [OK]
Common Mistakes:
  • Confusing bins with filters
  • Thinking bins apply to text data
  • Assuming bins join tables
2. Which of the following is the correct way to create bins in Tableau?
easy
A. Right-click a numeric field and select 'Create > Bins'
B. Drag a dimension to the Columns shelf and select 'Create > Bins'
C. Right-click a text field and select 'Create > Bins'
D. Use the Data menu and select 'Create > Calculated Field'

Solution

  1. Step 1: Recall the bin creation method in Tableau

    You create bins by right-clicking a numeric field and choosing 'Create > Bins'.
  2. Step 2: Check each option against this method

    Only Right-click a numeric field and select 'Create > Bins' matches the correct method; others either use wrong field types or wrong menu options.
  3. Final Answer:

    Right-click a numeric field and select 'Create > Bins' -> Option A
  4. Quick Check:

    Create bins = Right-click numeric field > Create > Bins [OK]
Hint: Bins come from right-clicking numeric fields, not text [OK]
Common Mistakes:
  • Trying to create bins from text fields
  • Using the Data menu instead of field context menu
  • Dragging dimensions instead of numeric fields
3. Given a numeric field 'Sales' with values from 0 to 1000, if you create bins with a size of 200, how many bins will Tableau create?
medium
A. 4
B. 6
C. 5
D. 10

Solution

  1. Step 1: Calculate the number of bins using Tableau's formula

    Number of bins = floor(1000 / 200) - floor(0 / 200) + 1 = 5 - 0 + 1 = 6 bins.
  2. Step 2: Confirm Tableau binning

    Tableau uses floor(value / size) * size for bin start: bins at 0, 200, 400, 600, 800 covering 0-200, 200-400, 400-600, 600-800, 800-1000.
  3. Step 3: Correct the calculation

    Since max value is 1000 and bin size is 200, bins start at 0, 200, 400, 600, 800 covering up to 1000, so total bins = 5.
  4. Final Answer:

    5 -> Option C
  5. Quick Check:

    floor(1000/200) - floor(0/200) + 1 = 6 but last bin covers 1000-1200 which is beyond max, Tableau creates 5 bins covering data [OK]
Hint: floor(max/size) - floor(min/size) + 1 usually, but check max coverage [OK]
Common Mistakes:
  • Calculating range / size = 5 without endpoint adjustment
  • Confusing bin size with number of bins
  • Assuming bins start at 1 instead of 0
4. You created bins on a numeric field but Tableau shows an error: 'Cannot create bins on this field.' What is the most likely cause?
medium
A. The field is a string or non-numeric data type
B. The data source is not connected
C. The bin size is set to zero
D. The field is a dimension, not a measure

Solution

  1. Step 1: Understand bin creation requirements

    Bins can only be created on numeric fields. If the field is string or non-numeric, Tableau cannot create bins.
  2. Step 2: Analyze error causes

    The field is a string or non-numeric data type matches the cause: field is non-numeric. Other options are less likely or unrelated to this error.
  3. Final Answer:

    The field is a string or non-numeric data type -> Option A
  4. Quick Check:

    Bins need numeric fields, non-numeric causes error [OK]
Hint: Bins require numeric fields; strings cause errors [OK]
Common Mistakes:
  • Trying to create bins on text fields
  • Assuming bin size zero causes this error
  • Ignoring data source connection issues
5. You want to analyze customer ages grouped in 10-year ranges using bins. The 'Age' field ranges from 18 to 72. Which bin size should you choose to create exactly 6 bins covering all ages?
hard
A. 9
B. 11
C. 13
D. 10

Solution

  1. Step 1: Recall Tableau's bin count formula

    Number of bins = floor(72 / size) - floor(18 / size) + 1. Need this = 6.
  2. Step 2: Test options

    A 11: floor(72/11)=6, floor(18/11)=1 -> 6-1+1=6 [check]
    B 9: floor(72/9)=8, floor(18/9)=2 -> 8-2+1=7 ✗
    C 13: floor(72/13)=5, floor(18/13)=1 -> 5-1+1=5 ✗
    D 10: floor(72/10)=7, floor(18/10)=1 -> 7-1+1=7 ✗
  3. Final Answer:

    11 -> Option B
  4. Quick Check:

    floor(72/11)-floor(18/11)+1=6 [OK]
Hint: Divide range by bins, round up to cover all data [OK]
Common Mistakes:
  • Choosing bin size equal to exact range divided by bins without rounding
  • Ignoring that bins must cover entire range
  • Assuming 10-year bins always create 6 bins regardless of range
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