Forum Discussion

jovendeluna21's avatar
jovendeluna21
Icon for Helper IV rankHelper IV
4 years ago
Solved

Dynamic Rolling Average & Sum based on Slicer Selection

Hello, Any idea  on how a dynamic rolling average and spend be dynamic based on slicers? I just noticed that the numbers do not change when I use different slicers such as World Area, Commodity, et...
  • amitchandak's avatar
    4 years ago

    jovendeluna21 , With help from the date table, measures like example measure should help

     

    Rolling 30 = calculate(AverageX(Values('Date'[Date]),CALCULATE(sum(Sales[Sales Amount]))),DATESINPERIOD('Date'[Date ],MAX('Date'[Date ]),-30,DAY))