Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Best way to calculate 3 month rolling avg? RangeSum? Peek?

Hello,

I need to calculate a 3 month rolling average which will be displayed in a chart (line or bar, undecided).

Basically, the dimension will be monthyear and for example where the chart says "September" the value shown would be the average of the total sales for July, August, and September at a monthly level.

Is it best to do this in an expression in the chart itself maybe using something like rangesum? If so, what would the syntax be like? I am struggling with rangesum.

Or I read somewhere of maybe doing it in the script with "peek"?

Thanks in advance, let me know if more information is required.

1 Reply
Gysbert_Wassenaar

See this document: Calculating rolling n-period totals, averages or other aggregations


talk is cheap, supply exceeds demand