4 Replies Latest reply on Jan 29, 2014 12:14 PM by Aaron Clancy

    Creating a downward or glideslope trend line

    Glen Marumoto

      I'm trying to create a glideslope line where the expected results should be for a given time period.  For instance, I have to reduce the number of backlogged files from 250 to 0 in 25 days.  Therefore, I would need a trend line that decreases 10 units per day.  In Excel, I would have charted this series as a line graph with the actual as a bar graph.  Can something similar be created in Tableau?  I've attached a picture of what I'm trying to do.

      Thanks,

      Glen

       

      Tableau Example.bmp

        • 1. Re: Creating a downward or glideslope trend line
          Aaron Clancy

          You'll need data somewhere that represents "Days that haven't happened yet" so that Tableau has a position to draw the projected line.  This could be a date table of ascending days.  There needs to be an outer join to this table and then a filter down to the relevant date window.

          The following was done in Tableau with a parameter called "Start Value" set to 250.

          Screen Shot 2014-01-28 at 10.01.01 PM.png

          The "Projected" calc is:

          [Start Value]-(([Start Value]/size())* (index()-1))

           

          This will create a line that traverses the available dates (where data exists) and increments downward at a rate of 250 divided by # of total days in window.

           

          I tried to avoid including a workbook and just giving you as much detail as possible in the post response because there's just wonky stuff I created to make dummy sales data fit your scenario.

          • 2. Re: Creating a downward or glideslope trend line
            Joshua Milligan

            Aaron Clancy wrote:

             

            You'll need data somewhere that represents "Days that haven't happened yet" so that Tableau has a position to draw the projected line.  This could be a date table of ascending days.  There needs to be an outer join to this table and then a filter down to the relevant date window.

             

             

            I think actually you just need one future date -- so it could be a simple UNION to the current data source or a dummy record that includes the future date and is not filtered out.  Then you can take advantage of Tableau's domain padding to fill in all the dates up to that future date.

             

            Regards,

            Joshua

            • 3. Re: Creating a downward or glideslope trend line
              Aaron Clancy

              My calc is based off of the existence of values across dates. I don't believe padding would work for the approach I've suggested as it is based off of an index value progressing through time.  let me know if we have a different understanding of what you mean by domain padding.

              • 4. Re: Creating a downward or glideslope trend line
                Aaron Clancy

                Disregard that last statement :-) , didn't realize index() increments on empty columns.  Adding one date value with a union would work.