A Multi-Head Attention Soft Random Forest for Interpretable Patient No-Show Prediction
Abstract
1. Introduction
2. Literature Review
3. Materials and Methods
3.1. Theoretical Framework
3.1.1. Soft Decision Tree
3.1.2. Random Forest
3.1.3. Attention Mechanism
3.2. Proposed Framework
3.2.1. Data Collection
- Patient characteristics: age, gender, and language.
- Appointment characteristics: appointment status, type of visit, reason for visit, appointment time, specific healthcare provider, and others.
- Clinic and provider: the type of clinic and the name of the physician.
3.2.2. Data Preprocessing
- Data cleaning: Data were cleaned to reduce noise, handle missing data, and remove outliers and irrelevant features.
- Feature engineering: New features were derived from the data. For instance, the feature “Percentage of No-shows” (% no-show) was calculated for each patient based on their appointment history prior to the target appointment. Similarly, the feature “Number of Visits” was defined as the number of visits prior to the target appointment. In addition, the feature “Number of Appointments on the Same Day” was defined as the number of appointments scheduled for that day. Thus, all history-based features were constructed using only information available up to the target appointment, without using the target outcome or any future appointments.
- Encoding categorical variables: The dataset primarily contains categorical variables, such as gender, reason for the visit, month of the appointment, and type of visit. We transformed categorical variables into numerical representations using label encoding.
3.2.3. Model Architecture
| Algorithm 1. Multi-head Attention Soft Random Forest Model |
| Input: Dataset Number of trees T, tree depth D, number of attention heads H, number of epochs E Output: Trained MHASRF model Global feature importance 1. Initialize forest: 2. for k = 1 to T: 3. SDTk ← SDT (depth = D, input dim = d, output dim = 2) 4. add SDTk to the forest 5. Train SDTs: 6. for each SDTk in the forest: 7. ← bootstrap sample of 8. for epoch = 1 to E: 9. train on using cross-entropy classification loss 10. Compute leaf statistics and tree reliability: 11. for each SDTk: 12. Pass training samples through SDTk to obtain leaf assignments 13. Precompute Ak(x) and Bk(x) 14. Ck ← average misclassification on 15. δk ← λH/Ck 16. Multi-head attention: 17. initialize λ1 ∈ and W ∈ 18. for batch X in : 19. for each SDT k: 20. obtain the leaf assignment of each input x in SDT 21. retrieve the corresponding Ak(x) and Bk(x) 22. for each tree k and head h: 23. 24. for each SDT k: 25. 26. 27. 28. 29. Feature importance: 30. for each feature xj: 31. Itree(xj) ← average absolute weight across nodes and trees 32. Iattention(xj) ← attention-weighted tree importance 33. Ifinal (xj) ← average the Itree(xj) and Iattention(xj) 34. Optimize parameters via cross-entropy loss and Adam |
3.3. Feature Importance
3.4. Loss Function and Optimization
3.5. Evaluation Metrics
- TP: The model correctly predicts that the patient will be a no-show.
- FP: The model incorrectly predicts that the patient will be a no-show.
- TN: The model correctly predicts that the patient will attend the appointment.
- FN: The model incorrectly predicts that the patient will attend the appointment.
3.6. Experimental Setup
4. Results and Discussion
4.1. Performance Comparison with Baseline Models
4.1.1. Performance in 5-Fold Cross-Validation
4.1.2. Performance in the Held-Out Testing Set
4.2. Loss Curve Analysis
4.3. Attention Weight Distribution
4.4. Feature Importance Analysis
4.5. Ablation Study
4.6. Stratified Analysis by Department
4.7. Contextual Comparison with Prior No-Show Prediction Studies
4.8. Tree-Wise Attention and the Structure of Appointment Data
5. Limitations and Future Directions
6. Conclusions
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
References
- Mazaheri Habibi, M.R.; Abadi, F.M.; Tabesh, H.; Vakili-arki, H.; Abu-Hanna, A.; Ghaddaripouri, K.; Eslami, S. Evaluation of no-show rate in outpatient clinics with open access scheduling system: A systematic review. Health Sci. Rep. 2024, 7, e2160. [Google Scholar] [CrossRef]
- Kheirkhah, P.; Feng, Q.; Travis, L.M.; Tavakoli-Tabasi, S.; Sharafkhaneh, A. Prevalence, predictors and economic consequences of no-shows. BMC Health Serv. Res. 2016, 16, 13. [Google Scholar] [CrossRef]
- Nguyen, D.L.; DeJesus, R.S.; Wieland, M.L. Missed Appointments in Resident Continuity Clinic: Patient Characteristics and Health Care Outcomes. J. Grad. Med. Educ. 2011, 3, 350–355. [Google Scholar] [CrossRef]
- Drabkin, M.J.; Lobel, S.; Kanth, N.; Martynov, A.; Hunt, H.W.; Guerrero, D.; Fogel, J.; Grechanik, A.; Mancuso, C.D.; Lev, S. Telephone reminders reduce no-shows: A quality initiative at a breast imaging center. Clin. Imaging 2019, 54, 108–111. [Google Scholar] [CrossRef]
- Srinivas, S.; Ravindran, A.R. Optimizing outpatient appointment system using machine learning algorithms and scheduling rules: A prescriptive analytics framework. Expert Syst. Appl. 2018, 102, 245–261. [Google Scholar] [CrossRef]
- Dantas, L.F.; Hamacher, S.; Oliveira, F.L.C.; Barbosa, S.D.J.; Viegas, F. Predicting Patient No-show Behavior: A Study in a Bariatric Clinic. Obes. Surg. 2019, 29, 40–47. [Google Scholar] [CrossRef]
- Ding, X.; Gellad, Z.F.; Mather, C.; Barth, P.; Poon, E.G.; Newman, M.; Goldstein, B.A. Designing risk prediction models for ambulatory no-shows across different specialties and clinics. J. Am. Med. Inform. Assoc. 2018, 25, 924–930. [Google Scholar] [CrossRef] [PubMed]
- Almutairi, T.H.; Olatunji, S.O. The utilization of AI in healthcare to predict no-shows for dental appointments: A case study conducted in Saudi Arabia. Inform. Med. Unlocked 2024, 46, 101472. [Google Scholar] [CrossRef]
- Ferro, D.B.; Brailsford, S.; Bravo, C.; Smith, H. Improving healthcare access management by predicting patient no-show behaviour. Decis. Support Syst. 2020, 138, 113398. [Google Scholar] [CrossRef]
- Valero-Bover, D.; González, P.; Carot-Sans, G.; Cano, I.; Saura, P.; Otermin, P.; Garcia, C.; Gálvez, M.; Lupiáñez-Villanueva, F.; Piera-Jiménez, J. Reducing non-attendance in outpatient appointments: Predictive model development, validation, and clinical assessment. BMC Health Serv. Res. 2022, 22, 451. [Google Scholar] [CrossRef] [PubMed]
- Dunstan, J.; Villena, F.; Hoyos, J.P.; Riquelme, V.; Royer, M.; Ramírez, H.; Peypouquet, J. Predicting no-show appointments in a pediatric hospital in Chile using machine learning. Health Care Manag. Sci. 2023, 26, 313–329. [Google Scholar] [CrossRef] [PubMed]
- Alshammari, A.; Almalki, R.; Alshammari, R. Developing a predictive model of predicting appointment no-show by using machine learning algorithms. J. Adv. Inf. Technol. 2021, 12, 234–239. [Google Scholar] [CrossRef]
- Alshammari, R.; Daghistani, T.; Alshammari, A. The Prediction of Outpatient No-Show Visits by Using Deep Neural Network from Large Data. Int. J. Adv. Comput. Sci. Appl. 2020, 11, 533–539. [Google Scholar] [CrossRef]
- Liu, D.; Shin, W.Y.; Sprecher, E.; Conroy, K.; Santiago, O.; Wachtel, G.; Santillana, M. Machine learning approaches to predicting no-shows in pediatric medical appointment. npj Digit. Med. 2022, 5, 50. [Google Scholar] [CrossRef]
- Chaudhari, S.; Mithal, V.; Polatkan, G.; Ramanath, R. An Attentive Survey of Attention Models. ACM Trans. Intell. Syst. Technol. 2021, 12, 53. [Google Scholar] [CrossRef]
- Montavon, G.; Samek, W.; Müller, K.R. Methods for interpreting and understanding deep neural networks. Digit. Signal Process. 2018, 73, 1–15. [Google Scholar] [CrossRef]
- Kuo, C.Y.; Yu, L.C.; Chen, H.C.; Chan, C.L. Comparison of models for the prediction of medical costs of spinal fusion in Taiwan diagnosis-related groups by machine learning algorithms. Healthc. Inform. Res. 2018, 24, 29–37. [Google Scholar] [CrossRef]
- Li, J.; Shi, J.; Chen, J.; Du, Z.; Huang, L. Self-attention random forest for breast cancer image classification. Front. Oncol. 2023, 13, 1043463. [Google Scholar] [CrossRef]
- Utkin, L.V.; Konstantinov, A.V. Attention-based random forest and contamination model. Neural Netw. 2022, 154, 346–359. [Google Scholar] [CrossRef] [PubMed]
- Frosst, N.; Hinton, G. Distilling a Neural Network Into a Soft Decision Tree. arXiv 2017, arXiv:1711.09784. [Google Scholar] [CrossRef]
- Breiman, L. Random Forests. Mach. Learn. 2001, 45, 5–32. [Google Scholar] [CrossRef]
- AlMuhaideb, S.; Alswailem, O.; Alsubaie, N.; Ferwana, I.; Alnajem, A. Prediction of hospital no-show appointments through artificial intelligence algorithms. Ann. Saudi Med. 2019, 39, 373–381. [Google Scholar] [CrossRef]
- Ahmad, M.U.; Zhang, A.; Mhaskar, R. A predictive model for decreasing clinical no-show rates in a primary care setting. Int. J. Healthc. Manag. 2021, 14, 829–836. [Google Scholar] [CrossRef]
- Batool, T.; Abuelnoor, M.; El Boutari, O.; Aloul, F.; Sagahyroon, A. Predicting Hospital No-Shows Using Machine Learning. In Proceedings of the IoTaIS 2020—Proceedings: 2020 IEEE International Conference on Internet of Things and Intelligence Systems; Institute of Electrical and Electronics Engineers Inc.: New York, NY, USA, 2021; pp. 142–148. [Google Scholar] [CrossRef]
- Goffman, R.M.; Harris, S.L.; May, J.H.; Milicevic, A.S.; Monte, R.J.; Myaskovsky, L.; Rodriguez, K.L.; Tjader, Y.C.; Vargas, D.L. Modeling patient no-show history and predicting future outpatient appointment behavior in the veterans health administration. Mil. Med. 2017, 182, e1708–e1714. [Google Scholar] [CrossRef]
- Topuz, K.; Uner, H.; Oztekin, A.; Yildirim, M.B. Predicting pediatric clinic no-shows: A decision analytic framework using elastic net and Bayesian belief network. Ann. Oper. Res. 2018, 263, 479–499. [Google Scholar] [CrossRef]
- Mohammadi, I.; Wu, H.; Turkcan, A.; Toscos, T.; Doebbeling, B.N. Data Analytics and Modeling for Appointment No-show in Community Health Centers. J. Prim. Care Community Health 2018, 9, 2150132718811692. [Google Scholar] [CrossRef]
- Hamdan, A.F.A.; Bakar, A.A. Machine Learning Predictions on Outpatient No-Show Appointments in a Malaysia Major Tertiary Hospital. Malays. J. Med. Sci. 2023, 30, 169–180. [Google Scholar] [CrossRef]
- Abushaaban, E.; Agaoglu, M. Medical Appointment No-Show Prediction Using Machine Learning Techniques. In Proceedings of the 2022 2nd International Conference on Computing and Machine Intelligence, ICMI 2022—Proceedings; Institute of Electrical and Electronics Engineers Inc.: New York, NY, USA, 2022. [Google Scholar] [CrossRef]
- Fan, G.; Deng, Z.; Ye, Q.; Wang, B. Machine learning-based prediction models for patients no-show in online outpatient appointments. Data Sci. Manag. 2021, 2, 45–52. [Google Scholar] [CrossRef]
- Ahmadi, E.; Garcia-Arce, A.; Masel, D.T.; Reich, E.; Puckey, J.; Maff, R. A metaheuristic-based stacking model for predicting the risk of patient no-show and late cancellation for neurology appointments. IISE Trans. Healthc. Syst. Eng. 2019, 9, 272–291. [Google Scholar] [CrossRef]
- Bahdanau, D.; Cho, K.; Bengio, Y. Neural Machine Translation by Jointly Learning to Align and Translate. arXiv 2014, arXiv:1409.0473. [Google Scholar]
- Nadaraya, E.A. On Estimating Regression. Available online: https://www.mathnet.ru/eng/tvp356 (accessed on 14 May 2026).
- Watson, G.S. Smooth regression analysis. Sankhya Ser. A 1961–2002 1961, 26, 359–372. [Google Scholar]
- Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.N.; Kaiser, Ł.; Polosukhin, I. Attention Is All You Need. arXiv 2017, arXiv:1706.03762. [Google Scholar]
- Utkin, L.V.; Konstantinov, A.V.; Kirpichenko, S.R. Attention and self-attention in random forests. Prog. Artif. Intell. 2023, 12, 257–273. [Google Scholar] [CrossRef]
- Zhu, D.; Yao, H.; Jiang, B.; Yu, P. Negative Log Likelihood Ratio Loss for Deep Neural Network Classification. arXiv 2018, arXiv:1804.10690. [Google Scholar] [CrossRef]
- Amalina, N.N. Prediction-Driven Adaptive Double-Booking Strategy for Outpatient Scheduling: A Multi-Objective Reinforcement Learning Approach. Master’s Thesis, Kumoh National Institute of Technology, Gumi, Republic of Korea, 2026. [Google Scholar]








