Tableau Bar and Line Charts

Bar charts and line charts are the two most widely used visualizations in business. Tableau builds both in seconds with drag and drop. Knowing when to use each one — and how to customize it — makes your analysis clear and professional.

Bar Charts

A bar chart compares values across categories. Each bar represents one category. The bar's length shows the value of that category. Use bar charts when you compare items that have no natural order — like comparing sales by product category or revenue by department.

Building a Bar Chart

  1. Drag a Dimension (e.g., Category) to Columns
  2. Drag a Measure (e.g., Sales) to Rows
  3. Tableau automatically draws a vertical bar chart

Diagram: Bar Chart Structure

SUM(Sales)
     ^
 1400|        [====]
 1200|                         [====]
 1000|
  800| [====]
  600|
  400|                [====]
     +--------------------------------------------> Category
     Furniture   Office Supplies  Technology   Art

Each bar's height = total sales for that category

Horizontal Bar Chart

Swap Rows and Columns to make bars go left to right instead of up and down. Horizontal bars work better when category labels are long — they prevent the labels from overlapping. Click the Swap Rows and Columns button in the toolbar, or manually drag the fields to the opposite shelves.

Stacked Bar Chart

A stacked bar chart shows parts of a whole inside each bar. Drag a second Dimension to the Color box in the Marks Card. Each bar splits into colored segments — one segment per category value in that second Dimension.

Stacked Bar Example

Sales by Region, split by Product Category:

East | [=Furniture=][=OfficeSupply=][=Technology=]
West | [=Furniture====][=Technology=======]
South| [=OfficeSupply=][=Technology==]

Legend:
  [=Furniture=]     [=OfficeSupply=]     [=Technology=]

Line Charts

A line chart shows change over time. Each point on the line represents a value at a specific time. The line connecting points reveals trends — rising, falling, or flat. Use line charts when the order of items matters, especially with date or time data.

Building a Line Chart

  1. Drag Order Date to Columns
  2. Drag Sales to Rows
  3. Tableau builds a bar chart by default
  4. Click the line chart icon in Show Me, or change the Marks type dropdown from "Automatic" to "Line"

Diagram: Line Chart Structure

SUM(Sales)
     ^
 1400|          *
 1200|        *   *
 1000|      *       *
  800|    *           *
  600|  *               *---*
     +--------------------------------------> Month
     Jan  Feb  Mar  Apr  May  Jun  Jul  Aug

Each * = sales total for that month
Lines connect consecutive months to show trend

Dual-Axis Chart

A dual-axis chart places two different Measures on the same chart, each with its own axis. This helps compare measures that use different scales — for example, Sales in dollars (large numbers) alongside Profit Margin in percentage (small numbers).

Building a Dual-Axis Chart

  1. Drag Sales to Rows
  2. Drag Profit to Rows (a second measure appears)
  3. Right-click the Profit axis and select "Dual Axis"
  4. Both measures now share one chart with two separate axes — one on each side

Diagram: Dual Axis

Left Axis (Sales $)     Right Axis (Profit %)
        ^                           ^
  1400  |  [===Bar===]         40%  |     *--*
  1200  |       [===Bar=]      30%  |  *--      *
  1000  |            [==Bar]   20%  | *            *--*
        +------------------------+  +-------------------+
        Jan  Feb  Mar  Apr  May     Jan  Feb  Mar  Apr  May

Bars = Sales on left axis
Line = Profit % on right axis

Combination Chart (Bar + Line)

In a dual-axis chart, you can make each measure look different. Click the second measure's section in the Marks Card and change its chart type to "Line" while keeping the first as "Bar." This creates a combination chart — common in business reporting.

Labeling Your Chart

Drag any Measure to the Label box in the Marks Card to show values directly on the bars or points. Click the Label box to adjust font size, alignment, and whether labels show for all marks or only min/max values.

Reference Lines on Charts

From the Analytics Pane, drag "Reference Line" onto your chart. Set it to the average, median, or a specific constant value. A horizontal dashed line appears, making it easy to see which bars or points fall above or below a target.

Example: Sales Target Line

SUM(Sales)
     ^
 1400|        [====]
 1200|- - - - - - - - - - (Target: $1,200) - - - -
 1000|
  800| [====]
  600|                [====]
     +--------------------------------------------> Category
     Furniture   Office Supplies  Technology

Summary

Bar charts compare categories using bar length. Line charts show change over time with connected points. Stacked bars show parts of a whole. Dual-axis charts compare two measures side by side using different scales. Reference lines add context like averages and targets. Both chart types start with the same steps — drag a Dimension to Columns and a Measure to Rows — and Tableau handles the visual automatically.

Leave a Comment

Your email address will not be published. Required fields are marked *