26
Time Series Time Series Analysis Analysis Predicting future sales Predicting future sales from past numbers from past numbers

Time Series Analysis Predicting future sales from past numbers

Embed Size (px)

Citation preview

Page 1: Time Series Analysis Predicting future sales from past numbers

Time Series AnalysisTime Series Analysis

Predicting future sales from past Predicting future sales from past numbersnumbers

Page 2: Time Series Analysis Predicting future sales from past numbers

What is it?What is it?

This is not as difficult as it first appears so This is not as difficult as it first appears so do not panic!do not panic!

It is used to forecast future sales from past It is used to forecast future sales from past data. If we have a sales pattern that has data. If we have a sales pattern that has grown like this one ...grown like this one ...

Page 3: Time Series Analysis Predicting future sales from past numbers

Sales

Time

Page 4: Time Series Analysis Predicting future sales from past numbers

Then we can predict the futureThen we can predict the futureSales

Time

N.B. May not always happen!

Page 5: Time Series Analysis Predicting future sales from past numbers

But what if it looked like this?But what if it looked like this?Sales

Time

Page 6: Time Series Analysis Predicting future sales from past numbers

This is where time series analysis This is where time series analysis comes in. comes in.

It ‘irons out’ the peaks and troughs in It ‘irons out’ the peaks and troughs in data to give a roughly smooth line data to give a roughly smooth line which you can then extend into the which you can then extend into the futurefuture

N.B. N.B. The further into the future you go The further into the future you go the less reliable the the less reliable the extrapolationextrapolation becomesbecomes..

Page 7: Time Series Analysis Predicting future sales from past numbers

How does it do this?How does it do this?

It does this by taking an average of figures It does this by taking an average of figures over a time period, for example an over a time period, for example an average of the 4 quarters in a year. Then average of the 4 quarters in a year. Then the first time period is dropped off the the first time period is dropped off the average and the next one is added.average and the next one is added.

Page 8: Time Series Analysis Predicting future sales from past numbers

For exampleFor example

Mon Tues WedMon Tues Wed First numberFirst number

Tues Wed ThursTues Wed Thurs Second numberSecond number

Wed Thurs FriWed Thurs Fri Third numberThird number

Thurs Fri SatThurs Fri Sat Fourth numberFourth number

And so on….And so on….

It is called a It is called a moving average.moving average.

Page 9: Time Series Analysis Predicting future sales from past numbers

Month Actual sales

4 quarter moving average

Jan 10Feb 11Mar 13April 7May 12

10+11+13+7

4

=10.25

For example….It is important that the answer is between feb and March

and not with either one. This is called Centering

Page 10: Time Series Analysis Predicting future sales from past numbers

Then…Then…

Month Actual sales

4 quarter moving average

Jan 10Feb 11Mar 13April 7May 12

11+13+7+12 4 =10.75

10.25

Page 11: Time Series Analysis Predicting future sales from past numbers

And then…And then…Month Actual

sales4 quarter

moving average

Feb 11

Mar 13

April 7

May 12

June 13

13+7+12+13 4 =11.25

10.25

10.75

Page 12: Time Series Analysis Predicting future sales from past numbers

Until…Until…Month Actual sales 4 quarter moving

average

Jan 10

Feb 11

Mar 13

April 7

May 12

June 13

July 16

Aug 6

Sept 13

Oct 15

Nov 16

Dec 9

10.25

10.75

11.25

12

11.75

12

12.512.5

12

Page 13: Time Series Analysis Predicting future sales from past numbers

You can see it leads to a flatter lineYou can see it leads to a flatter line

0

2

4

6

8

10

12

14

16

18

J F M A M J J A S O N D

Actual sales

4 quartermovingaverage

Page 14: Time Series Analysis Predicting future sales from past numbers

If it is still not flat enough…If it is still not flat enough…

Then you can take an average of the Then you can take an average of the moving average (usually only 2 each time)moving average (usually only 2 each time)

This also centres the data for you This also centres the data for you automatically. (So it falls exactly on a automatically. (So it falls exactly on a month and not between two)month and not between two)

