1 Reply Latest reply on Mar 29, 2016 9:35 AM by Dan Sanchez

    Need to produce a production plot with the x axis as a running sum of production time.

    Colin Anderson



      Great forum, new to Tableau and struggling with something, have a had a look through the forums and the chances don't look good with the best suggestion being to pre-structure the data before use within Tableau.  Unappealing, but it would work, so I'm interested in whether there's a Tableau only solution to this.


      I've a set of data depicting:

      Site ID - factory where a product is manufactured

      Prod A/B/C Vol - volume of product produced

      Prod Days - number of days manufacturing was operating

      Prod Period - first day of the month that manufacturing occurred


      The issue is that the production needs to be assessed against the cumulative dayss that the site has been operational rather than calendar date.  I've investigated 'running totals', however the running total can only be used on the y axis and I require this to be on the x axis.  To reiterate, I'm after a line graph with the x-axis as cumulative producing days and the y axis containing the associated production volumes.


      It seems simple enough...



        • 1. Re: Need to produce a production plot with the x axis as a running sum of production time.
          Dan Sanchez

          Hi Colin!


          Thanks for attaching the sample data.  I think the first step is that we need to use Tableau's Pivot function on the Prod Value columns.  After initially connecting to the data source we can pivot these columns like this:

          pivot data.png

          After doing the pivot we can then rename the columns to something a little bit more appropriate:

          rename columns.png

          Once we have the data restructured we can quickly build out a sparkline chart (not sure if this was your desired chart type or not but it seemed fitting given your data ) by bringing Site ID and Production Value onto Rows, and then a Continuous Dimension copy of Days onto Columns.

          prod days dim.png

          The final step is to double-click the Production Value axis and enable the Independent axis range option:

          axis settings.png


          And then voila!  We've got our final viz without needing to do any complicated calculations

          final viz.png


          I've also attached a copy of the workbook.  Hope this helps get you started and welcome to Tableau and the Forums!