
PECCARY#
peccary (Permutation Entropy and statistiCal Complexity Analysis for astRophYsics)
is a Python package for distinguishing between regular, complex, and stochastic
behavior in timeseries. It is based on the work by
Bandt & Pompe (2002),
Rosso et al. (2007),
and
Weck et al. (2015).
This code is also based on work by collaborator David Schaffner, who wrote the initial
version of some of the method, called PESCy.
In addition to calculating the Permutation Entropy (\(H\)) and Statistical Complexity (\(C\)) values, this package also has plotting tools for the \(HC\)-plane and visualizing the resulting \([H,C]\) values for various timeseries, examples timeseries, and utility functions.
A detailed summary of the PECCARY method can be found in Hyman, Daniel, & Schaffner (2025). If you make use of PECCARY, please include a citation to Hyman, Daniel, & Schaffner (2025) in any publications.
Note
This project is under active development.
Contents#
Citation and Attribution#
If you make use of this code, please cite the paper:
@article{peccaryPaper,
author = {{Hyman}, S{\'o}ley {\'O}. and {Daniel}, Kathryne J. and {Schaffner}, David A.},
title = "{PECCARY: A Novel Approach for Characterizing Orbital Complexity, Stochasticity, and Regularity}",
journal = {\apj},
keywords = {Theoretical techniques, Galaxy dynamics, Orbits, Orbit determination, Time series analysis, Astronomical methods, Astronomy software, 2093, 591, 1184, 1175, 1916, 1043, 1855, Instrumentation and Methods for Astrophysics, Astrophysics of Galaxies},
year = 2025,
month = jul,
volume = {987},
number = {2},
eid = {195},
pages = {195},
doi = {10.3847/1538-4357/adda3e},
archivePrefix = {arXiv},
eprint = {2407.11970},
primaryClass = {astro-ph.IM},
adsurl = {https://ui.adsabs.harvard.edu/abs/2025ApJ...987..195H},
adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}
Please also cite the PECCARY version you used as a software citation using the Zenodo DOI :
@software{peccaryZenodo,
author = {Hyman, Sóley and
Schaffner, David},
title = {soleyhyman/peccary: v0.1.1},
month = jul,
year = 2024,
publisher = {Zenodo},
version = {v0.1.1},
doi = {10.5281/zenodo.13168299},
url = {https://doi.org/10.5281/zenodo.13168299},
swhid = {swh:1:dir:2268b12e64f82631437df8024f5cd6904a85c396
;origin=https://doi.org/10.5281/zenodo.13168298;vi
sit=swh:1:snp:d7900e21d7d057b5b231c93c616cdb6b8dcd
b9ae;anchor=swh:1:rel:73c52e8ebc846b6f6ba39fcad830
8c60fcc9481c;path=/
},
}