Launch, grow, and unlock your career in data

February 15, 2017

Workout Wednesday: Dynamic Trellis Chart

For Workout Wednesday week 7, I challenge you to build this dynamic trellis chart. Special thanks to Chris Love for explaining to me why the trellis works the way it does. He has a great blog post series over on The Information Lab blog.

In this example, I'm using the same Superstore Sales I've used in previous Workout Wednesdays. Here are the guidelines:

  1. Match my colors.
  2. The user should be able to choose the level of detail they want for the date.
  3. The date axis format should not change, irrespective of the date level chosen.
  4. The user should be able to pick from the list of dimensions shown.
  5. The dimensions should be sorted from upper left to lower right based on the sales in the most recent time period.
  6. Match my tooltips. Note that they change based on the options the user selects. Pay attention to the date formats in particular.
  7. The title should update dynamically based on the date level and dimension selected.
  8. The end of each line should be labeled to the right of the last point. 
  9. There should be a little circle on the end of each line.
  10. Each section of the trellis should include a label for the value of the dimension for that section. E.g., California should be on the upper left when you selected quarters by state.
  11. The dimension labels should be centered in each section.
  12. There should be no gridlines, but the zero line should be included.
  13. Each row should should have a light divider between them.
  14. My final view is 900x700.


  1. Andy,
    This is an awesome example of a trellis. Thanks. Do you have any idea why the field Date has to be treated the way it does? (i.e. as a an attribute on the Columns shelf and also a dimension on the details shelf.) I would think you could just have Date as a continuous dimension on the Columns shelf and leave it off detail, but that causes the row and column table calcs to return incorrect values.

    1. Here is a better description of my question

    2. It has to do with domain padding. To draw the connected line, we need to make sure the dates don't get confused across the other dimensions. Yet we need the date on the detail for the table calc. It's all quite confusing! This post by Chris Love explains it better.

  2. Fresh start this morning helped. I was pulling a constant line from analytics pane and trying to label it. but i see that max rating offset itself is your calculated constant line!