Anda di halaman 1dari 74

FORECASTING

DR. MOHAMMAD ABDUL MUKHYI, SE., MM

6/3/2008

Apa Arti Runtut Waktu?


Data runtut waktu (time series) merupakan data yang
dikumpulkan,
p
, dicatat,, atau diobservasi sepanjang
p j g
waktu secara berurutan
Periode waktu dapat tahun, kuartal, bulan, minggu,
dan dibeberapa kasus hari atau jam.
jam
Runtut waktu dianalisis untuk menemukan pola
yang
g dapat
p dipergunakan
p g
untuk:
variasi masa lalu y
(1) memprakirakan nilai masa depan dan membantu
dalam manajemen operasi bisnis;
(2) membuat perencanaan bahan baku, fasilitas
produksi, dan jumlah staf guna memenuhi
permintaan
pe
taa d
dimasa
asa mendatang.
e data g
6/3/2008

Mengapa
g p Mempelajari
p j Analisis
Runtut Waktu?
Karena dengan
K
d
mengamati
ti data
d t runtut
t t waktu
kt akan
k
terlihat empat komponen yang mempengaruhi suatu
pola data masa lalu dan sekarang, yang cenderung
berulang dimasa mendatang

6/3/2008

Teknik Forecasting
Pendekatan Basis

Teknik

Hasil

Peramalan
ekstrapolatif

Ekstrapolasi
trend

Analisis rangkaian-waktu
Teknik benang-hitam
Teknik OLS
Pembobotan eksponensial
Transformasi data
Metode katastrofi

Projeksi

Peramalan
Teoretis

Teori

Pemetaan teori
Analisis jalur
Analisis Input
Input-Output
Output
Pemrograman linier
Analisis regresi
Estimasi interval
Analisis hubungan

Prediksi

Peramalan
intuitif

Penilaian
subjektif

Delphi konvensional
Delphi kebijakan
Analisis dampak-silang
Penilaian kelayakan

Konjektur

6/3/2008

Asumsi Peramalan Ekstrapolatif


1. Keajegan (persistence): Pola yang terjadi di
masa lalu akan tetap terjadi di masa
mendatang. Mis: jika konsumsi energi di masa
lalu meningkat, ia akan selalu meningkat di
masa depan.
2 Keteraturan (regularity): Variasi di masa lalu
2.
akan secara teratur muncul di masa depan.
Mis: jika banjir besar di Jakarta terjadi setiap
16 tah
tahun
n sekali,
sekali pola yg
g sama akan terjadi lagi
lagi.
3. Keandalan (reliability) dan kesahihan (validity)
data: Ketepatan
p
ramalan tergantung
g
g kepada
p
keandalan dan kesahihan data yg tersedia.
Mis: data ttg laporan kejahatan seringkali tidak
sesuai dg insiden kejahatan yg sesungguhnya,
data ttg gaji bukan merupakan ukuran tepat
6/3/2008
5
dari pendapatan masyarakat.

Klasifikasi Metode Peramalan


Forecasting Method
Subjective (Judgmental)
Forecasting Methods

Objective
Forecasting Methods
Time Series
M th d
Methods

Causal
Methods
M
th d

Analogies

Nave Methods

Simple Regression

Moving Averages

Multiple Regression

Exponential Smoothing

Neural Networks

Delphi
PERT

Simple Regression

Survey techniques

ARIMA
Neural Networks

References :
Combination of Time Series Causal Methods





6/3/2008

Intervention Model
Transfer Function (ARIMAX)
VARIMA (VARIMAX)
Neural Networks






Makridakis et al.
Hanke and Reitsch
Wei, W.W.S.
B
Box,
JJenkins
ki and
d Reinsel
R i
l

Ilustrasi
M d l Matematis
Model
M
i

Klasifikasi Metode Peramalan :

Forecasting Method

Objective
Subjective
(Judgmental)
Examples :
sales
l
= f (price
( i
, advert
d
t , ))
Forecasting Methods Forecasting Methods
Examples :
sales
l (t) = f (sales
( l (t-1), sales
l (t-2), ))

