1 Reply Latest reply on Aug 5, 2018 5:45 AM by Ankit Bansal

    Previous Year (Avg Calculation)

    Aaron Valleroy

      Good morning community,


      I am struggling to find a working calculation to obtain the average values for the previous year.  Example (Current year is 2018, I would like to have Previous year show (January 2017 through Dec 2017)).  The issue is I am trying to achieve this with the thought in mind that I will also need to look at Rolling 12,6, and 3 months within this same view.  Any assistance would be greatly appreciate. 


      The closest I have come is using the calc below:  However, once I remove the (Cycle M) which contains the Year Dimension the averages are incorrect. 


      I have also attached a picture of the layout I am trying to achieve with the data source.  I am curious if this can be achived in tableau since one dashboard would need to include a YTD, Previous Year, and rolling 12,6, and 3 months views on the same dashboard.)


      IF YEAR([Cycle M])= [Latest Year]






      [Actual] ELSE 0