1 Reply Latest reply on Feb 16, 2016 1:00 AM by Carl Slifer

    Display Average by plotting a reference line across bar chart

    kanchan kamat

      Hello all,


      I have query as below,



      I have to show bar chart for below data


      - Two Dimensions in hierarchical order as Country, Organisation

      - One Measure as Amount Awarded (AA)


      Then I have to show average AA by Country (rather than by Organisation) by plotting a reference line across

      the bar chart showing the average AA


      Can anyone help me with your suggestions please..


      Thanks in advance!

        • 1. Re: Display Average by plotting a reference line across bar chart
          Carl Slifer

          Howdy Kanchan,


          It sounds like you need to use an LOD calculation. This is short hand for Level of Detail. This lets you pick what level of detail for an aggregate to appear in. The way tableau works is when you plot  that average line it finds the average of all the current marks showing in the view this is because whatever is occurring on the rows, columns and marks card effects the underlying query in Tableau.


          Try the following field

          {FIXED [Country] : SUM([AA])}


          Then place this onto the details shelf, you will then use the reference line and in the drop down option for what field to use instead of using AA you will use this new field and then choose to use the average aggregation for the reference line.


          To learn more about LOD check out these fantastic links:

          Top 15 LOD Expressions | Tableau Software

          Tableau Level of Detail Calculated Fields v9 



          Carl Slifer


          1 of 1 people found this helpful