meta00 / vital_sqi

A package for physiological signal quality control
MIT License
31 stars 11 forks source link

power spectrum calculation #22

Closed meta00 closed 3 years ago

meta00 commented 3 years ago

in common/power_spectrum.py

Koaha commented 3 years ago

Function calculate_Spectrum takes input is the rr_intervals. The function converts to beat-per-minute unit and computes the power density or spectral power value (controlled by argument power_type). Power computes using either Welch, Lomb, or Periodogram. If Spectrogram is defined, the output of power is a 2d n x m array, n: times; m: frequencies.

Output: an array of frequencies, an array of relevant power

Koaha commented 3 years ago

@meta00 Review branch to merge with main

Koaha commented 3 years ago

Fixed the computation by using RR interval as the input and merged pull request #36