4 Replies Latest reply on Jun 19, 2017 6:56 AM by Dan Hoffman

    Bullet graph comparing current period vs previous period

    David Recuero Guerra

      Dear all,

       

      I want to create a bullet graph that compares the current quarter with the previous quarter. It would like similar to the one below - the blue line is the current quarter and the reference lines are the previous quarter amounts. I need these reference lines to be dynamic, so that the graph will update automatically in the future.

       

      Resultado de imagen para bullet graph tableau

       

      Thanks in advance.

       

      David

        • 1. Re: Bullet graph comparing current period vs previous period

          Hey David,

           

          We're going to need more information to be able to give you a helpful response. Would you be able to post a packaged workbook with some sample data, showing what you've already tried?

           

          -Diego

          • 2. Re: Bullet graph comparing current period vs previous period
            David Recuero Guerra

            Hi Diego,

             

            I already added the workbook in the original message. I want to compare my last quarter with the previous quarter (in this case Q4 2016 vs Q3 2016), showing the previous quarter as a reference line on the Q4 bar.

             

            So instead of having two bars, I would only have the Q4 bar, and a reference line of the previous quarter for comparison. Next quarter the graph would change, and I would show Q1 2017 compared to Q4 2016 and so on.

             

            Let me know if there is something that is not clear.

             

            Thanks a lot,

             

            David

            1 of 1 people found this helpful
            • 3. Re: Bullet graph comparing current period vs previous period
              David Recuero Guerra

              Hi everyone,

               

              Any ideas on this topic? Please find in the original message the workbook and description of the problem.

               

              Thanks a lot.

               

              David

              • 4. Re: Bullet graph comparing current period vs previous period
                Dan Hoffman

                Hi David,

                 

                Not sure if this is still an issue for you, but figured I'd give it a go.  See "New" in the attached workbook.

                 

                I created two calculated fields, "This Quarter" to sum the Amount for this quarter and "Last Quarter" to sum the Amount for the previuos quarter. Because the data doesn't line up with the current date anymore I've hard-coded some in the calculated fields.  To make it dynamic, delete "='42016'" from "This Quarter" and remove the "//" in front of one of the lines above it.  If you want to compare to the current period that we're in, use the first line (i.e. on 6/19/17 I want the "current" period to be Q2).  If you want to compare to the last period that has ended, use the second line (on 6/19/17 I want the "current" period to be Q1).  Do the same for "Last Quarter".

                 

                On the "New" sheet I removed your filter and used SUM(This Quarter) instead of SUM(Amount).  This produces the same result as filtering to the current quarter, but allows me to keep all the rows of data so I can also graph the previous quarter. I removed QUARTER(Period) from the Rows shelf to avoid showing empty rows.  I dragged SUM(Last Quarter) to the detail shelf.  Then I added two reference lines, one for the line and one for the shading.

                 

                If you want to add some text to tell the user which quarters are being compared, you could create a couple more calculated fields and throw them in the header or something.  Hopefully this helps!

                 

                Dan

                1 of 1 people found this helpful