Question

How to do year-over-year line chart visualizations on a daily grain?

  • 14 October 2015
  • 0 replies
  • 483 views

Userlevel 1

Hi all,


We’re transitioning from an analytics platform where people would commonly create line charts to compare year-over-year data on a daily grain for multiple months, or even entire years. (So, for example, one might chart daily activity for the past 3 months, and then compare that to the same 3 months from the prior year.)


I’m having a bit of trouble reproducing this elegantly in Looker; it’s simple enough for a single month, but it’s more complicated with 2 or more months. I can pivot on the year to create a year data series for a given measure, but since Looker will only accept one date dimension beyond that, the options for creating a visual that contains both month of year AND day of month on the x-axis seem limited.


I’ve got a “Month-Day” dimension that extracts those parts of the date, but because this is a string, the x-axis on my line chart gets rather messy – even when looking at just 3 months and with “Value Density” cranked all the way to the lowest setting (see attached screenshot).



Another option might be creating an entirely separate measure for prior-year data, but this is less desirable, as it has the potential to greatly increase the number of measures in a given explore, and would still not allow for comparisons covering 3 or more years.


What are some other ways to tackle this problem?


0 replies

Be the first to reply!

Reply