Title: | EEMD Based LSTM Model for Time Series Forecasting |
---|---|
Description: | Forecasting univariate time series with ensemble empirical mode decomposition (EEMD) with long short-term memory (LSTM). For method details see Jaiswal, R. et al. (2022). <doi:10.1007/s00521-021-06621-3>. |
Authors: | Kapil Choudhary [aut, cre], Girish Kumar Jha [aut, ths, ctb], Ronit Jaiswal [ctb], Rajeev Ranjan Kumar [ctb] |
Maintainer: | Kapil Choudhary <[email protected]> |
License: | GPL-3 |
Version: | 0.1.0 |
Built: | 2025-02-12 04:26:51 UTC |
Source: | https://github.com/cran/EEMDlstm |
Monthly international Maize price (Dollor per million ton) from January 2010 to June 2020.
data("Data_Maize")
data("Data_Maize")
A time series data with 126 observations.
price
a time series
Dataset contains 126 observations of monthly international Maize price (Dollor per million ton). It is obtained from World Bank "Pink sheet".
https://www.worldbank.org/en/research/commodity-markets
https://www.worldbank.org/en/research/commodity-markets
data(Data_Maize)
data(Data_Maize)
The eemdLSTM function computes forecasted value with different forecasting evaluation criteria for EEMD based LSTM model.
eemdLSTM(data, spl=0.8, num.IMFs=emd_num_imfs(length(data)), s.num=4L, num.sift=50L, ensem.size=250L, noise.st=0.2,lag = 4, LU = 2, Epochs = 2)
eemdLSTM(data, spl=0.8, num.IMFs=emd_num_imfs(length(data)), s.num=4L, num.sift=50L, ensem.size=250L, noise.st=0.2,lag = 4, LU = 2, Epochs = 2)
data |
Input univariate time series (ts) data. |
spl |
Index of the split point and separates the data into the training and testing datasets. |
num.IMFs |
Number of Intrinsic Mode Function (IMF) for input series. |
s.num |
Integer. Use the S number stopping criterion for the EMD procedure with the given values of S. That is, iterate until the number of extrema and zero crossings in the signal differ at most by one, and stay the same for S consecutive iterations. |
num.sift |
Number of siftings to find out IMFs. |
ensem.size |
Number of copies of the input signal to use as the ensemble. |
noise.st |
Standard deviation of the Gaussian random numbers used as additional noise. This value is relative to the standard deviation of the input series. |
lag |
Lag of time series data. |
LU |
Number of unit in GRU layer. |
Epochs |
Number of epochs. |
A time series is decomposed by EEMD into a set of intrinsic mode functions (IMFs) and a residual, which are modelled and predicted independently using LSTM models. Finally, the ensemble output for the price series is produced by combining the forecasts of all IMFs and residuals. EEMD overcomes the limitation of the mode mixing and end effect problems of the empirical mode decomposition (EMD).
TotalIMF |
Total number of IMFs. |
AllIMF |
List of all IMFs with residual for input series. |
data_test |
Testing set used to measure the out of sample performance. |
AllIMF_forecast |
Forecasted value of all individual IMF. |
FinalEEMDLSTM_forecast |
Final forecasted value of the EEMD based LSTM model. It is obtained by combining the forecasted value of all individual IMF. |
MAE_EEMDLSTM |
Mean Absolute Error (MAE) for EEMD based LSTM model. |
MAPE_EEMDLSTM |
Mean Absolute Percentage Error (MAPE) for EEMD based LSTM model. |
rmse_EEMDLSTM |
Root Mean Square Error (RMSE) for EEMD based LSTM model. |
AllIMF_plots |
Decomposed IMFs and residual plot. |
plot_testset |
Test set forecasted vs actual value plot. |
Choudhary, K., Jha, G.K., Kumar, R.R. and Mishra, D.C. (2019) Agricultural commodity price analysis using ensemble empirical mode decomposition: A case study of daily potato price series. Indian journal of agricultural sciences, 89(5), 882–886.
Wu, Z. and Huang, N.E. (2009) Ensemble empirical mode decomposition: a noise assisted data analysis method. Advances in adaptive data analysis, 1(1), 1–41.
emdLSTM
data("Data_Maize") eemdLSTM(Data_Maize)
data("Data_Maize") eemdLSTM(Data_Maize)
The emdLSTM function computes forecasted value with different forecasting evaluation criteria for EMD based LSTM model.
emdLSTM(data, spl=0.8, num.IMFs=emd_num_imfs(length(data)), s.num=4L, num.sift=50L,lag = 4, LU = 2, Epochs = 2)
emdLSTM(data, spl=0.8, num.IMFs=emd_num_imfs(length(data)), s.num=4L, num.sift=50L,lag = 4, LU = 2, Epochs = 2)
data |
Input univariate time series (ts) data. |
spl |
Index of the split point and separates the data into the training and testing datasets. |
num.IMFs |
Number of Intrinsic Mode Function (IMF) for input series. |
s.num |
Integer. Use the S number stopping criterion for the EMD procedure with the given values of S. That is, iterate until the number of extrema and zero crossings in the signal differ at most by one, and stay the same for S consecutive iterations. |
num.sift |
Number of siftings to find out IMFs. |
lag |
Lag of time series data. |
LU |
Number of unit in GRU layer. |
Epochs |
Number of epochs. |
A time series is decomposed by EMD into a set of intrinsic mode functions (IMFs) and a residual, which are modelled and predicted independently using LSTM models. Finally, the ensemble output for the price series is produced by combining the forecasts of all IMFs and residuals.
TotalIMF |
Total number of IMFs. |
AllIMF |
List of all IMFs with residual for input series. |
data_test |
Testing set used to measure the out of sample performance. |
AllIMF_forecast |
Forecasted value of all individual IMF. |
FinalEEMDLSTM_forecast |
Final forecasted value of the EEMD based LSTM model. It is obtained by combining the forecasted value of all individual IMF. |
MAE_EEMDLSTM |
Mean Absolute Error (MAE) for EEMD based LSTM model. |
MAPE_EEMDLSTM |
Mean Absolute Percentage Error (MAPE) for EEMD based LSTM model. |
rmse_EEMDLSTM |
Root Mean Square Error (RMSE) for EEMD based LSTM model. |
AllIMF_plots |
Decomposed IMFs and residual plot. |
plot_testset |
Test set forecasted vs actual value plot. |
Choudhary, K., Jha, G.K., Kumar, R.R. and Mishra, D.C. (2019) Agricultural commodity price analysis using ensemble empirical mode decomposition: A case study of daily potato price series. Indian journal of agricultural sciences, 89(5), 882–886.
Huang, N.E., Shen, Z., Long, S.R., Wu, M.C., Shih, H.H., Zheng, Q. and Liu, H.H. (1998) The empirical mode decomposition and the Hilbert spectrum for nonlinear and non stationary time series analysis. In Proceedings of the Royal Society of London A: mathematical, physical and engineering sciences. 454, 903–995.
Jha, G.K. and Sinha, K. (2014) Time delay neural networks for time series prediction: An application to the monthly wholesale price of oilseeds in India. Neural Computing and Applications, 24, 563–571.
eemdLSTM
data("Data_Maize") emdLSTM(Data_Maize)
data("Data_Maize") emdLSTM(Data_Maize)