Exemple #1
0
 def mean_hr(self, x, fs=500):
     """ Calculate the average heart rate
         from the raw ECG signal x by first
         obtaining the RR-intervals using
         R-peak detection.
     """
     rr = ecg_utilities.detect_r_peaks(x['data'][0], fs)
     return ecg_utilities.hrv_mean_hr(rr)
Exemple #2
0
 def rmssd(self, x, fs=500):
     """ Calculate RMSSD from the RR-vector. """
     rr = ecg_utilities.detect_r_peaks(x['data'][0], fs)
     return ecg_utilities.hrv_rmssd(rr)