| Feature | Description | Type | Source |
|---|---|---|---|
| Patient Characteristics | |||
| Age | The patient’s age at the time of the appointment | Continuous | Raw |
| Language | The patient’s preferred language | Categorical | Raw |
| Gender | The patient’s gender | Categorical | Raw |
| Visit Reason | The reason for the patient’s visit | Categorical | Raw |
| Appointment Characteristics | |||
| Visit Type | The type of visit (e.g., procedure, consult, or new) | Categorical | Raw |
| Appointment Status | The current status of the appointment (i.e., no-show or show) | Categorical | Raw |
| Time Appointment by Time | The exact time of the appointment | Continuous | Raw |
| Time Appointment by Day | The day on which the appointment is scheduled | Categorical | Raw |
| Time Appointment by Month | The month in which the appointment is scheduled | Categorical | Raw |
| Week of The Month | The week number within the month in which the appointment is scheduled | Categorical | Derived |
| Season | The season during which the appointment is scheduled (e.g., summer or winter) | Categorical | Derived |
| Number of Visits | The number of visits the patient had before this appointment date/time | Continuous | Derived |
| %No-Show | The percentage of the patient’s prior appointments that were no-shows | Continuous | Derived |
| Number of Appointments on The Same Day | The number of appointments the patient had on the same day | Continuous | Derived |
| Clinic and Provider | |||
| Institute | The healthcare institute where the appointment is scheduled | Categorical | Raw |
| Center Name | The specific center within the institute where the appointment is scheduled | Categorical | Raw |
| Department Name | The department within the center where the appointment is scheduled (e.g., dentistry, gynecology, or urology) | Categorical | Raw |
| Provider Name | The name of the healthcare provider (physician) assigned to the patient | Categorical | Raw |
| External Factors | |||
| Temperature | The outside temperature at the time of the appointment | Continuous | Derived |
| Dew | The dew point (moisture level in the air) at the time of the appointment) | Continuous | Derived |
| Humidity | The humidity level at the time of the appointment | Continuous | Derived |
| Windspeed | The wind speed at the time of the appointment | Continuous | Derived |
| Visibility | The visibility level at the time of the appointment | Continuous | Derived |
| Weather Conditions | General description of the weather (e.g., raining, cloudy, or clear) | Categorical | Derived |
| Air Quality | The description of the air quality index (e.g., good, moderate, unhealthy, or hazardous) | Categorical | Derived |
| Model | Accuracy | Specificity | Precision | Recall | F1-Score | AUC |
|---|---|---|---|---|---|---|
| MHASRF | 88.00% ± 0.30% | 90.47% ± 0.61% | 80.79% ± 0.70% | 82.88% ± 1.33% | 81.82% ± 0.52% | 93.91% ± 0.35% |
| DT | 88.29% ± 0.21% | 89.50% ± 0.35% | 79.79% ± 0.36% | 85.78% ± 0.66% | 82.67% ± 0.33% | 93.03% ± 0.18% |
| RF | 85.35% ± 0.65% | 95.41% ± 0.24% | 87.18% ± 0.32% | 64.53% ± 2.33% | 74.14% ± 1.54% | 93.14% ± 0.27% |
| LR | 86.82% ± 0.26% | 87.66% ± 0.34% | 76.92% ± 0.26% | 85.08% ± 0.94% | 80.79% ± 0.44% | 90.86% ± 0.33% |
| NB | 83.17% ± 0.48% | 81.65% ± 0.59% | 69.46% ± 0.65% | 86.30% ± 0.89% | 76.97% ± 0.64% | 86.86% ± 0.55% |
| XGBoost | 88.77% ± 0.22% | 90.57% ± 0.03% | 81.35% ± 0.04% | 85.02% ± 0.05% | 83.14% ± 0.03% | 94.43% ± 0.15% |
| Model | Accuracy | Specificity | Recall | Precision | NPV | F1-Score | AUC |
|---|---|---|---|---|---|---|---|
| MHASRF | 88.24% | 91.21% | 82.01% | 81.60% | 91.42% | 81.81% | 94.07% |
| DT | 88.43% | 89.82% | 85.51% | 79.98% | 92.88% | 82.65% | 93.18% |
| RF | 85.15% | 96.36% | 61.56% | 88.94% | 84.06% | 72.76% | 93.38% |
| LR | 86.63% | 87.98% | 83.78% | 76.82% | 91.94% | 80.15% | 90.54% |
| NB | 83.09% | 81.87% | 85.65% | 69.20% | 92.30% | 76.55% | 86.23% |
| XGBoost | 88.82% | 90.79% | 84.68% | 81.38% | 92.57% | 83.00% | 94.50% |
| Model vs. MHASRF | Only MHASRF Model Correct | Only Other Model Correct | p-Value | Interpretation |
|---|---|---|---|---|
| RF | 1425 | 801 | <10−6 | MHASRF significantly better |
| LR | 689 | 368 | <10−6 | MHASRF significantly better |
| DT | 453 | 502 | 0.120 | No significant difference |
| NB | 1525 | 480 | <10−6 | MHASRF significantly better |
| XGBoost | 324 | 452 | 5.0 × 10−6 | XGBoost significantly better |
| Model | Accuracy | Specificity | Precision | Recall | F1-Score | AUC |
|---|---|---|---|---|---|---|
| SHASRF | 88.08% | 91.17% | 81.46% | 81.59% | 81.52% | 93.90% |
| MHASRF (2-head) | 88.16% | 90.71% | 80.91% | 82.81% | 81.85% | 93.99% |
| MHASRF (3-head) | 88.24% | 91.21% | 81.60% | 82.01% | 81.81% | 94.07% |
| MHASRF (4-head) | 88.03% | 90.36% | 80.35% | 83.15% | 81.75% | 93.81% |
| MHASRF (8-head) | 88.08% | 90.15% | 80.17% | 83.71% | 81.90% | 93.95% |
| MHASRF (without δk) | 88.15% | 91.06% | 81.35% | 82.06% | 81.70% | 94.08% |
| Department | Number of Appointments | Actual No-Shows | Predicted No-Shows | Actual No-Show Rate | Predicted No-Show Rate | Prediction Difference | PPV | NPV |
|---|---|---|---|---|---|---|---|---|
| Colorectal surgery | 1085 | 301 | 250 | 27.74% | 24.70% | −0.0304 | 94.80% | 92.34% |
| Dentistry | 1285 | 406 | 353 | 31.60% | 27.88% | −0.0371 | 77.05% | 85.62% |
| Gastroenterology | 6837 | 2302 | 2200 | 33.67% | 33.10% | −0.0057 | 92.55% | 94.26% |
| General surgery | 2889 | 796 | 811 | 27.55% | 28.78% | 0.0122 | 81.26% | 93.41% |
| Gynecology | 80 | 12 | 20 | 15.00% | 20.37% | 0.0537 | 60.00% | 100.00% |
| Nutrition | 1139 | 527 | 908 | 46.27% | 65.19% | 0.1892 | 53.08% | 80.52% |
| Otolaryngology | 3068 | 1051 | 931 | 34.26% | 33.17% | −0.0109 | 89.69% | 89.89% |
| Plastic surgery | 367 | 145 | 102 | 39.51% | 32.44% | −0.0707 | 93.14% | 81.13% |
| Speech therapy | 228 | 74 | 163 | 32.46% | 66.48% | 0.3402 | 38.04% | 81.54% |
| Urology | 3080 | 877 | 846 | 28.47% | 28.46% | −0.0002 | 81.80% | 91.72% |
| Wound care | 414 | 107 | 19 | 25.85% | 18.37% | −0.0748 | 52.63% | 75.44% |
| Study | Year | Clinical Setting | Best-Performing Model | Accuracy | AUC |
|---|---|---|---|---|---|
| Srinivas et al. [5] | 2021 | Cardiology clinic | GB | – | 85.00% |
| Hamdan et al. [22] | 2022 | Outpatient hospital | GB | 78.00% | 65.00% |
| Abushaaban et al. [29] | 2022 | Multiple hospitals | Symbolic regression and instance hardness threshold | 94.00% | 94.00% |
| Valero-Bomer et al. [10] | 2022 | Outpatient hospital | DT | 73.00% | – |
| Liu et al. [14] | 2022 | Pediatric hospital | DNN | 97.00% | |
| Dustan et al. [11] | 2023 | Pediatric hospital (multi-specialty) | Balanced ensemble methods | – | 71–83% |
| Almutairi et al. [8] | 2024 | Dental appointments | DT | 80.00% | 84.00% |
| This Study | 2025 | Outpatient hospital | MHASRF | 88.24% | 94.07% |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2026 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license.
Share and Cite
Amalina, N.N.; An, H. A Multi-Head Attention Soft Random Forest for Interpretable Patient No-Show Prediction. Systems 2026, 14, 576. https://doi.org/10.3390/systems14050576
Amalina NN, An H. A Multi-Head Attention Soft Random Forest for Interpretable Patient No-Show Prediction. Systems. 2026; 14(5):576. https://doi.org/10.3390/systems14050576
Chicago/Turabian StyleAmalina, Ninda Nurseha, and Heungjo An. 2026. "A Multi-Head Attention Soft Random Forest for Interpretable Patient No-Show Prediction" Systems 14, no. 5: 576. https://doi.org/10.3390/systems14050576
APA StyleAmalina, N. N., & An, H. (2026). A Multi-Head Attention Soft Random Forest for Interpretable Patient No-Show Prediction. Systems, 14(5), 576. https://doi.org/10.3390/systems14050576