(t)

(t)

(t)

Combination of Time Series Causal Methods


Yt= f (Yt-j , j>0 ; Xt-i , i 0)

Examples :
Time Series Methods
Causal
Methods
, advert , advert
, )
sales = f (sales
(t)

Yt= f (Yt-1, Yt-2, , Yt-k)


6/3/2008

(t-1)

(t)

(t-1)

Yt= f (X1t, X2t, , Xkt)


7

Klasifikasi Model Time Series : Berdasarkan


B MODELS
Bentuk
t k atau
t Fungsi
F
i
TIME SERIES
LINEAR
Time Series Models

NONLINEAR
Time Series Models

ARIMA Box-Jenkins

Models from time series theory


nonlinear autoregressive, etc ...

Intervention Model

Flexible statistical parametric models


neural network model, etc ...

Transfer Function (ARIMAX)

State-dependent, time-varying parameter and long-memory models

VARIMA (VARIMAX)

References :
 Timo Terasvirta, Dag Tjostheim and Clive W.J. Granger, (1994)
Aspects of Modelling Nonlinear Time Series

6/3/2008
Handbook of Econometrics, Volume IV, Chapter 48.
Edited by R.F. Engle and D.I. McFadden

Nonparametric models

Models from economic theory

6/3/2008

6/3/2008

10

6/3/2008

11

6/3/2008

12

6/3/2008

13

MODEL
O
PERAMALAN RUNTUT
U U WAKTU
U
DENGAN ATAU TANPA TREN
RUNTUT
U U WKATU
U
EXPONENTIAL
SMOOTING
MENGANDUNG
UNSUR TREND

TIDAK

MOVING
AVERAGE

YA

TREND LINEAR

6/3/2008

TREND
KUADRATIK

TREND
EKSPONENSIAL

MODEL
AUTOREGRESIF

14

Empat komponen yang ditemukan dalam analisis


runtut waktu adalah:
1. Trend, yaitu komponen jangka panjang yang
mendasari p
pertumbuhan ((atau p
penurunan)) suatu data
runtut waktu.
2. Siklikal (cyclical), yaitu suatu pola fluktuasi atau
siklus dari data runtut waktu akibat perubahan
kondisi ekonomi.
3. Musiman (seasonal), yaitu fluktuasi musiman yang
sering
i dijumpai
dij
i pada
d data
d t kuartalan,
k
t l
b l
bulanan
atau
t
mingguan.
4. Tak beraturan (irregular), yaitu pola acak yang
disebabkan oleh peristiwa yang tidak dapat diprediksi
atau tidak beraturan, seperti perang, pemogokan,
pemilu,, atau longsor
p
g
maupun
p
bencana alam lainnya
y
6/3/2008

15

General of Time Series Patterns


Time Series
S
Patterns

Stationer

9 Nonseasonal
Stationaryy models

6/3/2008

Trend Effect

Seasonal Effect

9 Nonseasonal
Nonstationaryy models

9 Seasonal and
p
models
Multiplicative

Cyclic Effect

9 Intervention
models

16

Time Series Analysis


Deret berkala adalah suatu pengamatan atas suatu
kumpulan variabel kuantitatif dari waktu ke waktu.
waktu
Contoh
angka indeks rata-rata industri Dow Jones
data historis penjualan,
penjualan persediaan,
persediaan jumlah pelanggan,
pelanggan
tingkat bunga, biaya-biaya, dan lain-lain
Dunia Bisnis sangat tertarik akan peramalan dengan
mengunakan variabel berkala
Sering, bahwa variabel independen adalah tidak tersedia
untuk membangun model regresi dari variabel deret
berkala
Dalam analisis deret berkala, kita meneliti perilaku dari
suatu variabel masa lalu dalam rangka meramalkan
perilakunya.masa
depan
6/3/2008
17

Pola data
General Time Series PATTERN
Stationer
St ti
Trend (linear or nonlinear)
Seasonal (additive or multiplicative)
Cyclic
Calendar Variation

6/3/2008

18

Pendekatan Analisis Deret Berkala


Ada banyak teknik deret berkala.
I i biasanya
Ini
bi
mungkin
ki untuk
t k mengetahui
t h i teknik
t k ik mana
yang terbaik untuk data tertentu.
Biasanya mencoba beberapa teknik berbeda dan
memilih salah satu terbaik.
Untuk menjadi suatu model deret berkala yang efektif,
ini harus menyediakan beberapa teknikderet berkala di
dalam tool box.

6/3/2008

19

Measuring Accuracy
We need a way to compare different time series
techniques for a given data set.
Four common techniques are the:

$
Yi Y
i
n

Yi Yi

mean absolute deviation,

MAD =

i =1
=1

100
mean absolute percent error, MAPE =

n i =1

Yi

2
$
Yi Yi )
(
MSE =
n
i =1
n

the mean square error,


root mean square error.
6/3/2008

RMSE =

MSE

We will focus on the MSE.

20

Extrapolation Models
Extrapolation models try to account for the past
behavior of a time series variable in an effort to
predict
di t th
the ffuture
t
behavior
b h i off th
the variable.
i bl

$ = f (Y , Y , Y ,K)
Y
t +1
t
t 1
t 2
Well
ll first
f
talk
lk about
b
severall extrapolation
l
techniques that are appropriate for stationary data.

6/3/2008

21

An Example
Hasil produksi padi Indonesia dari tahun 1970
sampai tahun 2008 sampai bulan Mei.
Hasil produksi ini berdasarkan musiman
Ada 39 tahun

6/3/2008

22

tahun
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
6/3/2008

produksi padi
18 693 649
18.693.649
20.483.687
19.393.933
21.490.578
22.476.073
22.339.455
23.300.939
23.347.132
25.771.570
26.282.663
29.651.905
32 774 176
32.774.176
33.583.677
35.303.106
38.136.446
39 032 945
39.032.945
39.726.761
40.078.195
41.676.170
44.725.582

tahun
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008

produksi padi
45 178 751
45.178.751
44.688.247
48.240.009
48.181.087
46.641.524
49.744.140
51.101.506
49.377.054
49.236.692
50.866.387
51.898.852
50 460 782
50.460.782
51.489.694
52.137.604
54.088.468
54 151 097
54.151.097
54.454.937
57.051.679
58.268.796
23

6/3/2008

24

Moving Averages
Y
+
Y
+
Y
t
t-1
t- k +1
$
Yt +11 =
k
No general method exists for determining k.
We must try out several k values to see what works
best.

6/3/2008

25

Implementing the Model

6/3/2008

26

A Comment on Comparing MSE Values


Care should be taken when comparing MSE
values of two different forecasting techniques.
techniques
The lowest MSE may result from a technique that
fits older values very well but fits recent values
poorly.
It is sometimes wise to compute the MSE using
only the most recent values.

6/3/2008

27

Forecasting With
The Moving Average Model
Forecasts for time periods 25 and 26 at time period 24:

Y24 + Y23 36 + 35
$
Y25 =
=
= 355
.
2
2
$ +Y
Y
35 5 + 36
35.5
25
24
$
Y26 =
=
= 35.75
2
2

6/3/2008

28

Weighted Moving Average


The moving average technique assigns equal
weight to all previous observations
1
1
1
$
Yt +1 = Yt + Yt-1 +L+ Yt- k -1
k
k
k
The weighted moving average technique allows
for different weights to be assigned to previous
observations.
b
ti
$ = w Y + w Y +L+ w Y
Y
t +1
1 t
2 t-1
k t- k -1
where
h 0 wi 1 and
d

=1

We must determine values for k and the wi


6/3/2008

29

Forecasting With The Weighted


Moving Average Model
Forecasts for time p
periods 25
5 and 26
6 at time p
period 24:

Y25 = w1Y24 + w2 Y23 = 0.291 36 + 0.709 35 = 35.29


Y26 = w1Y25 + w2 Y24 = 0.291 35.29 + 0.709 36 = 35.79

6/3/2008

30

Exponential Smoothing
$ =Y
$ + (Y Y
$ )
Y
t +1
t
t
t
where 0 1
It can be shown that the above equation is equivalent to:

$ = Y + (1 ) Y + (1 ) 2 Y +L+ (1 ) n Y +L
Y
t +1
t
t 1
t 2
t n

6/3/2008

31

Examples of Two
Exponential Smoothing Functions
42
40

Un
nits Sold

38
36
34
32
Number of VCRs Sold
Exp. Smoothing alpha=0.1

30

Exp. Smoothing alpha=0.9

28
1

9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25

Time Period
6/3/2008

32

Implementing the Model

6/3/2008

33

Forecasting With The


Exponential Smoothing Model
Forecasts for time p
periods 25 and 26 at time p
period 24:
=Y
+ (Y Y
) = 35.74 + 0.268(36 35.74) = 35.81
Y
25
24
24
24
=Y
+ (Y Y
)Y
+ (Y
Y
)=Y
= 35.81
Y
26
25
25
25
25
25
25
25

Note that,

$ = 35.81, for t = 25, 26, 27, K


Y
t

6/3/2008

34

6/3/2008

35

Seasonality
Seasonality is a regular, repeating pattern
in time series data.
May
y be additive or multiplicative
p
in
nature...

6/3/2008

36

Stationary Seasonal Effects


Additive S easonal Effects

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

18

19

20

21

22

23

24

25

Tim e Pe r iod

Multiplicative S easonal E ffects

10

11

12

13

14

15

16

17

T im e Pe r io d

6/3/2008

37

Stationaryy Data With


Additive Seasonal Effects
where

Y
t + n = E t + St + n p

E t = (Yt - St-p ) + (1- )Et 1

St = (Yt - E t ) + (1- )St p


0 1
0 1
p represents the number of seasonal periods

Et is the expected level at time period t.


St iis the
th seasonall factor
f t for
f time
ti period
i d t.
t
6/3/2008

38

Implementing the Model

6/3/2008

39

Forecasting With The Additive


Seasonal Effects Model
Forecasts for time p
periods 25 to 28 at time p
period 24:

Y
24+ n = E 24 + S24+ n 4
= E + S = 354.44 + 8.45 = 363.00
Y
25
24
21
= E + S = 354.44 17.82 = 336.73
Y
26

24

22

= E + S = 354.44 + 46.58 = 401.13


Y
27
24
23
= E + S = 354.44 31.73 = 322.81
Y
28
24
24
6/3/2008

40

Stationaryy Data With


Multiplicative Seasonal Effects
where

Y
t + n = E t St + n p

E t = (Yt /Stt-pp ) + ((1- ))Et 1

St = (Yt /E t ) + (1- )St p


0 1
0 1
p represents the number of seasonal periods

Et is the expected level at time period t.


St is the seasonal factor for time period t.
6/3/2008

41

Forecasting With The Multiplicative


Seasonal Effects Model
Forecasts for time periods 25 to 28 at time period 24:

Y
24+ n = E 24 S 24+ n 4
= E S = 353.95 1.015 = 359.13
Y
25
24
21
= E S = 354.44 0.946 = 334.94
Y
26
24
22
= E S = 354.44 1.133 = 400.99
Y
27
24
23
= E S = 354.44 0.912 = 322.95
Y
28
24
24
6/3/2008

42

Trend Models
Trend is the long-term sweep or general
direction of movement in a time series.
Well now consider some nonstationary time
series techniques that are appropriate for
data exhibiting upward or downward trends.

6/3/2008

43

An Example
p
WaterCraft Inc. is a manufacturer of personal
water crafts (also known as jet skis)
skis).
The company has enjoyed a fairly steady
growth in sales of its products
products.
The officers of the company are preparing sales
and
a
d manufacturing
a u actu g p
plans
a s for
o tthe
e co
coming
g yea
year.
Forecasts are needed of the level of sales that
the company
p y expects
p
to achieve each q
quarter.
See file

