Generative Adversarial Networks Time Series Models to Forecast Medicine Daily Sales in Hospital


  • Amir Mahmud Husein Universitas Prima Indonesia
  • Muhammad Arsyal Universitas Prima Indonesia
  • Sutrisno Sinaga Universitas Prima Indonesia
  • Hendra Syahputa Universitas Prima Indonesia




Forecasting, Generative Adversarial Networks (GAN), deep learning, Stock Prediction


The success of the work of Generative Adversarial Networks (GAN) has recently achieved great success in many fields, such as stock market prediction, portfolio optimization, financial information processing and trading execution strategies, because the GAN model generates seemingly realistic data with models generator and discriminator .Planning for drug needs that are not optimal will have an impact on hospital services and economics, so it requires a reliable and accurate prediction model with the aim of minimizing the occurrence of shortages and excess stock, In this paper, we propose the GAN architecture to estimate the amount of drug sales in the next one week by using the drug usage data for the last four years (2015-2018) for training, while testing using data running in 2019 year , the classification results will be evaluated by Actual data uses indicators of Mean Absolute Error (MAE), Root Mean Square Error (RMSE) and Mean Absolute Percentage Error (MAPE). From the results of the experiment, seen from the value ​​of MAE, RMSE and MAPE, the proposed model has promising performance, but it still needs to be developed to explore ways to extract factors that are more valuable and influential in the trend disease progression, thus helping in the selection of optimal drugs

GS Cited Analysis


Download data is not yet available.


[1]. Husein, A. M., Harahap, M., Aisyah, S., Purba, W., & Muhazir, A. (2018). The implementation of two stages clustering (k-means clustering and adaptive neuro fuzzy inference system) for prediction of medicine need based on medical data. In Journal of Physics: Conference Series (Vol. 978, No. 1, p. 012019). IOP Publishing.

[2]. Harahap, M., Husein, A. M., Aisyah, S., Lubis, F. R., & Wijaya, B. A. (2018). Mining association rule based on the diseases population for recommendation of medicine need. In Journal of Physics: Conference Series (Vol. 1007, No. 1, p. 012017). IOP Publishing.

[3]. Borovykh, A., & Bohte, S. (2017). Conditional Time Series Forecasting with Convolutional Neural Networks, 1–19.

[4]. Bao W, Yue J, Rao Y (2017) A deep learning framework for financial time series using stacked autoencoders and long-short term memory. PLoS ONE 12(7): e0180944. https://doi. org/10.1371/journal.pone.0180944

[5]. Ömer Faruk, D. (2010). A hybrid neural network and ARIMA model for water quality time series prediction. Engineering Applications of Artificial Intelligence, 23(4), 586–594.

[6]. Maestre, J. M., Fernández, M. I., & Jurado, I. (2018). An application of economic model predictive control to inventory management in hospitals. Control Engineering Practice, 71(November 2017), 120–128.

[7]. Ribeiro, A., Seruca, I., & Durão, N. (2017). Improving organizational decision support: Detection of outliers and sales prediction for a pharmaceutical distribution company. Procedia Computer Science, 121, 282–290.

[8]. Shin, J. S., Kim, S., & Lee, J. M. (2015). Production and inventory control of auto parts based on predicted probabilistic distribution of inventory. Digital Communications and Networks, 1(4), 292–301.

[9]. De Santis, R. B., De Aguiar, E. P., & Goliatt, L. (2018). Predicting material backorders in inventory management using machine learning. 2017 IEEE Latin American Conference on Computational Intelligence, LA-CCI 2017 - Proceedings, 2017–November, 1–6.

[10]. Bozkir, A. S., & Sezer, E. A. (2011). Predicting food demand in food courts by decision tree approaches. Procedia Computer Science, 3, 759–763.

[11]. De Marcos, R. A., Bello, A., & Reneses, J. (2017). Short-term forecasting of electricity prices with a computationally efficient hybrid approach. International Conference on the European Energy Market, EEM, 6–11.

[12]. Beigaite, R., & Krilavičius, T. (2018). Electricity price forecasting for nord pool data using recurrent neural networks. CEUR Workshop Proceedings, 2145, 75–78.

[13]. Ugurlu, U. (2018). Electricity Price Forecasting Using Recurrent Neural Networks, (April), 1–21.

[14]. Khashei, M., & Hajirahimi, Z. (2018). A comparative study of series arima/mlp hybrid models for stock price forecasting. Communications in Statistics: Simulation and Computation, 0(0), 1–16.

[15]. Angamuthu Chinnathambi, R., Mukherjee, A., Campion, M., Salehfar, H., Hansen, T., Lin, J., & Ranganathan, P. (2018). A Multi-Stage Price Forecasting Model for Day-Ahead Electricity Markets. Forecasting, 1(1), 3.

[16]. Orozco, B. P., Abbati, G., & Roberts, S. (2018). MOrdReD: Memory-based Ordinal Regression Deep Neural Networks for Time Series Forecasting. Retrieved from

[17]. Borovykh, A., Bohte, S., & Oosterlee, C. W. (2017). Conditional time series forecasting with convolutional neural networks. Lecture Notes in Computer Science (Including Subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics), 10614 LNCS, 729–730.

[18]. Graves, A. (2016). Adaptive Computation Time for Recurrent Neural Networks, 1–19.

