Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

cscliffe10x
New Contributor II

Linear Average: Year Comparison

Hello,

I would like to make a linear average line for each of the two years I am comparing on the same chart.  Below I have the current year and prior year trend lines.  I would like a linear average for each of the years.

My current expressions are:

RangeSum(Above(TOTAL Sum({<[Date.autoCalendar.YearsAgo] = {0}>} Amount) ,0,RowNo(TOTAL)))/1000

RangeSum(Above(TOTAL Sum({<[Date.autoCalendar.YearsAgo] = {1}>} Amount) ,0,RowNo(TOTAL)))/1000

And my dimension is:

=Num(Week(Date(Date)-YearStart(Date)+1,00))

LinearTrends.PNG

As a bonus item, I would also like to remove the flat line at the top of the Current Year.  Thank you for your help.

Regards,