JOIN (Jurnal Online Informatika)
Vol 11 No 2 (2026)

EKF-LSTM for Hospital Pharmaceutical Demand Forecasting: A One-Step Ahead Hybrid Framework

Andung Harjito (Department of Computer Science, Brawijaya University Malang)
Wayan Firdaus Mahmudy (Department of Computer Science, Brawijaya University Malang)
Mahendra Data (Department of Computer Science, Brawijaya University Malang)



Article Info

Publish Date
26 Sep 2026

Abstract

Accurate pharmaceutical demand forecasting in hospitals is essential for optimization, as inaccurate demand predictions lead to drug shortages, overstocking, and increased operational costs. Although the integration of the Extended Kalman Filter (EKF) with Long Short-Term Memory (LSTM) has shown potential in various domains, its application to hospital pharmaceutical sales prediction remains underexplored. This study proposes a hybrid EKF-LSTM model that leverages recursive state estimation to stabilize learning during zero-demand periods, effectively handling non-linear and zero-inflated drug sales time-series. The model was evaluated on eight drug commodities (2022–2024) using time-series cross-validation with one-step-ahead forecasting and compared against LSTM, GRU, Random Forest, XGBoost, PatchTST, and ARIMA using MAE, MSE, RMSE and MAPE. EKF-LSTM achieved the lowest aggregate error (MAE: 78.33 ± 54.12 units; RMSE: 95.67 ± 68.45 units), yielding 51.7% lower RMSE than LSTM, the second-best method. For items with continuous demand, MAPE was as low as 18.16%. A Diebold-Mariano test confirmed a statistically significant superiority over PatchTST (p = 0.018). These findings indicate that the EKF-LSTM hybrid model provides a robust solution for hospital pharmaceutical inventory planning, reducing stockouts and overstocking while improving overall operational efficiency.

Copyrights © 2026






Journal Info

Abbrev

join

Publisher

Subject

Computer Science & IT

Description

JOIN (Jurnal Online Informatika) is a scientific journal published by the Department of Informatics UIN Sunan Gunung Djati Bandung. This journal contains scientific papers from Academics, Researchers, and Practitioners about research on informatics. JOIN (Jurnal Online Informatika) is published ...