6/3/2008

44

Double Moving
g Average
g

Y
t + n = E t + nTt
where

E t = 2M t D t
Tt = 2(M t D t ) /(k 1)
M t = (Yt + Yt 1 + L + Yt k +1) / k
D t = (Mt + Mt 1 + L + Mt k +1) / k

Et is the expected base level at time period t.


Tt is the expected trend at time period t.
6/3/2008

45

Forecasting With The


Double Moving Average Model
Forecasts for time p
periods 21 to 24 at time p
period 20:

Y
20+ n = E 20 + nT20
= E + 1T = 2385.33 + 1139.9 = 2525.23
Y
21
20
20
= E + 2T = 2385.33 + 2 139.9 = 2665.13
Y
22
20
20
= E + 3T = 2385.33 + 3 139.9 = 2805.03
Y
23
20
20
= E + 4T = 2385.33 + 4 139.9 = 2944.94
Y
24
20
20
6/3/2008

46

Double Exponential Smoothing


(Holts
(Holt
s Method)

Y
Tt
t + n = E t + nT
where
Et = Yt + (1-)(Et-1+ Tt-1)
Tt = (Et Et-1) + (1-) Tt-1
0 1 and 0 1

Et is the expected base level at time period t.


t
Tt is the expected trend at time period t.
6/3/2008

47

Forecasting
g With Holts Model
Forecasts for time periods 21 to 24 at time period 20:

Y
20+ n = E 20 + nT20

$ = E + 1T = 2336.8 + 1 152.1 = 2488.9


Y
21
20
20
$ = E + 2T = 2336.8 + 2 152.1 = 2641.0
Y
22
20
20
$ = E + 3T = 2336.8 + 3 152.1 = 27931
Y
.
23

20

20

$ = E + 4T = 2336.8 + 4 152.1 = 2945.2


Y
24
20
20

6/3/2008

48

Holt-Winters Method For


Additive Seasonal Effects
Yt + n = E t + nTt + St + n p
where

E t = Yt St p + (1- )(Et 1 + Tt 1 )

Tt = (E t E t 1 ) + (1 - )Tt 1
St = (Yt E t ) + (1- )St p
0 1
0 1
0 1

6/3/2008

49

Forecasting With Holt-Winters


Additive Seasonal Effects Method
Forecasts for time periods 21 to 24 at time period 20:

Y20+ n = E 20 + nT20 + S20+ n 4


= E + 1 T + S = 2253.3 + 1 154.3 + 262.66 = 2670.3
Y
21
20
20
17
= E + 2 T + S = 2253.3 + 2 154.3 312.59 = 2249.3
Y
22
20
20
18
= E + 3 T + S = 2253.3 + 3 154.3 + 205.40 = 2921.6
Y
23
20
20
19
= E + 4 T + S = 2253.3 + 4 154.3 + 386.12 = 3256.6
Y
24
20
20
20

6/3/2008

50

Holt-Winters Method For


M ltiplicati e Seasonal Effects
Multiplicative
Yt + n = (E t + nTt )St + n p
where

E t = Yt / St p + (1- )(Et 1 + Tt 1 )

Tt = (E t E t 1 ) + ((1 - ))Tt 1
St = (Yt / E t ) + (1- )St p
0 1
0 1
0 1
6/3/2008

51

Forecasting With Holt-Winters


Multiplicative Seasonal Effects Method
Forecasts for time p
periods 21 to 24 at time period
p
20:

Y20+ n = (E 20 + nT20 ) S20+ n 4


= (E + 1T ) S = (2217.6 + 1137.3)1.152 = 2713.7
Y
21
20
20 17
= (E + 2T ) S = (2217.6 + 2 137.3)0.849 = 2114.9
Y
22
20
20 18
= (E + 3T ) S = (2217.6 + 3 137.3)1.103 = 2900.5
Y
23
20
20 19
= (E + 4T ) S = (2217.6 + 4 137.3)1.190 = 3293.9
Y
24
20
20 20
6/3/2008

52

The Linear Trend Model

Y$ t = b0 + b1X1t
where X1t = t
For example:
X11 = 1, X12 = 2, X13 = 3, K

6/3/2008

53

Forecasting With
Th Li
The
Linear T
Trend
dM
Model
d l
Forecasts for time periods 21 to 24 at time period 20:
$ = b + b X = 3751
Y
. + 92.6255 21 = 2320.3
21
0
1
121
$ = b + b X = 3751
Y
. + 92.6255 22 = 2412.9
22
0
1
122
$ = b + b X = 3751
Y
. + 92.6255 23 = 2505.6
23
0
1
123
$ = b + b X = 3751
Y
. + 92.6255 24 = 2598.2
24
0
1
124

6/3/2008

54

The TREND() Function


TREND(Y-range, X-range, X-value for prediction)
where:
Y range is the spreadsheet range containing the dependent
Y-range
Y variable,
X-range is the spreadsheet range containing the
independent X variable(s),
X-value for prediction is a cell (or cells) containing the
values for the independent
p
X variable(s)
( ) for which we want
an estimated value of Y.
Note: The TREND( ) function is dynamically updated whenever
any inputs to the function change. However, it does not provide
the statistical information provided by the regression tool. It is
best two use these two different approaches to doing regression
in conjunction with one another.
6/3/2008

55

The Quadratic Trend Model

$ = b +b X +b X
Y
t
0
1 1t
2 2t
where X1t = t and X 2t = t 2

6/3/2008

56

Forecasting With
The Quadratic Trend Model
Forecasts for time periods 21 to 24 at time period 20:
2
= b +b X +b X
Y
21
0
1 12 1
2 2 2 1 = 653 .67 + 16 .671 21 + 3.617 21 = 2598 .9
2
= b +b X +b X
Y
=
653
.
67
+
16
.
671

22
+
3
.
617

22
= 2771 .1
22
0
1 12 2
2 22 2
2
= b +b X +b X
Y
=
653
.
67
+
16
.
671

23
+
3
.
617

23
= 2950 .4
23
0
1 12 3
2 22 3
2
= b +b X +b X
Y
=
653
.
67
+
16
.
671

24
+
3
.
617

24
= 3137 .1
24
0
1 12 4
2 22 4

6/3/2008

57

Computing Multiplicative
Seasonal Indices
We can compute multiplicative seasonal
adjustment indices for period p as follows:

Yi
i Y$
i
, for all i occuring
Sp =
g in season p
np
The final forecast for period i is then

$ adjusted = Y
$ S , for any i occuring in season p
Y
i
i
p
6/3/2008

58

Forecasting With Seasonal Factors


Applied To The Quadratic Trend Model
Forecasts for time periods 21 to 24 at time period 20:
= (b + b X + b X ) S = 2598 .9 105 .7% = 2747 .8
Y
21
0
1 12 1
2 22 1
1
= (b + b X + b X ) S = 2771 .1 80 .1% = 2219 .6
Y
22
0
1 12 2
2 22 2
2
= (b + b X + b X ) S = 2950 .5 103 .1% = 3041 .4
Y
23
0
1 12 3
2 22 3
3

= (b + b X + b X ) S = 3137 .2 111 .1% = 3486 .1


Y
24
0
1 12 4
2 22 4
4

6/3/2008

59

Summary of the Calculation and Use


of Seasonal Indices
1. Create a trend model and calculate the estimated
) for each observation in the sample.
value ( Y
t
2. For each observation, calculate the ratio of the actual
.
value to the predicted trend value: Yt / Y
t
).
(For additive effects, compute the difference: Y Y
t

3. For each season, compute the average of the ratios


calculated in step 2. These are the seasonal indices.
4. Multiply any forecast produced by the trend model by
the appropriate seasonal index calculated in step 3.
(For additive seasonal effects, add the appropriate factor
to the forecast
forecast.))
6/3/2008

