KNOWLEDGE BASE

How To Fix Color Separation Rather Than Gradient in Line Chart


Published: 19 Mar 2020
Last Modified Date: 24 Aug 2022

Issue

When placing ATTR discrete dimension to color in a line chart, the line gets gradient as below. How can I set a fixed color separation?
User-added image

Environment

  • Tableau Desktop

Resolution

A possible workaround to use dual axes of line and circle.
User-added image

Here are steps demonstrated in the attached workbook.
  1. Place Order Date to columns and select continuous year.
  2. Place Sales to rows.
  3. Place Category to color and right click to set to Attribute.
  4. Place one more Sales to columns and right click Dual Axis.
  5. Open SUM(Sales) mark card and remove Category from color.
  6. Open SUM(Sales)(2) mark card and change mark type to Circle.
  7. Right click the right Y axis and click Synchronized Axis.

Cause

The ability to fix color separation in a line chart is currently not build in a product.
 
Did this article resolve the issue?