[19]. Bianchi, F. M., Maiorino, E., Kampffmeyer, M. C., Rizzi, A., & Jenssen, R. (2017). An overview and comparative analysis of Recurrent Neural Networks for Short Term Load Forecasting, 1–41.

[20]. Qu, Y., Cai, H., Ren, K., Zhang, W., Yu, Y., Wen, Y., & Wang, J. (2017). Product-based neural networks for user response prediction. Proceedings - IEEE International Conference on Data Mining, ICDM, 1149–1154.

[21]. Zhang, L., Wang, G., & Giannakis, G. B. (2018). Real-time Power System State Estimation and Forecasting via Deep Neural Networks, 1–9. Retrieved from

[22]. Prasad, S. C., & Prasad, P. (2014). Deep Recurrent Neural Networks for Time- Series Prediction. 1407.5949, 95070, 1–19.

[23]. Karim, F., Majumdar, S., Darabi, H., & Harford, S. (2018). Multivariate LSTM-FCNs for Time Series Classification, 1–9. Retrieved from

[24]. Hsu, D. (2017). Multi-period Time Series Modeling with Sparsity via Bayesian Variational Inference, 1–14. Retrieved from

[25]. Müller-Navarra, M., Lessmann, S., & Voß, S. (2015). Sales forecasting with partial recurrent neural networks: Empirical insights and benchmarking results. Proceedings of the Annual Hawaii International Conference on System Sciences, 2015–March, 1108–1116.

[26]. Li, D., Chen, D., Shi, L., Jin, B., Goh, J., & Ng, S.-K. (2019). MAD-GAN: Multivariate Anomaly Detection for Time Series Data with Generative Adversarial Networks, 1–17.

[27]. Li, D., Chen, D., Goh, J., & Ng, S. (2018). Anomaly Detection with Generative Adversarial Networks for Multivariate Time Series, 1–10.

[28]. Esteban, C., Hyland, S. L., & Rätsch, G. (2017). Real-valued (Medical) Time Series Generation with Recurrent Conditional GANs.

[29]. Zhou, X., Pan, Z., Hu, G., Tang, S., & Zhao, C. (2018). Stock Market Prediction on High-Frequency Data Using, 2018.
[30]. Liang, Z., Jiang, K., Chen, H., Zhu, J., & Li, Y. (2018). Deep Reinforcement Learning in Portfolio Management.

[31]. Liang, Z., Chen, H., Zhu, J., Jiang, K., & Li, Y. (2018). Adversarial Deep Reinforcement Learning in Portfolio Management.

[32]. Leangarun, T., Tangamchit, P., & Thajchayapong, S. (2018). Stock Price Manipulation Detection using Generative Adversarial Networks. In 2018 IEEE Symposium Series on Computational Intelligence (SSCI) (pp. 2104-2111). IEEE

[33]. Chen, Y., Li, P., & Zhang, B. (2018). Bayesian renewables scenario generation via deep generative networks. 2018 52nd Annual Conference on Information Sciences and Systems, CISS 2018, 1–6.

[34]. Chen, Y., Wang, Y., Kirschen, D., & Zhang, B. (2018). Model-Free Renewable Scenario Generation Using Generative Adversarial Networks. IEEE Transactions on Power Systems, 33(3), 3265–3275.

[35]. Borovykh, A., Bohte, S., & Oosterlee, C. W. (2017). Conditional time series forecasting with convolutional neural networks. Lecture Notes in Computer Science (Including Subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics), 10614 LNCS, 729–730.

[36]. Du, S., Li, T., Yang, Y., & Horng, S. J. (2018). Deep Air Quality Forecasting Using Hybrid Deep Learning Framework. arXiv preprint arXiv:1812.04783.

[37]. Lee, D. (2017). Using Deep Learning Techniques to Forecast Environmental Consumption Level, 1–17.

[38]. Tech, C. Y., Networks, N., Detection, O. N., Digital, F., View, I., & Network, G. N. (2017). A Deep Learning Algorithm to Forecast Sales of Pharmaceutical Products A Deep Learning Algorithm to Forecast Sales of Pharmaceutical Products, (August).

[39]. Zhu, L., & Laptev, N. (2017). Deep and Confident Prediction for Time Series at Uber. IEEE International Conference on Data Mining Workshops, ICDMW, 2017–Novem, 103–110.

[40]. Kuo, P. H., & Huang, C. J. (2018). An electricity price forecasting model by hybrid structured deep neural networks. Sustainability (Switzerland), 10(4), 1–17.

[41]. Zhang, K., Zhong, G., Dong, J., Wang, S., & Wang, Y. (2019). Stock Market Prediction Based on Generative Adversarial Network. Procedia Computer Science, 147, 400–406.

[42]. Goodfellow, I. J., Pouget-Abadie, J., Mirza, M., Xu, B., Warde-Farley, D., Ozair, S., … Bengio, Y. (2014). Generative Adversarial Networks, 1–9.


Crossmark Updates

How to Cite

Husein, A. M., Arsyal, M., Sinaga, S., & Syahputa, H. (2019). Generative Adversarial Networks Time Series Models to Forecast Medicine Daily Sales in Hospital. Sinkron : Jurnal Dan Penelitian Teknik Informatika, 3(2), 112-118.

Most read articles by the same author(s)