MIT-LCP / physionet

A collection of tools for working with the PhysioNet repository.
http://physionet.org/
MIT License
69 stars 17 forks source link

Baseline Wander and Power Line Interference filtering of ECG data #48

Closed Sophzr closed 7 years ago

Sophzr commented 7 years ago

Hello everyone, I have a question regarding ECG pre-processing: I am working with MIT-BIH Arrhythmia Database and want to extract RR interval. I am quite new to ECG analysis and feature extraction. So, based on literature, I used band-pass FIR filter (1-50Hz) to remove baseline wander and power line interference. However, when I use gqrs() function after filtering, it extracts about 6500 qrs signals which is not correct. I also tried gqrs() on data without filtering and it detected about 2270 qrs signals which is about right. Now, my question is that do I need to filter data before using gqrs()? Thanks

alistairewj commented 7 years ago

You can learn a bit more about gqrs by reading the source code, or by looking at the configuration file. In particular this comment in the source code may shed some light:

/* sm() implements a trapezoidal low pass (smoothing) filter (with a gain of
   4*smdt) applied to input signal sig before the QRS matched filter qf().
   Before attempting to 'rewind' by more than BUFLN-smdt samples, reset smt
   and smt0.
 */