Forecasting Patient Prescription Demand in Community Pharmacies: A Comparison of Traditional Statistical Models and Machine Learning Techniques

Accurate forecasting of prescription demand allows community pharmacies to plan stock, staffing and dispensing capacity, yet most branches still rely on judgement and simple historical averages. This study examines whether traditional time-series models and machine learning techniques can accurately predict patient prescription volumes. Twelve months of prescription records from 162 community pharmacy branches in Bristol, United Kingdom, were used. Branches were segmented with K-means clustering, with the number of clusters selected by the elbow and silhouette methods (K = 2). Because the historical record was short, Monte Carlo simulation was used to generate an extended dataset of 10,000 observations from the cluster-level distributions. Four models were then trained and compared: a seasonal ARIMA (SARIMA) model, a Random Forest Regressor, a Random Forest Classifier and a Long Short-Term Memory (LSTM) recurrent neural network. Performance was measured by Root Mean Square Error (RMSE). The Random Forest Regressor achieved the lowest RMSE (30.987), followed by the LSTM (35.119) and SARIMA (36.829), while the Random Forest Classifier performed poorly (491.704) because the task is a regression problem. The best SARIMA specification, SARIMAX(0,1,1)(0,1,1,12), had an AIC of 789.008 and statistically significant coefficients. The results suggest that ensemble machine learning offers a modest accuracy advantage, while SARIMA remains valuable for its interpretability. A hybrid approach is recommended for operational use.

Authors

Institutions

Publication Details

Journal
International Journal of Advances in Engineering and Management
Published
2026-10-30
DOI
https://doi.org/10.5281/zenodo.23801828
Primary Topic
Forecasting Techniques and Applications
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Forecasting Patient Prescription Demand in Community Pharmacies: A Comparison of Traditional Statistical Models and Machine Learning Techniques

Nene C. T. Onyemari
2 links
International Journal of Advances in Engineering and Management
Forecasting Techniques and Applications
article

Forecasting Patient Prescription Demand in Community Pharmacies: A Comparison of Traditional Statistical Models and Machine Learning Techniques

Nene C. T. Onyemari
article en

Abstract

Accurate forecasting of prescription demand allows community pharmacies to plan stock, staffing and dispensing capacity, yet most branches still rely on judgement and simple historical averages. This study examines whether traditional time-series models and machine learning techniques can accurately predict patient prescription volumes. Twelve months of prescription records from 162 community pharmacy branches in Bristol, United Kingdom, were used. Branches were segmented with K-means clustering, with the number of clusters selected by the elbow and silhouette methods (K = 2). Because the historical record was short, Monte Carlo simulation was used to generate an extended dataset of 10,000 observations from the cluster-level distributions. Four models were then trained and compared: a seasonal ARIMA (SARIMA) model, a Random Forest Regressor, a Random Forest Classifier and a Long Short-Term Memory (LSTM) recurrent neural network. Performance was measured by Root Mean Square Error (RMSE). The Random Forest Regressor achieved the lowest RMSE (30.987), followed by the LSTM (35.119) and SARIMA (36.829), while the Random Forest Classifier performed poorly (491.704) because the task is a regression problem. The best SARIMA specification, SARIMAX(0,1,1)(0,1,1,12), had an AIC of 789.008 and statistically significant coefficients. The results suggest that ensemble machine learning offers a modest accuracy advantage, while SARIMA remains valuable for its interpretability. A hybrid approach is recommended for operational use.

International Journal of Advances in Engineering and Management
University of the West of England (GB)
Good health and well-being
Openalex Percentile: Top 10%
Forecasting Techniques and Applications
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon
Forecasting Patient Prescription Demand in Community Pharmacies: A Comparison of Traditional Statistical Models and Machine Learning Techniques — Nene C. T. Onyemari · International Journal of Advances in Engineering and Management (2026) | TGRS Research Map | TGRS