Big 5 ASEAN capital markets forecasting using WEMA method

ASEAN through ASEAN Economics Community (AEC) 2020 treaty has proposed financial integration via capital markets integration in order to aim comprehensive ASEAN economic integration. Therefore, the need to have a proper prediction of ASEAN capital market becomes a major issue. In this study, we took big 5 ASEAN capital markets, i.e. Straits Times Index (STI), Kuala Lumpur Stock Exchange (KLSE), Stock Exchange of Thailand (SET), Jakarta Stock Exchange (JKSE), and Philippine Stock Exchange (PSE) to be forecasted using WEMA method. Weighted Exponential Moving Average (WEMA) is a new hybrid moving average method which combines the weighting factor calculation in Weighted Moving Average (WMA) with the procedure of Exponential Moving Average (EMA). WEMA has successfully been implemented and used to forecaste discrete time series data, but never being used to forecast ASEAN capital markets. In this study, we took further action by implementing the WEMA method with brute force approach for scaling factor tuning on big 5 ASEAN capital markets. From the experimental results, we found that WEMA has successfully forecasted all those exchanges. By looking at the forecast error measurement, it gives the best performance on PSE and worst performance on SET dataset among all datasets being considered in this study.


Introduction
Time series is a set of observations where each one of them being recorded at a specific or regular interval [1,2]. One of the main goals of any time series analysis is nonetheless the prediction of future values from a given time series data. Some are using conventional methods, such as moving average and exponential smoothing methods [3][4][5][6], and some others are using soft computing methods, such as neural networks and fuzzy inference system [7][8][9]. Moreover, hybrid forecasting methods have also been developed by many researchers as we can find in the works of Zhiyuan et al. [10], Draidi and Labed [11], and Popoola et al. [12].
In time series forecasting, there is an assumption that the future is actually an extension of the past. Therefore, we can predict future values using historical data we have [13]. Later, it is known as technical analysis method that originally used by investors and traders as an input for trading decision.
Moving Average (MA) is one of the most popular and widely used technical analysis methods [14]. There are many variations of MA methods, but their underlying purpose remains the same, i.e. to track the trend determination of a given time series data [15]. One relatively new derivative method of MA is Weighted Exponential Moving Average (WEMA) method. It was first introduced in 2013 and since then has been widely used by researchers in time series analysis. Chen et al. for example, they modified and implemented WEMA method for differential physical layer secret key generation to improve security in wireless system [16]. Hansun et al. also implemented WEMA method in many scenarios, such as IHSG data and Forex data [17]. Based on their experimental results, WEMA method is proved to be robust and can be used as an alternative method in time series analysis.
In this study, we tried to take further scenarios of WEMA implementation, especially to forecast capital market in Association of Southeast Asian Nations (ASEAN) countries. ASEAN through ASEAN Economics Community (AEC) 2020 treaty has proposed financial integration via capital markets integration in order to aim comprehensive ASEAN economic integration [18]. Therefore, the need to have a proper prediction of ASEAN capital markets is a must. We take big 5 ASEAN countries according to World Economic Forum ranking, i.e. Singapore, Malaysia, Thailand, Indonesia, and Philippines [19]. Table 1 shows the big 5 ASEAN capital markets used in this study. Country column shows the name of big 5 ASEAN countries, i.e. Singapore, Malaysia, Thailand, Indonesia, and Philippine. Abbreviation column shows the popular abbreviation for each country capital market followed by its full definition in the last column of the Furthermore, we also propose to use brute force approach to find the best scaling factor in WEMA method. By using this approach, we could get a better forecasting result since it will search for the best α value that leads to the minimum forecasting result's error rate. After successful implementation of WEMA with brute force approach in big 5 ASEAN capital markets, we then calculate the prediction error. Two error measurement tools, i.e. Mean Square Error (MSE) and Mean Absolute Scaled Error (MASE) were used in this study as further explained in the next section.

Research Method
This section is started with a brief explanation of WEMA as the main forecasting method implemented in this study. Later, two forecast error measurement tools will also be explained to complete this section.

