Optimization of Random Forest for Outpatient Cancellation Prediction Using PSO and Behavioral Feature Engineering

Behavioral Feature Engineering Decision Support System Particle Swarm Optimization Random Forest Hospital Digital Twin

Authors

Vol. 8 No. 3 (2026): August
Medical Informatics
May 30, 2026
June 21, 2026
July 5, 2026

Downloads

Outpatient cancellations and no-shows, defined respectively as proactive withdrawals and silent attendance failures, were consolidated into a binary target variable representing failed appointments that result in a completed visit. This issue significantly reduces healthcare efficiency and increases operational costs. While machine learning is widely applied, the existing methods face critical trade-offs between computational resource demands and data integrity, often relying on synthetic resampling such as SMOTE that introduces artificial noise. This study further aims to develop an optimized, lightweight Decision Support System designed as a core engine for potential future Hospital Digital Twin and AI Command Center architectures. The primary contribution is Behavioral Feature Engineering utilizing a 12-month retrospective patient history as a natural data enrichment strategy, offering a robust alternative to artificial data generation. The proposed framework employs an optimized Random Forest classifier combined with Target Encoding, Mutual Information-based feature selection, and Particle Swarm Optimization for hyperparameter tuning. To ensure computational efficiency, the optimization was performed on a stratified 2% sample of 10,690 records from a large-scale dataset containing 686,387 records from three hospitals. The final model achieved an accuracy of 0.871, an F1-score of 0.870, and a ROC-AUC of 0.940, effectively surpassing recent 2024 state-of-the-art benchmarks even under significant class imbalance. Furthermore, Particle Swarm Optimization achieved a 75.6% reduction in tree complexity, requiring only 122 estimators instead of 500, while preserving peak performance. Multi-scheme validation under strict chronological temporal splits and patient-grouped cross-validation proved high generalization stability, yielding robust F1-scores of 0.855 and 0.867, with a narrow 95% confidence interval of [0.8692, 0.8728]. The entire end-to-end pipeline was completed in under 60 minutes using standard CPU resources. In conclusion, the proposed framework provides a robust and sustainable predictive engine suitable for proactive clinical resource management and future hospital digital integration

How to Cite

Dzaky , A. A. ., Alzami, F. ., & Pujiono, . P. (2026). Optimization of Random Forest for Outpatient Cancellation Prediction Using PSO and Behavioral Feature Engineering. Indonesian Journal of Electronics, Electromedical Engineering, and Medical Informatics, 8(3), 317-334. https://doi.org/10.35882/ijeeemi.v8i3.348

Similar Articles

21-30 of 215

You may also start an advanced similarity search for this article.