{"title":"BayesianFitForecast: a user-friendly R toolbox for parameter estimation and forecasting with ordinary differential equations.","authors":"Hamed Karami, Amanda Bleichrodt, Ruiyan Luo, Gerardo Chowell","doi":"10.1186/s12911-025-03208-z","DOIUrl":null,"url":null,"abstract":"<p><strong>Background: </strong>Mathematical models based on ordinary differential equations (ODEs) are essential tools across various scientific disciplines, including biology, ecology, epidemic modeling, and healthcare informatics, where they are used to simulate complex dynamic systems and inform decision-making. However, implementing Bayesian calibration and forecasting typically requires substantial coding in Stan or similar tools. To support Bayesian parameter estimation and forecasting for such systems, we introduce BayesianFitForecast, a user-friendly R toolbox specifically developed to streamline Bayesian parameter estimation and forecasting in ODE models, making it particularly relevant to health informatics and public health decision-making ( https://github.com/gchowell/BayesianFitForecast/ ).</p><p><strong>Results: </strong>This toolbox enables automatic generation of Stan files, allowing users to configure models, define priors, and analyze results with minimal programming expertise. By eliminating manual coding, BayesianFitForecast significantly lowers the technical barrier to Bayesian inference with dynamical systems. We demonstrate its flexibility and usability through applications to historical epidemic datasets (e.g., the 1918 influenza pandemic in San Francisco and the 1896-1897 Bombay plague) and simulated data, showing robust parameter estimation and forecasting performance under Poisson and negative binomial observation error structures. The toolbox also provides robust tools for evaluating model performance, including convergence diagnostics, posterior distributions, credible intervals, and performance metrics.</p><p><strong>Conclusion: </strong>By improving the accessibility of advanced Bayesian methods, BayesianFitForecast broadens the application of Bayesian inference in time-series modeling, healthcare forecasting, and epidemiological applications. In addition to the R scripting interface, a built-in Shiny web application is included, enabling interactive model configuration, visualization, and forecasting. A tutorial video demonstrating the toolbox's functionality is also available ( https://youtu.be/jnxMjz3V3n8 ).</p>","PeriodicalId":9340,"journal":{"name":"BMC Medical Informatics and Decision Making","volume":"25 1","pages":"385"},"PeriodicalIF":3.8000,"publicationDate":"2025-10-15","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"BMC Medical Informatics and Decision Making","FirstCategoryId":"3","ListUrlMain":"https://doi.org/10.1186/s12911-025-03208-z","RegionNum":3,"RegionCategory":"医学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q2","JCRName":"MEDICAL INFORMATICS","Score":null,"Total":0}
引用次数: 0
Abstract
Background: Mathematical models based on ordinary differential equations (ODEs) are essential tools across various scientific disciplines, including biology, ecology, epidemic modeling, and healthcare informatics, where they are used to simulate complex dynamic systems and inform decision-making. However, implementing Bayesian calibration and forecasting typically requires substantial coding in Stan or similar tools. To support Bayesian parameter estimation and forecasting for such systems, we introduce BayesianFitForecast, a user-friendly R toolbox specifically developed to streamline Bayesian parameter estimation and forecasting in ODE models, making it particularly relevant to health informatics and public health decision-making ( https://github.com/gchowell/BayesianFitForecast/ ).
Results: This toolbox enables automatic generation of Stan files, allowing users to configure models, define priors, and analyze results with minimal programming expertise. By eliminating manual coding, BayesianFitForecast significantly lowers the technical barrier to Bayesian inference with dynamical systems. We demonstrate its flexibility and usability through applications to historical epidemic datasets (e.g., the 1918 influenza pandemic in San Francisco and the 1896-1897 Bombay plague) and simulated data, showing robust parameter estimation and forecasting performance under Poisson and negative binomial observation error structures. The toolbox also provides robust tools for evaluating model performance, including convergence diagnostics, posterior distributions, credible intervals, and performance metrics.
Conclusion: By improving the accessibility of advanced Bayesian methods, BayesianFitForecast broadens the application of Bayesian inference in time-series modeling, healthcare forecasting, and epidemiological applications. In addition to the R scripting interface, a built-in Shiny web application is included, enabling interactive model configuration, visualization, and forecasting. A tutorial video demonstrating the toolbox's functionality is also available ( https://youtu.be/jnxMjz3V3n8 ).
期刊介绍:
BMC Medical Informatics and Decision Making is an open access journal publishing original peer-reviewed research articles in relation to the design, development, implementation, use, and evaluation of health information technologies and decision-making for human health.