WEMA
As a relatively new hybrid forecasting method in Moving Average (MA) family, Weighted Exponential Moving Average (WEMA) has been accepted and used by researchers around the world. The main contribution of this method is the combination of two conventional MAs, i.e. Weighted Moving Average (WMA) and Exponential Moving Average (EMA); that results in a better forecasting. As described in [17], [20], WEMA method follows these steps: a. First, we need to calculate a base dataset value, let's called it , for a given time series data using WMA formula as shown in (1).
where refers to the datum value at time and is the number of span data used in WMA calculation. b. Then, with the base dataset we calculate the prediction value using in (2) where is the real datum value at time , is the base value at time , and represents the degree of weighting factor decrement [21] as formulated in (3).
In this study, rather than using constant value, we used brute force approach to find and get the best value that could minimize the forecasting results error rate. c. Return to No. 1 until all the data in given period has been cycled. As can be clearly inferred from the procedures, WEMA approach differs from EMA in the data usage. If in EMA we used the most recent datum and one last ordered real datum, in WEMA it is not limited to those data, but some older data values in a given time period can be considered [20].

Forecast Error Measurement
There are many forecast error measurement tools can be used, but we focus on two of them, i.e. Mean Square Error (MSE) and Mean Absolute Scaled Error (MASE). MSE is a very popular forecast error technique; however it is not unit free which means that it would be better used in comparing and analyzing time series data with same data unit. MSE formulation is written as (4) [22] where n refers to the total number of data, A t is the actual value of data, and F t is the forecasted value of data. On the other hand, MASE is a relatively new unit-free method that was introduced by Hyndman and Koehler [23]. It scales errors based on the in-sample mean absolute error from naïve forecasting method [24], and expressed as (5) where is the actual value of data, is the forecasted value, and is a stable measure of the scale of the time series calculated on the training dataset, which can be found using (6) [25].
for non-seasonal time series data, and in (7) for seasonal time series data. denotes the season length.

Phatsa Framework and Data
We aim to forecast big 5 ASEAN capital markets using WEMA method as described in Introduction section. To achieve the goal, we develop a web based forecasting application called Phatsa which can be accessed freely on http://phatsa.com. Interested readers are welcome to read [26] for further information on Phatsa (PHP application for time series analysis).
Big 5 ASEAN capital markets used in this study are STI, KLSE, SET, JKSE, and PSE. Stock exchange composite index data being used is the closing data which were recorded daily from May 2, 2017 to May 2, 2018 and taken from investing.com, a global financial portal and internet brand which provide news, analysis, streaming quotes and charts, technical data and financial tools about the global financial markets [27]. After data collection phase, we predict the future values of big 5 ASEAN capital markets using Phatsa framework that had been integrated with WEMA method. The forecasting results will then be depicted in a graph together with the error measurement values as be discussed further in section 3.

Results and Analysis
This section consist of two parts, the first one is the forecasting results of big 5 ASEAN capital markets using WEMA method and the second one is the error measurement analysis.

Forecasting Results
The forecasting results for STI, KLSE, SET, JKSE, and PSE composite index data are shown on Figure 1 to

Error Measurements
Forecasting results graphs as shown before have given us initial understanding of WEMA performance in time series forecasting. However, to get more knowledge on forecasting accuracy, we need to use forecast error tools, such as MSE and MASE which have been explained in section 2. Table 2 shows the forecast error measurement results for big 5 ASEAN capital markets prediction using WEMA. As we can see in Table 2, PSE (Philippine Stock Exchange) has the lowest MASE value, which means that WEMA is best performed on PSE dataset. On the other hand, SET (Stock Exchange of Thailand) has the highest MASE value that indicates WEMA is worst performed on SET dataset.

Conclusion
The comprehensive ASEAN economic integration had been declared in AEC 2020 treaty. Therefore, the need to have a proper prediction of ASEAN capital market becomes an interesting research topic. We choose to predict the big 5 ASEAN capital markets using WEMA method with scaling factor fine tuning using brute force approach. It is successfully implemented and forecasted the big 5 ASEAN capital markets used in this study, i.e. Straits Times Index