I'd like to write a measure to calculate YOY difference between the current year YTD balance versus previous year YTD balance, and show in the chart like below for the past 5 years (obviously it will not be incremental every month like below, but will show the difference between the YTD current year and the YTD previous year for the past 5 years:
I think I need to modify the measure below so that it will not have the fixed reference of today, but the reference will be the reference year month in the chart and the same period last year.
Sum({$<[Date-Posting Date.autoCalendar.Year] = {$(=Year(Today()))}>}[Expense])-
Sum({$<[Date-Posting Date.autoCalendar.Year] = {$(=Year(Today())-1)}>}[Expense])
I'd appreciate it if anyone could let me know how I can modify the expression above.
Thank you.