Lin Lin Guo, Rui Tang, Jia Yang Wang, Si Zheng, Yin Zeng, Jun Hou, Mo Chen Dong, Jiao Li, Ying Cui
{"title":"使用机器学习预测儿科医院医疗任务的等待时间:全面,回顾性,现实世界的研究。","authors":"Lin Lin Guo, Rui Tang, Jia Yang Wang, Si Zheng, Yin Zeng, Jun Hou, Mo Chen Dong, Jiao Li, Ying Cui","doi":"10.2196/77297","DOIUrl":null,"url":null,"abstract":"<p><strong>Background: </strong>The shortage of pediatric medical resources and overcrowding in children's hospitals are severe issues in China. Accurately predicting waiting times can help optimize hospital operational efficiency.</p><p><strong>Objective: </strong>This study aims to develop machine learning models to predict waiting times for various laboratory and radiology examinations at a pediatric hospital.</p><p><strong>Methods: </strong>Time stamp data from laboratory and radiology examinations were retrospectively collected from the pediatric hospital information system between November 1, 2024, and March 13, 2025. Two queue-related and 4 time-based features were extracted using queue theory. Linear regression and 8 machine learning models were trained to predict waiting times for each medical task. Hyperparameters were fine-tuned using randomized search and 10-fold cross-validation, and the bootstrap method was used for model evaluation. Mean absolute error, mean square error, root mean square error, and the coefficient of determination (R²) were used as evaluation metrics. Shapley additive explanations values were used to assess feature importance.</p><p><strong>Results: </strong>A total of 230,864 time-stamped records were included after data preprocessing. The median waiting time was 4.817 (IQR 1.867-12.050) minutes for all medical tasks. Waiting times for radiology examinations were generally longer than those for laboratory tests. Tree-based algorithms, such as random forest and classification and regression trees, performed best in predicting laboratory test waiting times, with R² values ranging from mean 0.880(SD 0.003) to mean 0.934 (SD 0.003). However, the machine learning models did not perform well in predicting radiology examination waiting times, with R2 ranging from 0.114 (SD 0.005) to 0.719 (SD 0.004). Feature importance analysis revealed that queue-related predictors, especially the number of queuing patients, were the most important in predicting waiting times.</p><p><strong>Conclusions: </strong>Task-specific prediction models are more appropriate for accurately predicting waiting times across various medical tasks. Guided by queue theory principles, we developed machine learning models for the waiting time prediction of each medical task and highlighted the importance of queue-related predictors.</p>","PeriodicalId":56334,"journal":{"name":"JMIR Medical Informatics","volume":"13 ","pages":"e77297"},"PeriodicalIF":3.8000,"publicationDate":"2025-09-29","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"https://www.ncbi.nlm.nih.gov/pmc/articles/PMC12481172/pdf/","citationCount":"0","resultStr":"{\"title\":\"Predicting Waiting Times for Medical Tasks in a Pediatric Hospital Using Machine Learning: Comprehensive, Retrospective, Real-World Study.\",\"authors\":\"Lin Lin Guo, Rui Tang, Jia Yang Wang, Si Zheng, Yin Zeng, Jun Hou, Mo Chen Dong, Jiao Li, Ying Cui\",\"doi\":\"10.2196/77297\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"<p><strong>Background: </strong>The shortage of pediatric medical resources and overcrowding in children's hospitals are severe issues in China. Accurately predicting waiting times can help optimize hospital operational efficiency.</p><p><strong>Objective: </strong>This study aims to develop machine learning models to predict waiting times for various laboratory and radiology examinations at a pediatric hospital.</p><p><strong>Methods: </strong>Time stamp data from laboratory and radiology examinations were retrospectively collected from the pediatric hospital information system between November 1, 2024, and March 13, 2025. Two queue-related and 4 time-based features were extracted using queue theory. Linear regression and 8 machine learning models were trained to predict waiting times for each medical task. Hyperparameters were fine-tuned using randomized search and 10-fold cross-validation, and the bootstrap method was used for model evaluation. Mean absolute error, mean square error, root mean square error, and the coefficient of determination (R²) were used as evaluation metrics. Shapley additive explanations values were used to assess feature importance.</p><p><strong>Results: </strong>A total of 230,864 time-stamped records were included after data preprocessing. The median waiting time was 4.817 (IQR 1.867-12.050) minutes for all medical tasks. Waiting times for radiology examinations were generally longer than those for laboratory tests. Tree-based algorithms, such as random forest and classification and regression trees, performed best in predicting laboratory test waiting times, with R² values ranging from mean 0.880(SD 0.003) to mean 0.934 (SD 0.003). However, the machine learning models did not perform well in predicting radiology examination waiting times, with R2 ranging from 0.114 (SD 0.005) to 0.719 (SD 0.004). Feature importance analysis revealed that queue-related predictors, especially the number of queuing patients, were the most important in predicting waiting times.</p><p><strong>Conclusions: </strong>Task-specific prediction models are more appropriate for accurately predicting waiting times across various medical tasks. Guided by queue theory principles, we developed machine learning models for the waiting time prediction of each medical task and highlighted the importance of queue-related predictors.</p>\",\"PeriodicalId\":56334,\"journal\":{\"name\":\"JMIR Medical Informatics\",\"volume\":\"13 \",\"pages\":\"e77297\"},\"PeriodicalIF\":3.8000,\"publicationDate\":\"2025-09-29\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"https://www.ncbi.nlm.nih.gov/pmc/articles/PMC12481172/pdf/\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"JMIR Medical Informatics\",\"FirstCategoryId\":\"3\",\"ListUrlMain\":\"https://doi.org/10.2196/77297\",\"RegionNum\":3,\"RegionCategory\":\"医学\",\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"Q2\",\"JCRName\":\"MEDICAL INFORMATICS\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"JMIR Medical Informatics","FirstCategoryId":"3","ListUrlMain":"https://doi.org/10.2196/77297","RegionNum":3,"RegionCategory":"医学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q2","JCRName":"MEDICAL INFORMATICS","Score":null,"Total":0}
Predicting Waiting Times for Medical Tasks in a Pediatric Hospital Using Machine Learning: Comprehensive, Retrospective, Real-World Study.
Background: The shortage of pediatric medical resources and overcrowding in children's hospitals are severe issues in China. Accurately predicting waiting times can help optimize hospital operational efficiency.
Objective: This study aims to develop machine learning models to predict waiting times for various laboratory and radiology examinations at a pediatric hospital.
Methods: Time stamp data from laboratory and radiology examinations were retrospectively collected from the pediatric hospital information system between November 1, 2024, and March 13, 2025. Two queue-related and 4 time-based features were extracted using queue theory. Linear regression and 8 machine learning models were trained to predict waiting times for each medical task. Hyperparameters were fine-tuned using randomized search and 10-fold cross-validation, and the bootstrap method was used for model evaluation. Mean absolute error, mean square error, root mean square error, and the coefficient of determination (R²) were used as evaluation metrics. Shapley additive explanations values were used to assess feature importance.
Results: A total of 230,864 time-stamped records were included after data preprocessing. The median waiting time was 4.817 (IQR 1.867-12.050) minutes for all medical tasks. Waiting times for radiology examinations were generally longer than those for laboratory tests. Tree-based algorithms, such as random forest and classification and regression trees, performed best in predicting laboratory test waiting times, with R² values ranging from mean 0.880(SD 0.003) to mean 0.934 (SD 0.003). However, the machine learning models did not perform well in predicting radiology examination waiting times, with R2 ranging from 0.114 (SD 0.005) to 0.719 (SD 0.004). Feature importance analysis revealed that queue-related predictors, especially the number of queuing patients, were the most important in predicting waiting times.
Conclusions: Task-specific prediction models are more appropriate for accurately predicting waiting times across various medical tasks. Guided by queue theory principles, we developed machine learning models for the waiting time prediction of each medical task and highlighted the importance of queue-related predictors.
期刊介绍:
JMIR Medical Informatics (JMI, ISSN 2291-9694) is a top-rated, tier A journal which focuses on clinical informatics, big data in health and health care, decision support for health professionals, electronic health records, ehealth infrastructures and implementation. It has a focus on applied, translational research, with a broad readership including clinicians, CIOs, engineers, industry and health informatics professionals.
Published by JMIR Publications, publisher of the Journal of Medical Internet Research (JMIR), the leading eHealth/mHealth journal (Impact Factor 2016: 5.175), JMIR Med Inform has a slightly different scope (emphasizing more on applications for clinicians and health professionals rather than consumers/citizens, which is the focus of JMIR), publishes even faster, and also allows papers which are more technical or more formative than what would be published in the Journal of Medical Internet Research.