1 Reply Latest reply on Aug 2, 2018 3:39 AM by jordi.torrecillascardona

    Moderator can remove this thread


      Moderator can remove this thread

        • 1. Re: Standard Deviation in Table data
          Mahfooj Khan



          Is that what you wanted?

          Note: Replace date fields from the calculation. As per sample data there is no date field so I had to create a date field using your week number field.


          Last Week Value:

          IIF(DATETRUNC('week',[Date from Week Number])=

          DATE(DATETRUNC('week',DATEADD('week',-1,{FIXED [Client]:MAX([Date from Week Number])}))),[Calculated Field],NULL)


          Last 8 Weeks Values:

          IIF(DATETRUNC('week',[Date from Week Number])>=

          DATE(DATETRUNC('week',DATEADD('week',-9,{FIXED [Client]:MAX([Date from Week Number])})))

          AND DATETRUNC('week',[Date from Week Number])<

          DATE(DATETRUNC('week',DATEADD('week',-1,{FIXED [Client]:MAX([Date from Week Number])})))

          ,[Calculated Field],NULL)


          % of difference:

          (SUM([Last Week Value])-AVG([Last 8 Weeks Values]))/AVG([Last 8 Weeks Values])


          Here is your output;

          workbook attached for your reference. Let us know if this help.