These R files are example code which go along with the paper:
SIMULATING EMERGENCY DEPARTMENT BOARDING USING A DIFFERENCE EQUATION
New R code file (2026): ED Boarding MC simulation, generalized This version doesn't require a linear equation (or non-linear for that matter). All that is needed are the empirical values for: max patients that start boarding min patients that start boarding max patients that end boarding min patients that end boarding plus a starting value to begin the difference equation iteration
This version includes: -a bootstrap function to estimate standard errors -building of a matrix to iterate over a wide range or scenarios -an informative chart to show the range of new boarders and how that affects proportion of time over a boarder threshold -importance sampling section to examine values in the tail(s)
For more information please visit:
https://doi.org/10.1101/2020.03.19.20039040
This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.
