Skip to main content

This toolbox provides computation methods for skin sympathetic nerve activity (SKNA), which can be derived from electrocardiogram (ECG) signals collected under specific recording conditions.

Project description

pyskna

This toolbox provides computation methods for skin nerve activity (SKNA), which can be derived from electrocardiogram (ECG) signals collected under specific recording conditions.

Installation

pip install pyskna

Example

import pandas as pd
from pyskna import extract_iSKNA, extract_TVSKNA

# Load EKG file
EKG = pd.read_csv("example_ekg.csv", header=None).to_numpy().reshape(-1)

# iSKNA computation
SKNA_dict = extract_iSKNA(input_ary=EKG, fs=4000, f_l=500, f_h=1000, smoothing_win_len=0.1)

# TVSKNA computation
TVSKNA_dict = extract_TVSKNA(input_ary=EKG, fs=4000, smoothing_win_len=0.1, thread_n=12)

See test.py

Also see API.md

Compatibility for extract_TVSKNA

The extract_TVSKNA function uses VFCDM binaries, which has been tested with Python 3.11 on the following platforms:

  • macOS (Apple Silicon / ARM64)
  • Linux (x86_64)
  • Windows (x86_64)

Notes

  • macOS x86_64 (Intel) is expected to work, but has not been formally tested.
  • 32-bit systems are not supported; the VFCDM library has only been compiled for 64-bit architectures.

Citation

The neuECG technique for computing iSKNA has been implemented based on the following paper:

iSKNA:

Kusayama, T., Wong, J., Liu, X., He, W., Doytchinova, A., Robinson, E. A., ... & Chen, P. S. (2020).
Simultaneous noninvasive recording of electrocardiogram and skin sympathetic nerve activity (neuECG).
Nature Protocols, 15(5), 1853–1877.

TVSKNA:

If you use TVSKNA for 4kHz sampling frequency. Please cite the following paper:

  • For 4 kHz sampling:

    Kong, Y., Baghestani, F., D'Angelo, W., Chen, I. P., & Chon, K. H. (2025).
    A New Approach to Characterize Dynamics of ECG-Derived Skin Nerve Activity via Time-Varying Spectral Analysis.
    IEEE Transactions on Affective Computing.

  • For 500 and 1000 Hz sampling:

    Kong, Y., Baghestani, F., D'Angelo, W., Chen, I. P., & Chon, K. H. (2025).
    A New Approach to Characterize Dynamics of ECG-Derived Skin Nerve Activity via Time-Varying Spectral Analysis.
    IEEE Transactions on Affective Computing.

    Kong, Y., Baghestani, F., Chen, I. P., & Chon, K. H. (2025).
    Feasibility of Extracting Skin Nerve Activity from Electrocardiogram Recorded at a Low Sampling Frequency.
    arXiv preprint, arXiv:2508.00494. https://doi.org/10.48550/arXiv.2508.00494

⚠️ Patent Notice

Some functions (e.g., process_tvskna) in this library interface with the VFCDM algorithm covered by
U.S. Patent No. US8858450B2, owned by Ki Chon, Ph.D. and Kihwan Ju, Ph.D.
(Assignee: Research Foundation of the State University of New York).

By using VFCDM‑related functions (e.g., process_tvskna) in PySKNA, you agree to the
LICENSE.md and PATENT_NOTICE.md provided in the VFCDM Binaries repository, solely for non-commercial, academic, and research use.

Please see the PySKNA LICENSE.md for more details.

Commercial use of the patented components requires a separate license.

For patent‑related inquiries, contact ki.chon@uconn.edu.

For all other matters, contact youngsun.kong.phd@gmail.com.

📄 Citation

If you use this library in your research and publish your results, please cite it as follows:

APA 7th: Kong, Y. (2025). pySKNA (Version 0.1.0) [Computer software]. GitHub. https://github.com/ykong-phd/pyskna

IEEE: Y. Kong, pySKNA, Version 0.1.0, GitHub repository, 2025. [Online]. Available: https://github.com/ykong-phd/pyskna

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyskna-0.1.1.tar.gz (9.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyskna-0.1.1-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

File details

Details for the file pyskna-0.1.1.tar.gz.

File metadata

  • Download URL: pyskna-0.1.1.tar.gz
  • Upload date:
  • Size: 9.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.13

File hashes

Hashes for pyskna-0.1.1.tar.gz
Algorithm Hash digest
SHA256 752f5fb6d09fad5c14a93547c6af3aa25b4bca6eee219be405ddfb2a640e66c2
MD5 29a80472e5fd0f1bc6f3c2ad36af22e7
BLAKE2b-256 43ccd65b8384c192b1aa68c95737dfae2f1ffe9afbeb01f96c7ca08fa5e4021c

See more details on using hashes here.

File details

Details for the file pyskna-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: pyskna-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 9.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.13

File hashes

Hashes for pyskna-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e4f73cc82d297cb5fc164359708aa10dff9b78f23be21cde8c44a98c5a0854ce
MD5 84d4e3b20ca8f3282c53312bad7c2d44
BLAKE2b-256 0711c2125457b61d1337227513e536d9ca28c47c3a7bdf17a340104ac75d5fd7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page