PROS Lailatul U, Agus S, Suhartono Inflow and outflow fulltext

Proceedings of the IConSSE FSM SWCU (2015), pp. MA.98–102

MA.98

ISBN: 978-602-1047-21-7

Inflow and outflow of currency forecasting
using calendar variation model based on time series regression
Lailatul Urusyiyah, Agus Suharsono, Suhartono
Institut Teknologi Sepuluh Nopember, Sukolilo, Surabaya 60111, Indonesia

Abstract
Inflow and outflow of currency in Indonesia sometimes it’s happened because of any
other event such us calendar variation that cause by national holiday in Indonesia.
Because inflow and outflow are time series data, so in this observation used calendar
variation model based on time series regression. The purpose of this study was to
examine the effectiveness of calendar variation model based on time series regression in
improving the accuracy of the realization of the provision of the inflow and outflow of
currency in Indonesia. Result in this observation is calendar variation model based on
regression time series for inflow series have accuracy values in sample is 68.76%, while
the final model for the series outflow have accuracy 65.28%.

Keywords inflow, outflow, time series regression

1.

Introduction

Inflow of currency indicate a currency that enters to Bank Indonesia by deposit banking
and society. The other way, outflow of currency indicate a currency that leaves from Bank
Indonesia by cash banking and society. Inflow and outflow of currency in Indonesia
sometimes it’s happened because of any other event such us calendar variation that cause
by national holiday in Indonesia. In general, Islamic calendar is also is also a lunar calendar
based on twelve lunar months in year of 354 (or 355 days in leap year), used to date events
in many Muslim countries, and used by Moslem majority, also uses Islamic calendar,
especially in determining religious holidays, such as Eid-holidays.
The most thing that influence inflow and outflow is Idul Fitri which is changeable every
year. Because inflow and outflow are time series data, so in this observation used calendar
variation model based on time series regression. The purpose of this study was to examine
the effectiveness of calendar variation model based on time series regression in improving
the accuracy of the realization of the provision of the inflow and outflow of currency in
Indonesia.


2. Materials and methods
2.1 Modeling of time series regression method
Regression in time series context has the same form as general linear regression. By
assuming output or dependent series, , ¹ = 1,2, … , , as being influenced by a collection
of possible inputs or independent series, where the inputs are fixed and known, this relation
can be expressed as linear regression model (Shumway & Stoffer, 2006). If there exist a trend
in the data, then we can model as follows:
= ¼+ ¹+¸ ,
where ¸ is error component, usually assumed independently and identically distributed as
SWUP

L. Urusyiyah, A. Suharsono, Suhartono

MA.99

normal with mean 0 and variance .
Data with seasonal pattern,æ , , æ , , … , æ , , can be written as
= ¼ + æ , + æ , + ⋯+ æ , + ¸ ,
where æ , , æ , , … , æ , are dummy variables for seasonal pattern. For example, in monthly

data, there are twelve seasonal dummy variables, one for each month while for quarterly
data, three dummy variables are used, one for each quarter.
Data with calendar variation can also be modeled by using regression. Linear
regression model for data with calendar variation can be expressed as (Suhartono et al.,
2010)
= ¼+
, +
, + ⋯+
, +¸ ,
where , is dummy variable for p-th calendar variation effect. The number of calendar
variation effects can be identified based on time series plot of the data. Ljung-Box statistics
may be employed to test whether the sequence
is white noise, the lags of is used as
the input. Selection of the appropriate lags for the model is based on ACF and PACF plot of
this error, ¸ .

2.2 Best model criteria
The root mean squared error (RMSE) is employed as an evaluation index for evaluating
the performance of the proposed calendar variation models. The RMSE for out-sample data
is defined as

ü%æç
where

L



7

,

is the number of forecast. The RMSE of in-sample data is defined as
ü%æç 7 = Þ

where

∑°
C\ ”
\±› …\ o…


in the number of parameters.

∑°
C\ ”
\±› …\ o…
7o

,

2.3 Method
This study uses the inflow and outflow data of currency that recorded each month by
Bank Indonesia. The used of time period from January 2003 until December 2014. Stages of
the analysis begins by identifying the characteristic pattern of inflow and outflow of currency,
followed by determination of dummy variable for trend, seasonal, and calendar variation
period, followed by simultaneous estimation of calendar variation model and other pattern,
after that diagnostic checks on residual white noise (if the residuals is not a white noise, add
significant lags based on ACF and PACF plots of residual), residual normal distribution, and
then re-estimate calendar variation effect, other pattern, and appropriate lags
simultaneously.


