Hello,
I have a data set like below
Logic I need help is ... For each month , we have to compare with previous months.. if current month value is greater than previous month value means, subtract them and return the subtracted value.
If current month value is lesser than previous month means, it should be 0.. Next month comparison should be compared with the previous to Previous month ( which ever month has higher value )
For my above dataset, I need the output like below
Here if you see for Spain.. Feb 23 is ( 55-50 = 5 )
but for India , feb value is lesser than Jan. so its 0. again March value is lesser than Jan.. its should be 0 again. April value is higher than Jan. so ( 90 - 85 = 5 ) for Apr -23 ( India )
Any help on this..