I am looking to do a YoY%, MoM% and QoQ% difference for the following data which has separate columns for ‘Year’ and ‘Month’ in Integer format.
I tried to use the ‘periodOverPeriodDifference’ but it accepts the ‘DateTime’ format in the function parameter. Any inputs on how I could do this or if I can use any other function?
But I see blank values for YoY% in the output as shown below. I see in the example doc, we also have to groupBy the Date, but I don’t see the ‘Group By’ option in the Field wells. Is there anything else I need to do apart from the two formulas to get this working?
Hi Kellie, thanks for checking on this. The periodOverPeriodPercentDifference() is working for YoY% differences but I am trying to find out the MoM% and QoQ% differences between the latest 2 months and latest 2 quarters in the dataset respectively. The output should look something like the MoM and QoQ columns in the screenshot.
If you want MoM or QoQ for all months or quarters respectively, then you can use that same periodOverPeriodPercentDifference() function. If you only want the most recent MoM or QoQ, you will need to calculate current month and previous month and then calculate percent difference. I worked up an example of each for MoM in the screenshot provided. QoQ will work the same way. You can also reference this link to help with these types of calculations.