Forum Discussion

smithshire's avatar
smithshire
Frequent Visitor
4 years ago
Solved

Calculate the difference between calculated values in matrix visual

I have a matrix visual which displays a calculated measure of the total spend for each customer for the selected months. The month names are derived from a calendar table. I need to add an addition...
  • amitchandak's avatar
    4 years ago

    smithshire , these are measure then we create measure like

     

    This moth Vs last month

     

    MTD = CALCULATE(AverageX(values('Date'[Date]), calculate(SUM(Table[Qunatity Produced])) ),DATESMTD('Date'[Date]))

    MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD('Date'[Date]))
    last MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(dateadd('Date'[Date],-1,MONTH)))
    last month Sales = CALCULATE(SUM(Sales[Sales Amount]),previousmonth('Date'[Date]))

     

    And we can take diff

     

     

    Select Two period and take diff

    How to use two Date/Period slicers

    https://youtu.be/WSeZr_-MiTg