This page provides you with the source codes of the computations and results underlying

Espinoso A and Andrzejak RG. 2022. Phase irregularity: A conceptually simple and efficient approach to characterize electroencephalographic recordings from epilepsy patients. Phys. Rev. E. 105, 034212

If you use the source codes, please make sure that you give a reference to the manuscript. (The correct way to cite this paper is shown above, no page numbers should be given.)

Database, source code and results


The signals used for the analysis presented in the manuscript are from the Bern-Barcelona database. The database can be found in:

  • The Downloads section here
  • The library page here

Source code

In order to understand the source code, you should first read the manuscript and the readme PDF file. To find the PDF file of the manuscript, please follow the link at the top of this page. The readme PDF can be found below:

The code is done using MATLAB and it uses the same notation for mathematical symbols as in the manuscript. Additional comments can be found throughout the source code. You can download the codes using the following link:

The code files starting by "EA" are done for obtaining the results of the manuscript Espinoso 2022. The code files starting by "ASR" were used for obtaining surrogates and filter the signals. If you use these last mentioned codes, please cite the following paper:

Andrzejak RG, Schindler K, Rummel C. Nonrandomness, nonlinear dependence, and nonstationarity of electroencephalographic recordings from epilepsy patients. Phys. Rev. E, 86, 046206, 2012

To get started with the code for obtaining the EEG results open EA_EEG_Main.m, and for the Rössler results open EA_Rossler_Main.m. We have tested the code, and to the best of our knowledge it has no bugs. In case you have any questions or problems, please contact us.


The same results obtained in the paper for the EEG and Rössler are available in MATLAB format here:

To understand the organization of the results provided here, please read the readme file.

Please, read the important remark in the readme file. If you run the analysis using the codes provided here, you will not get identical results as in the paper. This is the reason why we provide the identical results here.

Mirrowed material

Legal Agreement

The source codes and results on these sites are free of charge for research and education purposes only. Any commercial or military use is prohibited. All resources are provided without any expressed or implied warranty. In no event the authors of the article or any of their host institutions are liable for any damages arising from the use of the software or results.