Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
psenthilbtech
Contributor III
Contributor III

Qlik - Forecasting Based on Previous Year

Hi

I have a scenario, where i have to forecast the data based on the last Year Month Data. Below is the sample data

Qn : With the given data below - i need to forecast the data for Sep-20 till Dec - 2020 (Based on the Months Previous Year Data)

Ex:  For Sept 2020 - I should get the value of Sept 2019, as i dont have the value for Sept 2018

For Oct  2020 - I should get the value of Oct 2019, as i dont have the value for OCt 2018

For Nov 2020 - I should get the Average value of Nov2019 and Nov 2018 and goes on

 

 

MonthPB
Nov-189041
Dec-189747
Jan-199243
Feb-197839
Mar-1913000950
Apr-1910621127
May-1911752534
Jun-1911144306
Jul-199192501
Aug-1910075416
Sep-197092894
Oct-195640611
Nov-194613950
Dec-194557715
Jan-204384742
Feb-204777633
Mar-207893871
Apr-204339084
May-204649449
Jun-205785399
Jul-204760955
Aug-204747258
Sep-20 
Oct-20 
Nov-20 
Dec-20

 

 

 

@sunny_talwar 

 

Regards,

SK

Labels (1)
1 Solution

Accepted Solutions
ashok1203
Creator II
Creator II

3 Replies
chrismarlow
Specialist II
Specialist II

Hi,

If you just need to go back 2 years you could try using above function, so something like following might work;

(alt(above(Sum(Amount),12,0),0)+alt(above(Sum(Amount),24,0),0))/(alt(above(Count(Amount),12,0),0)+alt(above(Count(Amount),24,0),0))

Note you may need to do something different with the denominator (to decide if you are dividing by 1 or 2), depending on how your data is structured.

If you need to go back over time further as this rolls forward, suggest you look at this;

The As-Of Table - Qlik Community - 1466130

Cheers,

Chris.

ashok1203
Creator II
Creator II

 
AAK
AT_7
Contributor III
Contributor III

Can you post solution or script here instead of QVW . That will be really helpful