3. Results and discussion
In this observation used data monthly inflow and outflow of currency during 20032013 as in sample, and period 2014 as out sample. The average of inflow and outflow for in
sample data is 21.28 and 23.68 (in million billion), standard deviation for inflow and outflow
are 16.37 and 11.71. While the average of inflow and outflow for out sample data is 40.35
and 42.67, standard deviation for inflow and outflow are 22.54 and 27.38. Figure 1 displays
the time series plot inflow and outflow for January 2003 through December 2014.

SWUP

Inflow and outflow of currency forecasting using calendar variation model
based on time series regression

MA.100

8

8

100


100

8

8

80

80

9

9

1

1

Y1(t)


Y1(t)

1

60
8
11

40

11
1
1

20

7 91 0
4
23 56 8


7

1

1

9

10

12

1

2
8 10
8 9 1 2 34
1
1 212
7 9

3 56 1 0
567 9
4
23456 8 1 0

10

7
2

10

11
10

12 3

1
1


2
7
11 2
8
7 9
4 6
4 78 1 1 345
7
23
3 56 9 1 2
1 2 345 8
5
6 8 1112
6 9 12

10

5
4 6
2

2

9

11

11

5
34

7
12

11 2
10

4
3 567

6
12

10
9 11

10
9
11

4 6
3 5

60
11

40

1

12

1

12

20

7

8

7 91 0
4
23 56 8

1
10

10

1

10

1

2
7
11 2
8
7 9
4 6
2
4 78 1 1 345
7
23
1 2 345 8
3 56 9 1 2
5
6 8 1112
6 9 12

1

7
11
10

12 3
5
4 6
2

7

2

9

11

7

11

2 5
34
6

12

11 2
10
12

4
3 567

10
9 11

10
9
11

4 6
3 5

12
12
7

8

1

0

0
M onth
Year

11
1
2
8 10
8 9 1 2 34
1
1 212
7 9
3 56 1 0
567 9
4
23456 8 1 0

1

9

10

12
11

2

11

1
8

M onth
Year

Jan
Ja n
Jan
Jan
Jan
Jan
Jan
Jan
Jan
Jan
Jan
Jan
2003 2004 2005 2006 2 007 200 8 2009 2010 2011 2012 2013 2014

Figure 1. Time series plot inflow (Ÿ•

Dec/2006

Jan
Ja n
Jan
Jan
Jan
Jan
Jan
Jan
Jan
Jan
Jan
Jan
2003 2004 2005 2006 2 007 200 8 2009 2010 2011 2012 2013 2014

) and outflow (Ÿ•

) of currency.

Dec/2006

Dec/2010

Dec/2010

120

100

100
80

Trend 1

Trend 2

Trend 1

Trend 3

Trend 2

Trend 3

60

Y2(t)

Y1(t)

80
60

40

40

20

20

0
Month Jan Jan Jan Jan Jan Jan Jan Jan Jan Jan Jan Jan
Year 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014

0
Month Jan Jan Jan Jan Jan Jan Jan Jan Jan Jan Jan Jan
Year 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014

Figure 2. Time series plot inflow and outflow of currency with three trend.

It is shown in Figure 1 that the inflow of currency is high enough generally occurred in
January in every year, and are generally low in December in each year, while outflow of
currency is high enough generally occurred in December in every year, and are generally low
in January so it can be presumed the existence of seasonal patterns in the data inflow and
outflow. Inflow of currency also appears high in November of 2004 to 2006, October 2007 to
2009, September 2010 and 2011, August 2012 to 2014. Inflow of currency which seemed
high every year did not occur in the same month, while outflow of currency also appears high
in November 2003 and 2004, October 2005 to 2007, September 2008 to 2010, August 2011
and 2012, July 2013 and 2014. Outflow of currency which seemed high every year did not
occur in the same. It appears that there was a shift in the earlier period to capture the pattern
of currency inflow and outflow. It is the underlying suspicion that there are variations
calendar effects affecting the amount inflow and outflow of currency.
Dummy variables were expressed effect of calendar variations is a dummy with a
period of weeks in the period when Idul Fitri and one month after the Idul Fitri for the inflow,
while the dummy with a weekly period during the period of Idul Fitri and one month prior to
the Idul Fitri for the outflow of currency, So that the dummy variables were formed as a result
of variations in the calendar are as follows:
,

=p

1 , for month to-¹ with Idul Fitri in week to0 , for each month

1 , for month to- ¹ + 1 with Idul Fitri in week to0 , for each month
for inflow, while the dummy calendar variations due to the outflow is
, "