60

Refining
e
g tthe
e Seaso
Seasonal
a Indices
d ces
Note that Solver can be used to simultaneously
determine the optimal values of the seasonal
indices and the parameters of the trend model
being used.
There is no guarantee that this will produce a
better forecast,, but it should produce
p
a model
that fits the data better in terms of the MSE.
See file Fig11-39.xls

6/3/2008

61

Seasonal Regression Models


Indicator variables may also be used in regression
models to represent seasonal effects.
If there are p seasons,
seasons we need p -1
1 indicator
variables.
Our example problem involves quarterly data,
data so p=4
and we define the following 3 indicator variables:
1, if Yt is an observation from quarter 1
X 3t =
0, otherwise
1, if Yt is an observation from quarter 2
X 4t =
0, otherwise
1, if Yt is an observation from quarter 3
X 5t =
th
i
0, otherwise
6/3/2008

62

Implementing the Model


The regression function is:
$ = b +b X +b X +b X +b X +b X
Y
t
0
1 1t
2 2t
3 3t
4 4t
5 5t
where X1t = t and X 2t = t 2

See file Fig11-42.xls

6/3/2008

63

Forecasting With The


S
Seasonal
lR
Regression
i M
Model
d l
Forecasts for time periods 21 to 24 at time period 20:
Y21 = 824.471+ 17.319(21) + 3.485(21) 2 86.805(1) 424.736(0) 123.453(0) = 2638.5
Y 22 = 824.471+ 17.319(22) + 3.485(22) 2 86.805(0) 424.736(1) 123.453(0) = 2467.7
Y23 = 824.471+ 17.319(23) + 3.485(23) 2 86.805(0) 424.736(0) 123.453(1) = 2943.2
Y24 = 824.471+ 17.319(24) + 3.485(24) 2 86.805(0) 424.736(0) 123.453(0) = 3247.8

