Bayesian Markov Chain Monte Carlo (MCMC) Model for Estimating Hospital Service Waiting Time
Waiting time is an important indicator of hospital service quality because it relates directly to patient satisfaction and service efficiency. This study estimates patient waiting time using Bayesian Gamma Regression with a log link function, fitted by Markov Chain Monte Carlo (MCMC) with the No-U-Turn Sampler (NUTS). The Smart Hospital Appointment dataset of 10,000 records was used, with severity_level, appointment_type, department, and emergency_case as predictors, and an 80:20 train–test split. Observed waiting times ranged from 1 to 59 minutes (mean 25.20, SD 14.86). Severity level was the only predictor with a clearly identifiable association with waiting time: relative to High severity, the posterior mean coefficients for Low (1.37) and Medium (0.89) correspond to mean waiting times about 3.9 and 2.4 times longer, respectively, with 95% credible intervals excluding zero. Credible intervals for most department coefficients included zero, while several parameters (the intercept, emergency_case, and the appointment-type coefficients) were weakly identified, probably because of overlap between emergency_case and appointment_type. Sampling diagnostics were acceptable (R-hat ≤ 1.01; bulk ESS 437–1,778). On the test set, the model achieved an MAE of 7.75 minutes and an RMSE of 9.22 minutes, without comparison to a baseline model. The posterior predictive check showed that the model reproduces the general location of the data but not its shape, as the simulated distribution had a right tail beyond the observed maximum, indicating that the Gamma specification is only an approximation. These findings suggest that severity level largely determines expected waiting time in this dataset, and that the model requires further refinement before it can be used for operational prediction.
Authors
- Zulfahmi Indra (ORCID: https://orcid.org/0000-0002-0429-606X)
- Febrianta Immanuel Purba
- Tegas Ramadhan
- Hafizham Mufti Siregar
Publication Details
- Journal
- Journal of Artificial Intelligence and Engineering Applications (JAIEA)
- Published
- 2026-10-30
- DOI
- https://doi.org/10.59934/jaiea.v6i1.3079
- Primary Topic
- Healthcare Operations and Scheduling Optimization
- Type
- article
- Field-Weighted Citation Impact
- 0.00