Fourier Transformaion on Model Fiing for Pakisan Inflaion Rae Anam Iqbal (Corresponding auhor) Dep. of Saisics, Gov. Pos Graduae College (w), Sargodha, Pakisan Tel: 92-321-603-4232 E-mail: anammughal343@gmail.com Basheer Ahmad Dep. of Managemen Sciences, Iqra Universiy, Islamabad, Pakisan Tel: 92-322-656-5140 E-mail: drbasheer@iqraisb.edu.pk Kanwal Iqbal Dep. of Quaniaive Mehod SBE (School of Business and Economics) Universiy of Managemen and Technology, Lahore, Pakisan Tel: 92-336-750-2158 E-mail: F2017204003@um.edu.pk Asad Ali Dep. of Saisics, Universiy of Sargodha, Sargodha, Pakisan Tel: 92-304-161-1166 E-mail: ranaasadali23@gmail.com Received: Ocober 25, 2017 Acceped: November 10, 2017 doi:10.5296/ber.v8i1.12052 URL: hps://doi.org/10.5296/ber.v8i1.12052 Absrac Inflaion is one of he serious economic indicaors in Pakisan. Inflaion can be crawling, walking, running, hyper and sagflaion according o naure. To model monhly inflaion rae in Pakisan periodogram analysis and frequency domain analysis which is also known as Fourier analysis or specral analysis is used. Afer analyzing he daa, inflaion cycle lengh is observed and appropriae Fourier series models are fied o he daa. Monhly inflaion rae is also analyzed by Auo Regressive Inegraed Moving average (ARIMA). Furher, models are 84
compared and i is found ha Fourier series models are more suiable o forecas inflaion rae of Pakisan. Keywords: Inflaion, Periodogram, Fourier Series Models, ARIMA Models, Saionariy, Roo Mean Square Error, Mean Absolue Error 1. Inroducion Inflaion is a siuaion in which price level increases and purchasing power decreases. There are cerain elemens cause he rise of inflaion such as increase in populaion, increase in demand, lack of supply, developmen expendiures and consan low producion due o some social, poliical, climaic, naional or inernaional siuaions. Increase in inflaion rae gives birh o unemploymen, povery, unfair disribuion, poor labour force and social evils. So, for economic growh of a counry, i is imporan o analyze inflaion rae of a counry. Time series is he collecion of observaion wih respec o ime or space. Time series analysis is also known as ime domain analysis. Box and Jenkins (1976) mehodology come under ime domain analysis. Time series may conain rend, seasonaliy, cyclic and random componen. Therefore i is imporan o explore he saionariy of daa. A saionary series has a wave-like paern as i has consan mean and consan variance. Waves have a period which is he disance beween peaks or ime beween wo peaks of a wave. Frequency is he closely relaed propery of he wave period and is jus he proporion of cycle ha occurs during one observaion. Frequency domain is used o analyze he daa wih respec o frequency. Transformaion is very imporan in frequency domain analysis and is used o conver a ime domain funcion ino a frequency domain. Fourier ransformaion found by grea mahemaician Joseph Fourier (1822) is he mos commonly used ransformaion in frequency domain analysis. This frequency domain analysis is also known as specral analysis or Fourier analysis. In his paper frequency domain approach wih periodogram analysis is used o model he monhly inflaion rae. Model based on specral analysis and model based on Box-Jenkins mehodology are also compared. 2. Lieraure Review Euk (2012) presened ime series analysis of Nigerian monhly inflaion raes and fied a muliplicaive seasonal auoregressive inegraed moving average model. He showed ha he model is adequae and forecass are agreed closely wih observaions. Raza, Javed and Naqvi (2013) discussed he impac of inflaion on economic growh of Pakisan and esimaed shor run and long run relaionship beween inflaion and economic growh. They suggesed ha governmen should mainain inflaion in single digi which is favorable for economic growh. Ekpenyong, John, Omekara and Peer (2014) proposed he applicaion of periodogram analysis and Fourier analysis o model inflaion raes in Nigeria. The main objecive of he sudy was o idenify inflaion cycles and fi he appropriae model o forecas fuure values. Konarasinghe and Abeynayake (2015) suggesed a sudy based on Fourier ransformaion on model fiing for Sri Lankan share marke. They also analyzed he monhly reurns by 85
ARIMA (Auo Regressive Inegraed Moving Average) and concluded ha Fourier ransformaion along wih muliple regression is suiable. Konarasinghe, Abeynayake and Gunarane (2015) proposed a model by using Box-Jenkins mehodology or Auo-Regressive Inegraed Moving Average (ARIMA) mehodology o forecas Sri Lankan share marke reurns. Jere and Siyanga (2016) used Hol s exponenial smoohing and Auo-Regressive Inegraed Moving Average (ARIMA) models o forecas inflaion rae of Zambia. They showed ha he choice of Hol s exponenial smoohing is as good as an ARIMA model. Konarasinghe, Abeynayake and Gunarane (2016) developed a model named as circular model based on Fourier ransformaion o forecas Reurns of Sri Lankan share marke. Thomson and Vuuren (2016) proposed Fourier ransform analysis o deermine he duraion of Souh African business cycle which is measured by using log changes in nominal GDP (Gross Domesic Produc). Three dominan cycles are used o forecas log monhly nominal GDP and he forecass are compared wih hisorical daa. They found ha Fourier analysis is more effecive in esimaing he business cycle lengh as well as in deermining he posiion of he economy in he business cycle. 3. Research Mehodology The main objecive of his sudy is o develop a significan model o forecas inflaion rae in Pakisan. For his purpose, monhly daa on CPI inflaion rae from 2008 o 2016 is colleced from (Pakisan Bureau of Saisics, n.d.). Firs periodogram analysis is used o find inflaion cycle as inflaion is affeced by many facors which may cause seasonaliy and periodiciy in he series. Afer deermining he period or frequency of series, significance of seleced period is esed by a es developed by Fisher (1929). Fourier series is hen used o model inflaion rae by uilizing seleced frequency as Fourier frequency. Moreover, Box-Jenkins mehodology is also used o model he daa. By using accuracy measures boh ypes of models are compared and i is found ha model based on Fourier series is considering smaller deviaion in Roo Mean Square Error (RMSE), Mean Absolue Error (MAE) and Mean Absolue Percenage Error (MAPE). 3.1 Periodogram Analysis Periodogram is a ool ha pariions he oal variance of a ime series ino componen variances like ANOVA. The longer cycle shares large variance in he series. In general pracice periods of cycles are no known hen Periodogram is uilized o idenify dominan cyclic behavior in he series. In periodogram analysis, ime series can be viewed as N cos sin i i i, (1) Y T a w b w i i 1 where T is rend, N is oal number of observaions, a i and b i are coefficiens, w i is angular frequency in radians and ε is error erm. The coefficiens are calculaed as 86
i i N 1 Business and Economic Research N 2 a Y Tˆ cos w, (2) i i N 1 N 2 b Y Tˆ sin w. (3) The calculaed coefficiens are hen used o obain Inensiy or Periodogram ordinae a frequency f i as 2 2 2 I fi ai bi i 1,2, q, (4) N In case of even number of observaions N = 2q, q = N/2 and for odd number of observaions N = 2q+1, q = (N-1)/2. The period agains he larges Inensiy ha is acually he larges sum of squares is seleced as cycle period of series. 3.2 A Significance Tes for Periodic Componen The variabiliy in he sizes of sum of squares may be due o jus sampling error. The larges ordinae mus indicae srong periodiciy even for whie noise series. Therefore i is necessary o es he significance of larges periodic componen in whie noise. A es developed by Fisher (1929) provides a reasonable mehod for esing significance of such periodic componens. To perform Fisher es g saisic is compued which is he raio of larges sum of squares (or inensiy ordinae) o he oal sum of squares. Tables of criical values for his es saisic are given in Russell (1985). The null hypohesis of whie noise series is rejeced, if he value of g saisic is greaer han criical value. 3.3 Specral Analysis The basic idea of specral analysis is o ransform he ime domain series ino frequency domain series, which deermines he imporance of each frequency in he original series. This arge is achieved by using Fourier ransformaion. The general Fourier series model ha conain componens of ime series is given by where w = 2πf k cos sin i, (5) Y T iw iw i i 1 k = n/2 (In case of even number) k = (n-1)/2 (In case of odd number) n is he number of observaions per season or cycle lengh, f is he Fourier frequency or number of peaks in series, k is he harmonic of w (see Delurgio, 1998), is he ime index, α i 87
Y Business and Economic Research and β i are ampliudes which are esimaed hrough muliple linear regression analysis. 3.4 ARIMA Auoregressive inegraed moving average models are presened by Box, Jenkins and Reinsel (1994). To achieve saionariy, if a series is differenced d imes hen he model will be ARIMA (p,d,q), where p denoes auoregressive erms and q denoes moving average erms. ARIMA model for a saionary ime series is a linear equaion in which predicors are lags of dependen variable and lags of error erms i.e. d B Y B, (6) p q where, Y = presen value, d = difference, B = backshif operaor, ε = presen error erm 4. Resuls and Discussion Time series plo of original inflaion rae in Pakisan is consruced. Figure 1 shows ha here exis rend, seasonaliy and cyclical variaions in he series bu he lengh of he cycle is no confirmed. 25.00 20.00 15.00 10.00 5.00 0.00 Inflaion Rae Period Figure 1. Original Series of Inflaion Raes In his sudy firs saionariy of he series is examined by using ACF (Auocorrelaion Funcion), PACF (Parial Auocorrelaion Funcion) and ADF (Augmened Dicky Fuller) es and i is found ha series is no saionary. As figure 1 indicaes here exis rend herefor o make such a ime series saionary, he rend is esimaed and hen removed from he series. 4.1 Fiing Trend Model The esimaed rend equaion is given by Tˆ 16.927 0.1387 88
Table 1. Summary of rend model Predicor coef SE coef P Consan 16.9270 0.4992 33.91 0.000 T -0.1387 0.0084-16.48 0.000 S = 2.50222 R-Sq = 73.1% R-Sq(adj) = 72.8% Table 1 shows ha boh he parameers in he rend model are significan. 4.2 Periodogram Analysis Afer removing rend from he series, de-rended series is used o esimae seasonal componen. By using equaion (2), (3) and (4) inensiies a various frequencies are obained as given in Table 2. Table 2. Frequencies, Periods and Inensiies freq P Pdg freq P Pdg 0 0 0.254902 3.923077 2.469466 0.009804 102 17.82893 0.264706 3.777778 2.571481 0.019608 51 0.283872 0.27451 3.642857 4.361273 0.029412 34 151.7146 0.284314 3.517241 3.985825 0.039216 25.5 5.061672 0.294118 3.4 1.131958 0.04902 20.4 143.5882 0.303922 3.290323 0.115284 0.058824 17 24.33793 0.313725 3.1875 0.848861 0.068627 14.57143 6.144949 0.323529 3.090909 4.099034 0.078431 12.75 13.55495 0.333333 3 4.243186 0.088235 11.33333 17.27606 0.343137 2.914286 3.418537 0.098039 10.2 27.54437 0.352941 2.833333 1.415018 0.107843 9.272727 63.83039 0.362745 2.756757 1.373335 0.117647 8.5 3.69523 0.372549 2.684211 1.026038 0.127451 7.846154 1.240284 0.382353 2.615385 1.869164 0.137255 7.285714 6.553623 0.392157 2.55 3.213267 0.147059 6.8 4.288788 0.401961 2.487805 3.215139 0.156863 6.375 17.12196 0.411765 2.428571 2.99018 0.166667 6 23.81014 0.421569 2.372093 2.466381 0.176471 5.666667 14.43552 0.431373 2.318182 2.288237 0.186275 5.368421 4.424012 0.441176 2.266667 0.927199 0.196078 5.1 3.554464 0.45098 2.217391 0.390481 0.205882 4.857143 3.682635 0.460784 2.170213 0.329865 0.215686 4.636364 0.798868 0.470588 2.125 1.620553 0.22549 4.434783 6.765822 0.480392 2.081633 3.01465 0.235294 4.25 2.518789 0.490196 2.04 3.122662 0.245098 4.08 3.450255 0.5 2 4.191004 89
Table 2 shows ha period and frequency corresponding o larges inensiy are n = 34 and f = 0.02941. Here frequency is jus he inverse of period. Thus he period of cycle or long-erm inflaion cycle is 34 monhs. This shows ha inflaion rae is high during 2008-01 o 2010-10. The shor-erm inflaion cycle idenified by second larges inensiy is 20 monhs ha is from 2010-11 o 2013-06. 4.3 Significance Tes of Periodic Componen As Fisher es saisic value in Table 3 is greaer han he criical value so he null hypohesis of whie noise is rejeced and he seleced period is significan. Table 3. Oupu of Significance es 4.4 Esimaion of Seasonal Componen G saisic Criical value Fisher Tes 0.2415 0.126 Since he number of observaions is even herefore, 34 K n 17 2 2 and w 2 0.02941 Hence he seasonal model is given by 17 Y ( cos iw sin iw) i i i 1 The parameers of his model are esimaed by he leas square mehod. 90
Table 4. Parameer Esimaion in seasonal componen Predicor Coef SE coef p Predicor Coef SE coef p cosw 0.2011 0.3326 0.60 0.547 sin9w -0.1804 0.3326-0.54 0.589 sinw 1.7138 0.3325 5.15 0.000 cos10w 0.0979 0.3326 0.29 0.769 cos2w 0.5942 0.3326 1.79 0.078 sin10w -0.1098 0.3327-0.33 0.742 sin2w -0.3602 0.3325-1.08 0.283 cos11w 0.1520 0.3326 0.46 0.649 cos3w -0.5690 0.3326-1.71 0.092 sin11w -0.2342 0.3328-0.70 0.484 sin3w 0.0970 0.3325 0.29 0.771 cos12w 0.1696 0.3326 0.51 0.612 cos4w 0.2673 0.3326 0.80 0.424 sin12w 0.0322 0.3330 0.10 0.923 sin4w -0.0619 0.3325-0.19 0.853 cos13w 0.1959 0.3326 0.59 0.558 cos5w -0.1403 0.3326-0.42 0.674 sin13w -0.0045 0.3332-0.01 0.989 sin5w -0.2481 0.3325-0.75 0.458 cos14w -0.1704 0.3326-0.51 0.610 cos6w 0.4640 0.3326 1.39 0.168 sin14w 0.1847 0.3339 0.55 0.582 sin6w -0.2661 0.3325-0.80 0.426 cos15w 0.1041 0.3326 0.31 0.755 cos7w 0.0541 0.3326 0.16 0.871 sin15w -0.0645 0.3356-0.19 0.848 sin7w -0.2593 0.3326-0.78 0.438 cos16w -0.0459 0.3325-0.14 0.891 cos8w 0.2135 0.3326 0.64 0.523 sin16w -0.1154 0.3450-0.33 0.739 sin8w 0.0808 0.3326 0.24 0.809 cos17w 0.4074 0.4954 0.82 0.414 cos9w -0.1208 0.3326-0.36 0.717 sin17w 28.55 47.13 0.61 0.547 Table 4 indicaes ha sinw is significan a 5% level of significance and sinw, cos2w, cos3w are significan a 10% level of significance. So he esimaed seasonal models are given by Yˆ 1.7138sin w (7) Yˆ 1.7138sin w 0.5942cos 2w 0.5690cos3 w (8) Since Y垐 Y T By exploring he randomness of error erm wih he help of ACF and PACF i is found ha error erm is no random. So firs order auoregressive is used. Table 5. Summary of firs order auoregressive Predicor Coef SE coef P ε -1 0.65893 0.07242 9.1 0 s = 1.41653 Table 5 presens ha he parameer esimae of error erm is significan in model. ˆ 0.658822 (9) 1 91
4.5 General Fourier Series Model The general models which consis esimaed rend, esimaed seasonal componen and error componen may be Yˆ 16.927 0.1387 1.7138sin w 0.65893 1 (10) Yˆ 16.927 0.1387 1.17138sin w 0.5942cos 2w 0.5690cos3 w 0.65893 1 (11) Model (10) and model (11) are found o be overall significan. The residuals of boh models are also found o be independenly and normally disribued. Table 6. Summary of Fourier series Models Model RMSE MAE MAPE Model (10) 1.68 1.16 15% model (11) 1.57 1.03 13% Table 6 shows ha RMSE, MAE and MPE for boh models are small. Figure 2. Plo of acual and esimaes Figure 2 reveals ha esimaed values of boh models are very close o acual values. 4.5 ARIMA Models on Inflaion Rae Time series plo of inflaion rae shows ha series is non-saionary. Afer aking he firs difference series becomes saionary and saionariy is confirmed hrough correlogram and ADF es. The idenificaion of AR and MA is done hrough correlogram and ARIMA models of differen orders are fied o he daa as given in Table 7. Table 7. Summary of ARIMA Models Model RMSE MSE MAPE (12,1,16) 2.52 1.94 34% (16,1,16) 3.03 2.20 40% ARIMA models are found o be overall significan. RMSE, MSE and MAPE of boh models 92
are small. The residuals of boh models are also independenly and normally disribued. From he oupu of Table 6 and Table 7, i can be seen ha Fourier series models are good fied as compare o ARIMA models. 4. Conclusion Using periodogram analysis o sudy inflaion rae in Pakisan, i has been found ha inflaion is much affeced by periodic or cyclical variaion as long-erm inflaion cycle is 34 monhs and shor-erm inflaion cycle is 20 monhs for he period under sudy. Fourier series models have been developed o forecas inflaion rae in Pakisan. ARIMA models have also been fied o he monhly inflaion rae in Pakisan. I has been observed ha accuracy measures RMSE, MAE, MAPE for boh ypes of fied models are good and residuals are normally and independenly disribued. So boh mehods can be used o forecas Pakisan inflaion rae bu i is idenified ha Fourier series models have more effecive accuracy measures as compare o ARIMA models. References Box, G. P. E., & Jenkins, G. M. (1976). Time series analysis: Forecasing and conrol. San Francisco: Holden-Day. Box, G. P. E., Jenkins, G. M., & Reinsel, G. (1994). Time series analysis: Forecasing and conrol. New Jersey, NJ: Prenice Hall. Ekpenyong, John, E., Omekara, C. O., & Peer, E. M. (2014). Modeling inflaion raes using periodogram and fourier series analysis mehods: The Nigerian case. Inernaional journal of African & Asian sudies, 4, 49-62. Euk, E. H. (2012). Predicing inflaion raes of Nigeria using a seasonal Box-Jenkins model. Journal of saisical and economeric mehods, 1(3), 27-37. Fisher, R. A. (1929). Tess of significance in harmonic analysis. Proceedings of he royal sociey of London, 125(796), 54-59. hps://doi.org/10.1098/rspa.1929.0151 Fourier, J. (1822). The analyical heory of hea. New York: Dover publicaions. Jere, S., & Siyanga, M. (2016). Forecasing inflaion rae of Zambia using Hol s exponenial smoohing. Open journal of Saisics, 6, 363-372. hps://doi.org/10.4236/ojs.2016.62031 Konarasinghe, W. G. S., & Abeynayake, N. R. (2015). Fourier ransformaion on model fiing for Sri Lankan share marke reurns. Global journal for research analysis, 4(1), 159-161. Konarasinghe, W. G. S., Abeynayake, N. R., & Gunarane, L. (2015). ARIMA models on forecasing Sri Lankan share marke reurns. Inernaional journal of novel research in Physics Chemisry and Mahemaics, 2(1), 6-12. Konarasinghe, W. G. S., Abeynayake, N. R., & Gunarane, L. (2016). Circular model on forecasing reurns of Sri Lankan Share marke. Inernaional journal of novel research in Physics Chemisry and Mahemaics, 3(1), 49-56. 93
Pakisan Bureau of Saisics. (n.d.). Publicaions. Rerieved from hp://www.pbs.gov.pk/publicaions Raza, S. H., Javed, M. R., & Naqvi, S. A. (2013). Economic growh & inflaion: A ime series analysis of Pakisan. Inernaional journal of innovaive research and developmen, 2(6), 689-703. Russell, R. H. (1985). Significance ables for he resuls of fas fourier ransforms. Briish journal of mahemaical and saisical psychology, 38(1), 116-119. hps://doi.org/10.1111/j.2044-8317.1985.b00820.x Delurgio, S. (1998). Forecasing principles and applicaions. Unied Saes of America, USA: Irwin McGraw-Hill. Thomson, D., & Vuuren, G. V. (2016). Forecasing he Souh African business cycle using fourier analysis. Inernaional business and economics research journal, 15(4), 175-192. hps://doi.org/10.19030/iber.v15i4.9755 Copyrigh Disclaimer Copyrigh for his aricle is reained by he auhor(s), wih firs publicaion righs graned o he journal. This is an open-access aricle disribued under he erms and condiions of he Creaive Commons Aribuion license (hp://creaivecommons.org/licenses/by/3.0/). 94