6/3/2008

64

StatTools
StatTools is an add-in
add in that simplifies the
process of performing time series analysis
in Excel.
A trial version of StatTools is available on
p y g this book.
the CD-ROM accompanying
For more information on StatTools see:
http://www.palisade.com

6/3/2008

65

Combining Forecasts
It is also possible to combine forecasts to create a
composite forecast.
Suppose we used three different forecasting methods
on a given data set.
Denote the predicted value of time period t using
each method as follows:

F1t , F2t , and F3t


We could create a composite forecast as follows:

$ = b +b F +b F +b F
Y
t
0
1 1t
2 2t
3 3t
6/3/2008

66

ARIMA Model: Produksi padi


ARIMA model for Produksi padi
Estimates at each iteration
Iteration
SSE Parameters
0 451374984309793 0,100 0,100 0,100 0,100
1 368364447306473 0,021 0,199 0,250 0,152
2 325456920491419 -0,129 0,154 0,348 0,186
3 285571989081979 -0,279 0,118 0,475 0,229
4 245711224167492 -0,324 0,193 0,542 0,187
5 187899115792845 -0,474 0,260 0,657 0,041
6 155112700780088 -0,527 0,353 0,704 -0,109
7 141714161123773 -0,447
0 447 0
0,503
503 0
0,647
647 -0,201
0 201
8 129630495049884 -0,368 0,653 0,585 -0,287
9 117486920579732 -0,301 0,803 0,523 -0,376
10 101549593049237 -0,291 0,953 0,498 -0,503
11 87502739697009 -0,393 1,051 0,567 -0,653
,
1,076
,
0,614
,
-0,708
,
12 81737678770148 -0,543
13 79314052359269 -0,619 1,074 0,596 -0,687
14 79233477547537 -0,622 1,073 0,587 -0,677
15 79162421478230 -0,620 1,072 0,581 -0,671
16 79124151604006 -0,619 1,071 0,577 -0,667
17 79104368397552 -0,619 1,071 0,576 -0,665
18 79092164140468 -0,619 1,070 0,575 -0,664
19 79085747120700 -0,620 1,070 0,575 -0,664
Relative change in each estimate less than 0,0010

