Comparing GM % from previous month to YTD GM %

Hi everyone, I have a top movers insight showing the MoM change in GM for the previous month and the month before (for example July to June). I got a request to change the comparison to show the previous month to YTD, I am using a relative date filter but if I change it to YTD it does not work.
Any ideas are welcome!
Curent filter:
image

Thanks in advance!
Eli

Hello @eyagel !

When you used the filter for YTD and it didn’t work, what did the view of the filter look like?

Also, in the field wells are you suing a calculated field to create a column with YTD as an integer?

Just figured it out!
I used minOver(min({Date (Period)}), [{Date (Period)}], POST_AGG_FILTER) for the date
and periodToDateAvg({GM %}, {date}, ‘YEAR’, addDateTime(-1, ‘MM’, now())) for the YTD GM (excluding this month.

Hey @eyagel , that’s excellent, and thank you for sharing the solution with the community!

1 Like