Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I am trying to calculate a rolling average line where the 'average' for a month = (current month + previous month) / 2.
This is depicted by the 'average' row in the screenshot below.
For all intents and purposes, we will say that my expression is Sum(Sales).
Thank you.
hi,
it will be better if you bring previous month sales against current month sales in script.
for that take resident of original table then in month field take it as (month-1)
and with help of key and month field join it to original table this will saves calculations on front end might increase front end calculation performance.
thanks
Mayuresh
May be this
RangeAvg(Before(Sum(Sales), 0, 2))
try something like this:
RangeSum(Sum(Sales),Above(Sum(Sales))) / 2
Close, but not quite
What is missing?
hi,
it will be better if you bring previous month sales against current month sales in script.
for that take resident of original table then in month field take it as (month-1)
and with help of key and month field join it to original table this will saves calculations on front end might increase front end calculation performance.
thanks
Mayuresh
Yes, this will work - thank you.
If your question is now answered, please flag the Correct Answer (via the big "Correct Answer" button near every post; not visible in preview) and Helpful Answers (found under the Actions menu under every post).
If not, please make clear what part of this topic you still need help with .