Code to reproduce the figures from Wimalasena et al. 2025
To ensure reproducibility, this repository includes an environment.yml file specifying the required Python packages and versions.
Make sure you have conda or mamba installed.
Then run:
conda env create -f environment.ymlThis will create a new conda environment (named spinal-pop-dyn-figs or as specified in the YAML file).
Once created, activate the environment:
conda activate spinal-pop-dyn-figsYou are now ready to run the figure generation scripts.
The recommended way to run the figure scripts is to open them in Visual Studio Code and use the Interactive Python window (e.g., Jupyter-style cells). This allows step-by-step execution and interactive debugging.
Each script is designed to generate one figure directly from the source data in data/SourceData.xlsx.
⚠️ Make sure the data file is present before running scripts. Seedata/README.mdfor setup instructions.
Some figure scripts support switching between subjects via a C_ID variable defined near the top of the file.
To generate figures for a specific subject:
C_ID = "1" # or "2"