neuropsychology / NeuroKit

NeuroKit2: The Python Toolbox for Neurophysiological Signal Processing
https://neuropsychology.github.io/NeuroKit
MIT License
1.56k stars 419 forks source link

ECG: Heart Rate Variability (HRV) #131

Closed DominiqueMakowski closed 3 years ago

DominiqueMakowski commented 4 years ago

HRV

image

General

Complexity

DominiqueMakowski commented 4 years ago

@Tam-Pham could you take a look at these super easy formulae: https://link.springer.com/article/10.1186/s12938-017-0402-3 ^^ so we can add these additional poincaré indices as it seems highly relevant especially for short-term intervals 🙏

DominiqueMakowski commented 4 years ago

Time-frequency Domain Analysis (TF)

Still from https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3913584/pdf/pone.0081896.pdf; 3 methods:

We might want to include some of these as generic methods under something like signal_timefrequency or something.

image

Each HRV signal is divided into 5 segments of equal length, each segment is approximately 15 seconds in time domain. The average energy of each segment was computed. The features are:

  • MAX w: maximum amount of energy in each window.
  • MIN w: minimum amount of energy in each window.
  • DIF w: difference between maximum and minimum amount of energy between windows.
  • STD w: standard deviation between energy of time windows. The obtained signal in TF domain is also divided into three frequency segments.
  • Evlf: the total energy of signal in very low frequency band (0.003–0.04) Hz, divided by length of band (0.037).
  • Elf: the total energy of signal in low frequency band (0.04–0.15) Hz, divided by length of band (0.11).
  • Ehf: the total energy of signal in high frequency band (0.15–0.4) Hz, divided by length of band (0.25).
  • Fvlf: the average of energy signal in very low frequency band (0.04–0.003) Hz.
  • Flf: the average of energy signal in low frequency band (0.04– 0.15) Hz.
  • Fhf: the average of energy signal in high frequency band (0.15– 0.4) Hz.
  • Also, we have defined the first order derivative as a feature to show the difference between adjacent windows. This derivative is the difference between the average energy in subsequent windows. This derivative for the first window(first 15 S) was computed by the difference between this window and the last 15 seconds in the second minute. So the first order derivative feature is computed as below...
stale[bot] commented 3 years ago

This issue has been automatically marked as inactive because it has not had recent activity. It will eventually be closed if no further activity occurs.

Tam-Pham commented 3 years ago

BUMPED. need to add SDANN and SDNN index

DominiqueMakowski commented 3 years ago

Closing in favour of https://github.com/neuropsychology/NeuroKit/projects/5