3 Replies Latest reply on Apr 11, 2013 8:48 PM by Dimitri.B

    Multiple Reference Lines in a Bullet Graph

    J G

      I have a budget bar graph that shows budget by branch by spend type. A reference line that shows the remaining amount after a budget cut which changes based on a parameter. The reference line is used to show the amount cut using total(sum([amount remaining after cut])). Ultimately I would like to create multiple parameters that allow me to adjust amount (or percentage) cut by branch by spending type. Whenever I try to get multiple bars I end up getting one across the entire graph instead of just each bar, or it will just be one bar, or it will just error out.


      I referenced this: http://community.tableau.com/thread/111337

      to get me this far but I have become stuck.


      Any help would be appreciated.

        • 1. Re: Multiple Reference Lines in a Bullet Graph

          Are you aware of the scope control for reference lines?


          ref line controls.png


          Just checking the basics first, in case it slipped your attention (happens all the time with most people).

          • 2. Re: Multiple Reference Lines in a Bullet Graph
            J G

            Hey Dimitry,


            Thank you for your response. Yes I am aware of the scope control. If I select per cell it will add every spend type's amount cut to ever spend type. So each one would have would have all of the other cut amounts. I have changed it to that in the attached work book for your convencience.


            I guess I would like to control which shows up where? or some sory of parameter to make the approiate line show up for the approriate bar?


            Again I appreaciate your help.

            • 3. Re: Multiple Reference Lines in a Bullet Graph

              Then I suggest that instead of making calculated fields for each type, you make one for all types, using IF statement that will apply relevant amounts of cut, like the one below (add your remaining types using the same pattern). This way you only need one reference line, and it will apply the right calculation based on the type, and will show nothing if there is no cut for that type, rather than 0 and a redundant label.



                  [Spend Type] = "Equipment" then ([Budget]-[Spent])*(1-[Equipment Amount Cut])


                  [Spend Type] = "Labor" then ([Budget]-[Spent])*(1-[Labor Amount Cut])

              //etc. - add remaining types here

              ELSE Null