Skip to main content

ntsa — nonlinear time-series analysis for dynamical-system models

DOI PyPI docs

Characterizes the dynamical regime of a model from a single long trajectory:

  • Lyapunov exponents
  • Delay embedding (optimal lag + false nearest neighbours)
  • Regime classification (fixed point / limit cycle period-k / frequency-locked / quasiperiodic / chaotic)
  • Yields a per-case diagnostic figure — one row of 8 panels. Example:

Figure 1: Dynamical systems diagnostics Time series | PSD | 3-D delay portrait | first-return map of local maxima | plane-crossing Poincaré section | recurrence plot | 3-D MDS | Lyapunov spectrum image

Documentation: andreanovoa.github.io/ntsa | Tutorial: tutorial_ntsa.ipynb

Key Reference: Kantz & Schreiber, Nonlinear Time Series Analysis (2004).

Install

pip install ntsa

Quickstart

from dynamodels.physical import Lorenz63
from ntsa import characterize as chz

chz.characterize([Lorenz63()], pdf_name='figs/l63.pdf')
python -m ntsa.characterize          # 4-case demo -> figs/ntsa_defaults.pdf (+ .png)

Works with any model implementing the model protocol — dynamodels is the reference implementation. Part of the same ecosystem as romda (real-time bias-aware data assimilation).

Citation

If you use this repository, please cite the software archive:

@software{novoa_ntsa,
  author = {Nóvoa},
  title = {ntsa: nonlinear time-series analysis for dynamical-system models},
  publisher = {Zenodo},
  doi = {10.5281/zenodo.21843575},
  url = {https://doi.org/10.5281/zenodo.21843575},
}

The routines in this package were developed from the codes published as supplementary material of Nóvoa & Magri (2022):

@article{novoa2022jfm,
  title = {Real-time thermoacoustic data assimilation},
  journal = {Journal of Fluid Mechanics},
  volume = {948},
  pages = {A35},
  year = {2022},
  doi = {10.1017/jfm.2022.653},
  url = {https://doi.org/10.1017/jfm.2022.653},
  eprint = {2106.06409},
  archivePrefix = {arXiv},
  author = {Nóvoa and Magri},
}

Development

pip install -e ".[dev]"
python -m pytest tests/
ruff check ntsa/ tests/

Releases: bump version in pyproject.toml, then git tag vX.Y.Z && git push --tags (publishes to PyPI); docs deploy to GitHub Pages on every push to main.

License

MIT

Metadata

Release files for ntsa 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ntsa 0.3.1
File Size Uploaded
ntsa-0.3.1.tar.gz 38.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ntsa 0.3.1
File Interpreter ABI Platform
ntsa-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 75.9 kB

Release files / ntsa-0.3.1.tar.gz

Download URL ntsa-0.3.1.tar.gz
Size 38.7 kB
Tags Source
SHA-256 checksum
How to use checksums
0d318d58b2fc0340b209851d3c6951c7a18c7ef50b7019a392b1411b254114e9
BLAKE2b-256 checksum
How to use checksums
4ed6225f4f1c7ba18f63e6f44d7f25411b2fd470007b37871bc44b050558f19e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 19, 2026.

Transparency log

Release files / ntsa-0.3.1-py3-none-any.whl

Download URL ntsa-0.3.1-py3-none-any.whl
Size 37.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
05d8bd80a41ee67d9228a3f2b80065511422258484644f6a7bad7d7ec7e5d93a
BLAKE2b-256 checksum
How to use checksums
70b5960246372871ce19a21ee65193680da2ae10ee1deb48dcb033c76c5ea876
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 19, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.3.1 This release

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page