6/3/2008

67

Final Estimates of Parameters


Type
Coef
SE Coef
T
AR 1 -0,6197
0,1611
-3,85
MA 1
1,0698
0,0298
35,85
MA 2
0,5753
0,1894
3,04
MA 3 -0,6641
0,6641
0,1882
-3,53
3,53

P
0,001
0,000
0,005
0,001

Differencing: 3 regular differences


Number of observations: Original series 39, after differencing 36
Residuals:
es dua s SS = 70758139198041
0 58 39 980
(bac
(backforecasts
o ecasts e
excluded)
c uded)
MS = 2211191849939 DF = 32
Modified Box-Pierce (Ljung-Box) Chi-Square statistic
Lag
g
12
24
36
48
Chi-Square
20,9
38,4
*
*
DF
8
20
*
*
P-Value
0,008
0,008
*
*

6/3/2008

68

Model-model Time Series Regression


g

1. Model Regresi untuk LINEAR TREND


Yt = a + b.t + error

t = 1, 2, (dummy waktu)

2. Model Regresi untuk Data SEASONAL (variasi konstan)


Yt = a + b1 D1 + + bS-1 DS-1 + error
dengan : D1, D2, , DS-1
S 1 adalah dummy waktu dalam
satu periode seasonal.

3. Model Regresi untuk Data dengan LINEAR TREND dan


