5 Replies Latest reply on Jan 4, 2017 3:03 PM by Lawrence Chan

    Creating cumulative line chart to include months with no data

    Lawrence Chan

      I have searched Google and Tableau forums but had no success finding a solution. I would like to create a cumulative line chart in Tableau using the data set below. The changes I made to the chart are:

      • Fixed the start date and end date on the x-axis to 01/01/2016 and 12/31/2018, respectively.
      • Created a calculated variable for the y-axis ('Number of records') as an attempt to draw the cumulative line chart -- that failed. The equation I used was 'ZN(SUM( [Number of Records] )'.
      • Formatted the x-axis date to the format 'mmm yy'.

       

      While data only exists for the month of October 2016, can someone show me how to create a cumulative line chart that connects the months of the fixed x-axis (January 2016 to December 2018)?

       

      Thanks in advance for your help.

       

      Data:

      DateNumber of records
      10/1/20161
      10/1/20161
      10/1/20161
      10/1/20161
      10/1/20161
      10/1/20161
      10/1/20161
      10/1/20161
      10/1/20161

       

      Current State of Cumulative Line Chart:

      Current State.jpg

       

      Desired State of Cumulative Line Chart:

      Desired State.jpg