=S

,

=p

1 , for month to-¹ with Idul Fitri in week to0 , for each month

SWUP

L. Urusyiyah, A. Suharsono, Suhartono

MA.101

1 , for month to- ¹ − 1 with Idul Fitri in week to0 , for each month
where = 1,2,3,4. While variable stating the positive trend in the data patterns of the inflow
and outflow of currency is expressed by t. It can be describe in the Figure 2.
So that the dummy variable stating the trend in the data pattern there tree, while
variable stating their seasonal pattern expressed by monthly dummy, ie æ , , æ , , … , æ , .
Time series regression models inflow of currency can be presumed as follows.
7 , = 0.16¹ − 17.55œ , − 54.58œ‰, + 0.02œ , ¹ + 0.42œ‰, ¹ + 26.04æ ,
+17.71æ , + 16.08æ‰, + 15.66æï, + 14.55æò, + 13.55æÓ, + 17.09æy,
+15.21æ2, + 15.21æ ¼, + 15.11æ , + 9.26æ , + 25.16 ,
+24.44 , + 6.77 ‰, − 8.61 ï, + 5.52 , " + 4.75 , "
+10.71 ‰, " + 34.16 ï, " +
having obtained the alleged models, then the next step is to test the assumption of
independent residuals and normal distribution. When they fulfill these assumptions we then
carried out the significance of the parameters. The results obtained are
7 , = 0.24¹ − 45.46œ‰, − 0.29œ , ¹ + 0.27œ‰, ¹ + 32.97æ , + 20.42æ ,
+18.37æ‰, + 17.74æï, + 16.55æò, + 15.10æÓ, + 19.97æ¡, + 18.92æy,
+19.16æ2, + 20.25æ ¼, + 17.22æ , + 10.46æ , + 24.07 ,
+19.04 , − 9.17 ï, − 10.39 , " + 11.64 , " + 13.94 ‰, "



+41.91 ï, " − 0.26 o ï + 23.84v¢, − 22.26v¢, + 21.36v¢,
, o

=S

+31.45v¢,

y

+ 20.56v¢,

Ó

+m ,

1, ¹ =
0, ¹ ≠
For time series regression models outflow of currency can be presumed as follows.
7 , = 0.12¹ − 17.71œ , − 59.45œ‰, + 0.09œ , ¹ + 0.54œ‰, ¹ + 7.28æ ,
+10.18æ , + 13.49æ‰, + 16.39æï, + 16.18æò, + 20.71æÓ,
+16.16æy, + 10.72æ2, + 9.27æ ¼, + 13.89æ , + 37.57æ ,
−3.22 , + 16.29 , + 34.69 ‰, − 36.51 ï, + 40.14 , o
+20.96 , o + 5.95 ‰, o + 5.31 ï, o +
having obtained the alleged models, then the next step is to test the assumption of
independent residuals and normal distribution. When they fulfill these assumptions we then
carried out the significance of the parameters. The results obtained are
7 , = −60.30œ , − 0.11œ , ¹ + 0.62œ‰, + 14.02æ , + 13.34æ , ¹
+17.31æ‰, + 19.91æï, + 20.57æò, + 24.67æÓ, + 23.59æ¡,
+19.66æy, + 17.58æ2, + 16.42æ ¼, + 17.97æ , + 36.81æ ,
+12.26 , + 29.33 ‰, + 52.96 ï, + 36.19 , o + 12.05 , o
+6.47 ‰, o + 50.73v¢,2Ó + 32.02v¢,2ò + +31.42v¢, ¡
+0.517 , o − 0.157 , o ‰ + m
where residual variable that white noise and normal distribution and v

/

=p

4. Conclusion and remarks
Calendar variation model based on regression time series for inflow series have
accuracy values which measured by RMSE for in sample is 3.66, while the final model for the
series outflow is 5.68. So it can be concluded that calendar variation model based on time
series regression more accurate for forecasting than naïve model because RMSE calendar
variation model is smaller than naïve model (standard deviation from out sample data).

SWUP

Inflow and outflow of currency forecasting using calendar variation model
based on time series regression

MA.102

References
Shumway, R.H., & Stoffer, D.S. (2006). Time series analysis and its application with R examples (2nd
ed.). Springer, Berlin.
Suhartono, Muhammad H.L., & Nor A.H. (2010). Calendar variation based on time series regression for
sales forecasts: The Ramadhan effects.
Wei, W.W.S. (2006). Time series analysis, univariate and multivariate methods. Addison Wesley
Publishing Company, Canada.

SWUP