Skip to content

Contact sales

By filling out this form and clicking submit, you acknowledge our privacy policy.

Tableau Playbook - Jump Lines

Sep 4, 2019 • 8 Minute Read

Introduction

This is the second part of a two-part series on Tableau Playbook - Step Lines and Jump Lines. In the first part, we delved into the concept and how to build the step lines. Check it out in case you missed it.

In this guide (Part 2), by analyzing a real-life dataset, Rossmann Store Sales, we will practice jump lines and the combination of these two, step by step. Meanwhile, we will draw some conclusions from Tableau visualization.

Jump Lines

In this practice, we will build the jump lines to analyze monthly sales trend grouped by Assortment.

  1. First, we build a continuous line chart which is grouped and colored by "Assortment":

    jump lines - basic process 1

    1. Drag "Date" into Columns Shelf.

    2. Right-click on "YEAR(Date)" on Columns Shelf and change the type to Month from continuous Date Values.

    3. Drag "Assortment" into Rows Shelf.

    4. Drag "Sales" into Rows Shelf.

    5. Measures are aggregated as SUM, by default. But SUM is inappropriate here because the distribution over time is unbalanced for Sales. By analyzing the distribution of Sales, we can also find out the data is skewed. Therefore, MEDIAN is better than AVG.

    6. Drag "Assortment" into Marks - Color.

  2. In this example, we focus on the changes in jump lines, so we can truncate axes and make them range independently for a better view.

    1. Right-click on the y-axis and click Edit Axis...
    2. Uncheck Include zero to truncate automatically.
    3. Select Independent axis range for each row or column in the Range options.

    jump lines - basic process 2

  3. The steps are very similar to those of step lines, except choosing another line type. Expand Path shelf and choose Jump from Line Type.

  4. Here is an optional step. To specific the position of data points, we can show the points on the jump line. Expand Color shelf and choose Effects - Markers to All.

  5. Put on the finishing touches:

    1. Edit the Title to "Monthly Sales Trend by Assortment".
    2. Remove the grid lines and make our data present cleaner: Navigate to Format -> Lines... and set Grid Lines as None in Rows.
    3. Remove both x-axis and y-axis titles in Edit Axis...
    4. Right-click on the x-axis and click Format... Expand Dates in the Scale Option from the Axis tab and choose Custom. Then customize the format as mmm yyyy.

    jump lines - basic process 3

Analysis:

Without connecting to the adjacent points, we can completely focus on the duration of the sales value before it changes. Currently, Tableau doesn't support the forward and backward setting for step and jump lines. So by highlighting the data point on jump lines, we can see the position of current sales value more clearly.

Combination

A better workaround is combining step lines and jump lines together to see the strength of both. Let's Duplicate the previous jump lines and reform on it:

  1. Hold down the Control key (Command key in Mac) and drag "MEDIAN(Sales)" to its right side on the Rows Shelf which means making a copy.

    step lines and jump lines - combination 1

  2. Convert the second view to step lines:

    1. Expand Path shelf and convert back to Step from Line Type.
    2. Remove "Assortment" from the Color shelf because we want to customize the color manually.
    3. In order to weaken the visual effect of step lines, we expand the Color shelf and change the color to light gray.
    4. We don't need the point on step lines, so we set Effects - Markers to None.
  3. Use the dual axis technique to combine jump lines with step lines:

    step lines and jump lines - combination 2

    1. Right-click on the second "MEDIAN(Sales)" and check Dual Axis.
    2. Check Synchronize Axis to synchronize two axes.
    3. We can see the step lines overlap the jump lines. We need to move it to the back. Right-click right y-axis and click Move marks to back.
    4. Since the two y-axes are synchronized, we can hide the right axis by unchecking Show Header.
  4. Expand both Size shelves for these two lines and slide to a more appropriate size.

Here is the final chart:

Analysis:

By using the dual axis technique, this combination chart gives full play to the advantages of step lines and jump lines. Jump lines are represented as colorful lines. They highlight the duration and exact position of a sales value. In the meanwhile, the gray step lines illustrate the magnitude of changes between adjacent sales points.

From the overall shape, we can see that the sales change patterns of "basic" and "extended" stores are comparatively similar, while "extra" stores are very different and their growth rates are much faster.

Conclusion

In this guide, we have learned to draw the jump lines and combination charts. First, we built a group of jump lines to emphasize the duration. On the basis of this chart, we mixed step lines to display the magnitude as well.

You can download this example workbook Line Chart and Variations from Tableau Public.

In conclusion, I have drawn a mind map to help you organize and review the knowledge in this guide.

I hope you enjoyed it. If you have any questions, you're welcome to contact me at recnac@foxmail.com.

More Information

If you want to dive deeper into the topic or learn more comprehensively, there are many professional Tableau Training Classes on Pluralsight, such as Tableau Desktop Playbook: Building Common Chart Types.

I made a complete list of my common Tableau charts serial guides, in case you are interested:

CategoriesGuides and Links
Bar ChartBar Chart, Stacked Bar Chart, Side-by-side Bar Chart, Histogram, Diverging Bar Chart
Text TableText Table, Highlight Table, Heat Map, Dot Plot
Line ChartLine Chart, Dual Axis Line Chart, Area Chart, Sparklines, Step Lines and Jump Lines
Standard ChartPie Chart
Derived ChartFunnel Chart, Waffle Chart
Composite ChartLollipop Chart, Dumbbell Chart, Pareto Chart, Donut Chart