SEASONAL (variasi konstan)
Yt = a + b.t + c1 D1 + + cS-1 DS-1 + error
Gabungan model 1 dan 2.
6/3/2008

69

Nave Model

The recent periods are the best predictors of the future.


1. The simplest model for stationary data is

Yt +1 = Yt
2. The simplest model for trend data is

Yt +1 = Yt + (Yt Yt 1 ) or
Yt

Yt +1 = Yt
Yt 1
3. The simplest model for seasonal data is

Yt +1 = Y(t +1) s
6/3/2008

70

Average Methods

1. Simple Averages
obtained by finding the mean for all the relevant values and
then using
g this mean to forecast the next period.
p
n

Yt

Yt +1 =
t =1 n

forstationarydata

2. Moving Averages
obtained by finding the mean for a specified set of values
and then using this mean to forecast the next period
period.

(Y + Yt 1 + K + Yt n +1 )
M t = Yt +1 = t
n
6/3/2008

forstationarydata

71

Average Methods

(continued)

3. Double Moving Averages


one set of moving averages is computed, and then a second set
is computed as a moving average of the first set.

(Y + Yt 1 + K + Yt n +1 )
M t = Yt +1 = t
n
( M t + M t 1 + K + M t n +1 )
(ii) M t =
(ii).
n
(i).

(iii). at = 2M t M t
(iv). bt =

2
( M t M t )
n 1

Yt + p = at + bt p
6/3/2008

f
foralineartrenddata
li
t dd t
72

Exponential Smoothing Methods


9 Single Exponential Smoothing

for stationary data

Yt +1 = Yt + (1 )Yt
9 Exponential Smoothing Adjusted for Trend : Holts Method
1. The exponentially smoothed series :
At = Yt + (1) (At-1+ Tt-1)
2. The trend estimate :
Tt = (At At-1) + (1 ) Tt-1
3. Forecast p periods into the future :

Yt + p = At + pTt
6/3/2008

73

Exponential Smoothing Adjusted for Trend and


Seasonal Variation : Winters Method

1. The exponentially smoothed series :


Y
At = t + (1 ) ( At 1 + Tt 1)
St L
2. The trend estimate :
Tt = ( At At 1) + (1 )Tt 1

3. The seasonality estimate :

Three
p
parameters
models

Y
St = t + (1 ) St 1
At
4. Forecast p periods into the future :
Yt + p = ( At pTt ) St L + p
6/3/2008

74