This repository contains the code needed to reproduce the figures and simulations for the paper "Immediate and delayed response of simulated human atrial myocytes to clinically-relevant hypokalemia" 10.3389/fphys.2021.651162. To cite this work, please use the information provided in the CITATION file.
- Python 3.4+
- Myokit 1.30.1+
- A working OpenCL installation is required for the tissue simulations
- Installation help for Myokit and OpenCL
- Shared code is stored in
shared.pyand used by several figures.
Models:
- The Courtemanche et al. 1998 model. Original paper doi: 10.1152/ajpheart.1998.275.1.h301. Myokit model code was adapted from an existing CellML model in PMR.
- The Grandi, Pandit, Voigt et al. 2011 model. Original paper doi: 10.1161/CIRCRESAHA.111.253955 Myokit model code was newly implemented and a CellML model was uploaded to PMR.
- The Koivumäki, Korhonen et al. 2011 model. Original paper doi: 10.1371/journal.pcbi.1001067 Myokit model code was newly implemented and a CellML model was uploaded to PMR.
- The Maleckar et al. 2008 model. Original paper doi: 10.1016/j.pbiomolbio.2009.01.010 Myokit model code was adapted from an existing CellML model in PMR.
- The Ni et al. 2017 model. Original paper doi: 10.3389/fphys.2017.00946 Myokit model code was newly implemented and a CellML model was uploaded to PMR.
- The Nygren et al. 1998 model. Original paper doi: 10.1161/01.RES.82.1.63 Myokit model code was adapted from an existing CellML model.
- The Voigt, Heijman et al. 2013 model. Original paper doi: 10.1016/j.yjmcc.2013.03.011 Myokit model code was adapted from this code and a CellML model was uploaded to PMR.
To re-run the single cell simulations, and create the main figures, use:
- Figure 1:
f1.py - Figure 2:
f2.py - Figure 3:
f3.py - Figure 4:
f4.py - Figure 5:
f5.py - Finally, to generate the non-schematic parts of Figure 6, use
f6.py.
These store their figures in directories figure-1, figure-2, etc.
Several supplementary figures are provided:
s1-vr.pycreates supplementary figure 1, showing digitised data from Gelband et al. 1972 and Ten Eick & Singer, 1979, and comparing with model predictions.s2-ap-cat.pycreates a model comparison figure showing AP and CaT.s3-relative-contributions.pycreates a figure showing relative contributions of all currents.s4-restitution.py <model>creates a restitution curve for the given model, and plots it alongside data stored inliterature-data, digitised from Van Wagoner et al..s5-ik1-ko.pygenerates a figure showing the three ways in which external K+ affects IK1.s6-ik1-x.pygenerates a figure showing the K-dependence of the rectifiation variable in four models.s7-fast-slow.py <model>generates a figure showing short and long-term changes in concentrations, AP, IK1, INaK, and INaCa.s8-strand.pyperforms strand simulations and creates an overview figure.s9-dvdtmax.py <model>generates a figure showing maximum dV/dt for all models.s10-ina-sd.py <model>generates a figure with single-cell excitability data (INa availability and SD curves).s11a-rm-calculations.pycreates a figure showing details of membrane resistance calculations, as dos11b-rm-ko.py, ands11c-rm-low.py(which can be customised by changing the variablesk,dt, and `dv`` inside the script).s11d-rm.pycreates a membrane resistance figure for a chosen model.s12-iv.py <model>generates a figure showing instantaneous IV relationships at low K.
Linux or OS/X users can use the all-x scripts to generate figures for all models.
Similarly, the all script regenerates all figures in this study.