Towards Sharing Tools, and Artifacts, for Reusable Simulation (STARS): a minimal model example
The materials and methods in this repository support work towards developing the STARS healthcare framework (Sharing Tools and Artifacts for Reusable Simulations in healthcare). The code and written materials here demonstrate the application of STARS version 1 to sharing a SimPy
discrete-event simulation model and associated research artifacts.
- All artifacts in this repository are linked to study researchers via ORCIDs;
- Model code is made available under an MIT license;
- Python dependencies are managed through
mamba
; - Documentation of the model is enhanced using a simple Jupyter notebook.
- The python model itself can be viewed and executed in Jupyter notebooks via Binder;
- The materials are deposited and made citable using Zenodo;
- The model is sharable with other researchers and the NHS without the need to install software.
- A full suite of automated tests are provided with the model.
Added
- All model classes and functions now have python type hints
treat_sim.datasets
module withload_nelson_arrivals
,load_alternative_arrivals
andvalid_arrival_profile
functionstests/test_datasets.py
contains functional and dirty tests for loading and using internal arrival profile datasets.
Changed
Scenario
defaults to the time dependent arrival profile given in Nelson (2013), but also acceptsarrival_profile
apandas.DataFrame
parameter for scenario analysis.- Default arrival profile is sourced from local package rather than GitHub URL.
Fixed
- MODEL: thinning algorithm:
np.Inf
->np.inf
for compatibility withnumpy>=2