Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

rolling 6 weeks value

Hi Experts,

i have a chart which has dimension as cyclic group that includes Date, hour, month.

i need to calculate numbers of calls received to the corresponding dimension.

i also need to calculate rolling 6 weeks' average calls received based on date selection.

for example,if the date i have selected is monday, then i need to show last 6 monday's average.

Also, this average should only be enabled if the dimension is chosen as Hour.

How can i do this. Please help me.

7 Replies
Anonymous
Not applicable
Author

Defining a Flag at ETL like:

If(weekday(Date)='Mon', 'M',

If(weekday(Date)='Tue', 'T',

and so on..)) as Flag


Then use these Flags value in set expression and something like mentioned in these thread?


Rolling 52 Week Comparison (53-Week Year Problem)

Set Analysis for Rolling Periods

Calculating rolling n-period totals, averages or other aggregations

Not applicable
Author

is it possible to do in the table rather than in script?

vishsaggi
Champion III
Champion III

Do you have a sample app to share which would be easy to work on?

Not applicable
Author

i m trying an expression like this

Sum({<date={">=$(=Weekstart(Max(date), -5))<=$(=Date(Max(date)))"}>} Actualcalls)

but i m not getting expected output.

i think there is problem in weekstart.

if i select the date as 'aug 7' i.e., sunday, then it should calculate last 6 sundays and aug 7.

how to do this. please help

vishsaggi
Champion III
Champion III

= Sum({< date= {"$(= '>=' & Weekstart(Max(date), -5)) and '<=' Date(Max(date)))" } >} Actualcalls)

can you try that ?

Not applicable
Author

no Vish, this is not the expected output

vishsaggi
Champion III
Champion III

Can you share a sample app and expected output please if possible ?