Page 15: Time Series Analysis Predicting future sales from past numbers

Like so…Like so…Month Actual sales 4 quarter

moving average

8 quarter moving

ave

Jan 10

Feb 11

Mar 13 10.510.5

April 7 1111

May 12 11.62511.625

June 13 11.82511.825

July 16 11.82511.825

Aug 6 12.512.5

Sept 13 12.512.5

Oct 15 12.2512.25

Nov 16

Dec 9

10.25

10.75

11.25

12

11.75

12

12.512.5

12

Page 16: Time Series Analysis Predicting future sales from past numbers

We can now look into the futureWe can now look into the future

0

2

4

6

8

10

12

14

16

18

J F M A M J J A S O N D j f m a m j j

Actual sales

4 quartermovingaverage

?

Page 17: Time Series Analysis Predicting future sales from past numbers

How accurate?How accurate?

How often did the actual sales coincide How often did the actual sales coincide with the trend?with the trend?

Why should this start to happen in the Why should this start to happen in the future?future?

Page 18: Time Series Analysis Predicting future sales from past numbers

VariationVariation

Calculate the difference between the Calculate the difference between the moving ave figures and the actual moving ave figures and the actual numbers.numbers.

Positive and negatives are important.Positive and negatives are important.

This is why we centred the data!This is why we centred the data!

Page 19: Time Series Analysis Predicting future sales from past numbers

Month Actual sales

4 quarter moving average

8 quarter moving

ave

Variation

Jan 10

Feb 11

Mar 13 -2.5-2.5

April 7 -4-4

May 12 0.3750.375

June 13 1.1251.125

July 16 4.1254.125

Aug 6 -6.5-6.5

Sept 13 0.50.5

Oct 15 2.752.75

Nov 16

Dec 9

10.25

10.75

11.25

12

11.75

12

12.5

12.5

12

10.510.5

1111

11.62511.625

11.82511.825

11.82511.825

12.512.5

12.512.5

12.2512.25

Page 20: Time Series Analysis Predicting future sales from past numbers

Therefore…Therefore…

-2.5-4+0.375+1.125+4.125-6.5+0.5+2.75-2.5-4+0.375+1.125+4.125-6.5+0.5+2.75

88

=-0.515=-0.515

Therefore, on average the actual line is 0.515 below the trend line. So we should allow for this in our extrapolation

Page 21: Time Series Analysis Predicting future sales from past numbers

VariationVariation

Then find the average variation, and just Then find the average variation, and just add (or subtract) it to the extrapolated add (or subtract) it to the extrapolated prediction.prediction.

This will on average cover the variations This will on average cover the variations between the trend and the actual between the trend and the actual numbers.numbers.

Page 22: Time Series Analysis Predicting future sales from past numbers

We can do better We can do better however.however.

Seasonal VariationsSeasonal Variations

Page 23: Time Series Analysis Predicting future sales from past numbers

Seasonal what?Seasonal what?

Many firms have busy and quiet timesMany firms have busy and quiet times

For example….For example….

Page 24: Time Series Analysis Predicting future sales from past numbers

We can take account of thisWe can take account of this

If sales in January are always low then we If sales in January are always low then we can make our predictions more accurate can make our predictions more accurate by taking this into account.by taking this into account.

Instead of working out the variance for all Instead of working out the variance for all time periods we could look at the variance time periods we could look at the variance for Januarys, then Februarys, then all for Januarys, then Februarys, then all Marches and so on.Marches and so on.

Page 25: Time Series Analysis Predicting future sales from past numbers

How?How?

In the same way. Find the average In the same way. Find the average variation for the time you are interested in variation for the time you are interested in and then add it to (or take it away from) and then add it to (or take it away from) your prediction.your prediction.

Page 26: Time Series Analysis Predicting future sales from past numbers

BewareBeware

Past performance does not mean it will Past performance does not mean it will carry on for evercarry on for ever

The further into the future you go the less The further into the future you go the less reliable it becomes.reliable it becomes.