Forum Discussion

unnijoy's avatar
unnijoy
Post Prodigy
4 years ago

YOY Sales comparison using graph

I have yearly sales data. Now i am trying to compare the YOY sales and YOY %. But what i need is to reprasent data in Graph. That to based on the Latest month date. 

For example i have the latest month data availabe is for the month of Feb 2022. so i need to show the YOY compariosn for Feb. 

Below graph is wat i am trying to replicate.

 

How can i create this graph is Bi

2 Replies

  • unnijoy , You can create a measure for last year same month

    last year MTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESMTD(dateadd('Date'[Date],-12,MONTH)))

     

    or year behind measure

    Year behind Sales = CALCULATE(SUM(Sales[Sales Amount]),dateadd('Date'[Date],-1,Year))

    Year behind Sales = CALCULATE(SUM(Sales[Sales Amount]),SAMEPERIODLASTYEAR('Date'[Date]))

     

    take of these two measures

    diff% = divide(SUM(Sales[Sales Amount]) - [Year behind Sales] ,[Year behind Sales] )

    • unnijoy's avatar
      unnijoy
      Post Prodigy

      hi amitchandak ,

       

      I got this formula but how to show thin in the graph so that the latest month data will compare with same month last year. Like the graph that is shown  below.