Cardio PyMEA: A user-friendly, open-source Python application for cardiomyocyte microelectrode array analysis

Open source analytical software for the analysis of electrophysiological cardiomyocyte data offers a variety of new functionalities to complement closed-source, proprietary tools. Here, we present the Cardio PyMEA application, a free, modifiable, and open source program for the analysis of microelectrode array (MEA) data obtained from cardiomyocyte cultures. Major software capabilities include: beat detection; pacemaker origin estimation; beat amplitude and interval; local activation time, upstroke velocity, and conduction velocity; analysis of cardiomyocyte property-distance relationships; and robust power law analysis of pacemaker spatiotemporal instability. Cardio PyMEA was written entirely in Python 3 to provide an accessible, integrated workflow that possesses a user-friendly graphical user interface (GUI) written in PyQt5 to allow for performant, cross-platform utilization. This application makes use of object-oriented programming (OOP) principles to facilitate the relatively straightforward incorporation of custom functionalities, e.g. power law analysis, that suit the needs of the user. Cardio PyMEA is available as an open source application under the terms of the GNU General Public License (GPL). The source code for Cardio PyMEA can be downloaded from Github at the following repository: https://github.com/csdunhamUC/cardio_pymea.

2. The abstract is very focused on the software license and other computational aspects of PyMEA. However, the reviewer believes that providing a compact and general overview of the main capabilities of the software (beat detection, pacemaker origin estimation, and etc) on the abstract could further gain the attention of researchers working within this field and looking for this kind of solution.
3. The authors could explain the method used to compute the field potential duration (FPD) according to the mentioned reference using a simple and compact approach. All the other details from the features of the software are well explained, with the exception of this calculation.
Specific comments and suggestions 1. No page or line numbering are provided in the manuscript. This makes the process of reviewing a little bit harder.
2. Section "Automated electrode exclusion". Instead of using the term data modification, the reviewer thinks that data treatment or data pre-processing is more adequate.
3. After the equation of the radius r, it is said: These parameters are additionally bound. It seems the authors are referring to imposing bounds on the parameters during the leastsquares fitting. Please make it clearer.
4. LAT was defined 2 times or more.

5.
Please specify what type of finite difference was applied to approximate the derivatives for the maximum upstroke velocity calculation (forward,backward,central,...).
6. Conduction velocity calculation. Although very simple and easy to infer, the formula "electrode-distance/∆LAT ", lacks the definition of ∆LAT .
7. Property vs distance from pacemaker. Please define multiplier 8. In general the texts describing the name of functions within the code are written with another font style. For LaTeX users this is usually done with the command texttt.
9. Please explain or provide a reference for Sturge's rule.
10. It seems the concepts of power-law and probability density functions are mixed or entwined. he authors 11. Should some signal processing tools be used for noisy signals before MEA calculations? Is this a common practice within the field? Perhaps the authors could mention something about this.
12. Cardio PyMEA provides uniques (section). Before the caption of Fig.8 the authors mention "suggesting that there is a strong relationship between these two properties", when refering to the R 2 coefficient of determination. Perhaps using "suggesting a good fitting was achieved", or something similar would be better, to avoid a possible confusion with a positive correlation.
Suggestions for future improvements of the software 1. At the final section of the manuscript the authors mention the software may freeze when using large datasets. On the reviewer's experience this may be related to the usage of the matplotlib as a backend for the plots. Although it is pretty standard for Python code to use matplotlib, for huge datasets it takes significant time to render and plot data with this library. An alternative is to use the PyQtGraph library (https://www.pyqtgraph.org/), which is faster and can easily handle large datasets. It can also deliver high-quality plots.
2. Currently PyMEA only supports input data in the format of a specific MEA recording software. For a broader use, this could be extended to other input formats which might be also in use within the MEA community.
3. Also with respect to input/output, the authors could consider in the future using data in the HDF5 file format. It can significantly reduce storage of large datasets, and may provide a faster interface for reading and writing data, which could also impact on the performance of the software when loading large datasets.