Вы находитесь на странице: 1из 11

G Model BSPC-247; No.

of Pages 11

ARTICLE IN PRESS
Biomedical Signal Processing and Control xxx (2011) xxxxxx

Contents lists available at ScienceDirect

Biomedical Signal Processing and Control


journal homepage: www.elsevier.com/locate/bspc

A novel method for detecting R-peaks in electrocardiogram (ECG) signal


M.Sabarimalai Manikandan a, , K.P. Soman b
a b

Department of Electronics and Communication Engineering, Amrita Vishwa Vidyapeetham, Coimbatore, Tamilnadu, India Center for Excellence in Computational Engineering and Networking, Amrita Vishwa Vidyapeetham, Coimbatore, Tamilnadu, India

a r t i c l e

i n f o

a b s t r a c t
The R-peak detection is crucial in all kinds of electrocardiogram (ECG) applications. However, almost all existing R-peak detectors suffer from the non-stationarity of both QRS morphology and noise. To combat this difculty, we propose a new R-peak detector, which is based on the new preprocessing technique and an automated peak-nding logic. In this paper, we rst demonstrate that the proposed preprocessor with a Shannon energy envelope (SEE) estimator is better able to detect R-peaks in case of wider and small QRS complexes, negative QRS polarities, and sudden changes in QRS amplitudes over that using the absolute value, energy value, and Shannon entropy features. Then we justify the simplicity and robustness of the proposed peak-nding logic using the Hilbert-transform (HT) and moving average (MA) lter. The proposed R-peak detector is validated using the rst-channel of the 48 ECG records of the MIT-BITH arrhythmia database, and achieves average detection accuracy of 99.80%, sensitivity of 99.93% and positive predictivity of 99.86%. Various experimental results show that the proposed R-peak detection method signicantly outperforms other well-known methods in case of noisy or pathological signals. 2011 Elsevier Ltd. All rights reserved.

Article history: Received 22 November 2010 Received in revised form 3 March 2011 Accepted 4 March 2011 Available online xxx Keywords: Biosignal processing QRS detection ECG analysis Signal detection

1. Introduction Automatic detection of the R-peaks in a long-term electrocardiogram (ECG) signal is the most important step for diagnosis of cardiac disorders, heart-rate variability analysis, biometric, and ECG coding systems [13]. The performance of these systems heavily rely on the accuracy of the R-peak detector. Many methods based on the derivatives [6], digital lters [710], linear prediction, wavelet transform [1,1214], mathematical morphology [15,16], and empirical mode decomposition (EMD) [17], geometrical matching [18], neural networks [19] and hybrid approach [11] have been developed for the detection of R-peaks. Methods based on the ltering techniques and decision rules are computationally efcient and hence ideal for any automatic ECG analysis [9]. Most of the methods include a preprocessing or feature extraction stage and a decision stage [4]. Generally, preprocessing stage applies various signal processing techniques to accentuate the QRS complex and suppress noises but most of them have some drawbacks. In [7], the tradeoff between misses and false detections relies on the selection of bandwidth of the lter and size of the moving-window integrator. The WT-based QRS detector has the choice problem of mother wavelet and scales to obtain QRS events. Although the EMD-based approach in [17] can overcome the choice problem of basis function,

Corresponding author. Tel.: +91 0422 2656422. E-mail address: msm.sabari@gmail.com (M.Sabarimalai Manikandan). 1746-8094/$ see front matter 2011 Elsevier Ltd. All rights reserved. doi:10.1016/j.bspc.2011.03.004

selection of a set of intrinsic mode functions (IMFs) is very difcult under noisy environments. The performance can be improved by designing more effective ltering and better threshold adjustment procedures [17]. However, it is hard to design a single comprehensive preprocessing technique for achieving simultaneous QRS enhancement and noise reduction effectively in practice. Therefore, most of the works paid attention on constructing suitable decision rules based on the preprocessing results. The decision stage of the ltering approaches commonly consists of a set of heuristic rules and a set of tactics for nding the approximate location of candidate R-peak. These thresholds are adapted periodically based upon amplitudes, durations and RRintervals of past detected R-peaks. In such a case, performance relies highly on the accurate estimation of initial parameters in the learning phase. Most of methods had higher false-negative (FN) and false-positive (FP) detections in case of small and wider QRS complexes. Therefore, additional decision rules have been developed from a positive view but they have negative effects. For example, in [9], failure instances of the ve QRS detection methods with and without use of secondary threshold were investigated by using the MIT-BITH arrhythmia database records 108 (negative R-peaks and high noises) and 208 (wide-QRS complexes). Experimental results showed that the detection accuracy of the Method I, modied Method I, and Method III is very poor for negative R-peaks in record 108 [9]. Furthermore, Method I and Method III fail to detect small and wider QRS complexes in record 208. In this case, modied Method I, Method II and modied Method II had better detections

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11 2

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx

with use of secondary threshold but it results in higher FP detections for noisy ECG signal. Moreover, many methods had higher FN for ECG with small and wider QRS complexes. Therefore, two rules with adaptive amplitude-dependent and time-dependent thresholds were widely adopted to reject or include identied R-peaks located at tm and tn : (i) if tn tm < 0.2 s (refractory period) and (ii) search back if tn tm > 1.5RRavg . These rules may improve detections for regular rhythms but some rules may be in conict with others. Furthermore, searchback mechanism cannot be halted in case of irregular rhythms with varying QRS complexes. Moreover, there are often lots of thresholds dened in heuristic rules. The above detection issues clearly indicate that it is hard to nd a proper rule set in case of (i) wide QRS complexes, (ii) low-amplitude QRS complexes, (iii) negative QRS polarities, (iv) sudden changes in RR intervals, (v) sudden changes in QRS amplitudes, (vi) sudden changes in QRS morphologies, and (vii) sharp P- and T-waves. All of the aforementioned constraints on the preprocessor and heuristic rules of the existing QRS detectors demonstrate that detection of R-peaks is still very challenging task. In this paper, we propose a new preprocessor which is based on the Shannon energy envelope estimator and a simple peak-nding logic using the Hilbert-transform (HT) and moving average (MA) lter to combat the detection problem of unusually shaped QRS complexes and noises. The rest of this paper is organized as follows. In Section 2, the four-stage R-peak detection methodology is described in detail. We here introduce our new preprocessor and a novel automatic peak-nding scheme without using any amplitude threshold and prior knowledge of detected R-peaks. The experimental results to demonstrate the effectiveness of the proposed preprocessor and peak-nding scheme are presented in Sections 2.2 and 2.3. We experimentally evaluate our method using the wellknown MIT-BIH arrhythmia database, and a comparison between the proposed methodology and other approaches is presented in Section 3. Finally, in Section 4, we discuss and conclude our study. 2. The proposed R-peak detection methodology The block diagram of the proposed R-peak detection algorithm is shown in Fig. 1. It consists of four stages, namely, digital ltering, Shannon energy envelope extraction, peak-nding logic, and true R-peak locator. The rst stage of the proposed algorithm includes a bandpass lter, an amplitude normalization and rst-order forward difference operation to emphasize the QRS complex and to remove the noise in ECG signal. In the second stage, Shannon energy estimation and zero-phase ltering are applied to obtain a smooth Shannon energy (SE) envelope that plays the most critical role in the proposed algorithm. We can observe that major local maxima in the SE envelope represent approximate locations of the R-peaks in ECG signal. In the third stage, the proposed peak-nding technique is developed based on the Hilbert transformation, drift removal and zero-crossing point (ZCP) detection. The proposed technique identies accurate locations of the local maxima by detecting positive zero-crossing points in Hilbert-transformation of the SE envelope. We here show that the positive ZCP in Hilbert sequence of the envelope, s[n], indicates local peaks of the s[n] and the MA lter reduces the effect of ZCP drift in positive and negative directions. Finally, locations of the local maxima are used as guides to nd accurate locations of the R-peaks in ECG signals. The detailed discussions on each stage in Fig. 1 are presented in the following subsections. 2.1. Noise suppression and enhancement of QRS complex In the realistic environments, ECG signals may be corrupted by various kinds of noise, including power line interference, electrode contact noise, motion artifacts, muscle contraction and baseline

Stage 1: Linear Digital Filtering

ECG
x[n]

Bandpass Filtering (BPF)

f[n]

First-Order Forward Differencing (FOFD)

d[n]

Amplitude Normalization (AN) [n]

Stage 2: Smooth SE Envelope Extraction

Zero-Phase Filtering

Shannon Energy (SE) Computation

s[n] Stage 3: Peak-Finding Logic Hilbert Transformation Moving Average Filtering

z[n] Positive Zero Crossing Point (ZCP) Detection

Stage4: Identification of the real RPeak in the ECG within 25 samples Time Instants of R-peaks
Fig. 1. Block diagram of the proposed four-stage R-peak detection methodology.

drift and also have large P and T waves. Therefore, the digital ltering stage is constructed using bandpass lter (BPF) and rst-order differentiation to accentuate the QRS complex, and to reduce noise and the inuence of the P and T waves. The 4th order Chebyshev type I bandpass lter is designed for the bandwidth of [6 18] Hz. Here, the lter is applied in both the forward and reverse directions to avoid the phase distortion. Then, the ltered signal, f[n], is differentiated to provide information about the slope of the QRS complexes. The differentiation of the ltered ECG is implemented as d[n] = f [n + 1] f [n], (1)

which acts as a high-pass lter. The differentiation stage further reduces the interference of tall P- and T-waves. The output of the differentiator is a bipolar signal and thus a rectication is required to simplify the detection of negative R-peaks. After band-pass ltering and differentiation, we normalize the differentiated ECG (dECG) signal, d(n), by [n] = d d[n] maxN (|d[n]|) n=1 , (2)

where N denotes the number of samples in ECG segment. 2.2. Shannon energy and smooth envelope extraction After differentiation, the dECG signal is passed through a nonlinear transformation to obtain positive peaks regardless of polarity of QRS complexes. The main objective of transformation is to use single-sided threshold mechanism and to enhance the QRS complexes [5]. In literature, the squaring transformation is widely used but it considerably diminishes the magnitude of the candidate Rpeaks of low-amplitude QRS complexes and wide QRS complexes [9]. Here, we study the performance of different nonlinear transformation techniques using the low-amplitude QRS complexes, wider QRS complexes, and noisy ECG signals. The absolute value, energy

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx 3
1 0 1 0.5 0 0.5 1 1 0.5

Normalized Original ECG dECG Signal

2 1 0 1 0.5 0 1 1 0.5

0.5

Shannon Energy Envelope

1 Energy Envelope 0.5

1 0.5 0 1 0.5 0 1 0.5 0 0

1 Absolute Envelope Entropy Envelope 0.5 0 1 0.5

10

10

time (sec)

(a)

time (sec)

(b)

Fig. 2. Illustrates the performance of different envelopes extracted for a differentiated ECG (dECG) signal. The Shannon entropy approach emphasizes the effect of low noise components and the energy (squarer) approach decreases the magnitude of R-wave candidates. The Shannon energy approach magnies medium-amplitude values and thus exhibits the small difference between the successive peaks than the other envelopes.

value, Shannon entropy value, and Shannon energy value of the normalized dECG signal are computed using the following using Eqs. (3)(6)[20] [n]|, a(n) = |d 2 [n], e[n] = d [n]| log(|d [n]|), se(n) = |d 2 [n]). 2 [n] log(d s[n] = d (3) (4) (5) (6)

Then, the ltering is applied to obtain peaks corresponding to the QRS-complex portions and smooth out the spikes and noise bursts that is implemented using a rectangular impulse response, h(k) of length M. Here, the ltering operation is performed in both the forward and reverse directions, i.e., conv(s, h) s reverse the data sr conv(sr , h) s reverse the data y. This zero-phase ltering provides sharp peaks around QRS complex regions and smooth out spurious spikes. The smoothness depends on the lter length L. Generally, the L should be approximately the same as the duration of possible wider QRS complex. The length of the lter is found empirically. For sampling rate of 360 samples/s, the lter length of 55 samples is found in this study. Fig. 2 illustrates the performance of Shannon energy, Shannon entropy, energy and absolute value envelopes of the normalized dECG signals. Experimental results show that the Shannon entropy approach stresses the effect of low noise components that results in the envelope with artifacts and more unwanted peaks. The energy (squarer) approach decreases the amplitude of the small R-wave candidates much more than that of high-amplitude ones. This approach results in the envelope with large high/low peak amplitude ratio. The Shannon entropy and the energy approaches increase the difculty of the R-wave peak detection task. Therefore, we here introduce Shannon energy approach to obtain a positive signal. The Shannon energy envelogram (SEE) approach has the following advantages over conventional approaches: (i) it results in small deviations between the successive peaks; (ii) it reduces the

effects of low-value noise components; and (iii) it produces smooth sharp local maxima which clearly indicate the time instants of Rpeaks. Therefore, the Shannon energy envelope of a normalized [n], is computed by using an Eq. differentiated ECG (dECG) signal, d (6). The major advantages of SE approach show that it can lead to the much better R-peak detection performance in the presence of small and wider QRS complexes, and non-stationary noise. Experimental results, shown in Fig. 2, demonstrate that major local maxima in a smooth Shannon energy envelope, s[n], indicate approximate locations of the R-peaks in a ECG signal. Hence, the smooth Shannon energy envelope are processed further to detect R-peaks.

2.3. Hilbert transform-based peak-nding logic The detection of a R-wave peak is achieved by comparing the envelope of a ECG signal against a xed/adaptive amplitudedependent and RR interval-dependent thresholds. Most R-peak detection methods use a similar approach to determine the threshold. The detection thresholds are adapted periodically based upon amplitudes, durations and RR-intervals of past detected R-peaks. In such a case, performance relies highly on the accurate estimation of initial parameters in the learning phase. Almost all methods use additional decision rules for the reduction of false-positive detections and introduce secondary thresholds to detect missed R-peaks. These heuristic rules may improve detections for regular rhythms but some rules may be in conict with others. Furthermore, searchback mechanism with secondary threshold cannot be halted in case of irregular rhythms with varying QRS complexes and noise. Moreover, there are often lots of thresholds dened in heuristic rules. In this paper, we introduce a novel automatic peak-nding logic by exploiting the property of the Hilbert transform (HT) and using the moving average (MA) lter. The main objective of this paper is to demonstrate the use of the Hilbert-transform for reducing the complexity of the local maxima nding task. The Hilbert transform is widely used for analyzing the

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11 4

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx

1.0 0.75

candidate Rpeak

r(t)=1/(1+t ) candidate Rwave model H[r(t)]=t/(1+t2) Hilbert transform of the candidate Rwave

1 0.5 0 0

TP

TP

TP

TP

TP

TP

TP

TP

amplitude

0.5 0.25 0

0.5
TP TP

1.5
r FN
n

2.5
HT[r ]
n

3
Rpeak FN

3.5
TP

TP

1 0.5 0

TP

TP

oddsymmtery function

0.25 0.5 0.3 0.15 0

zerocrossing point

0.5 0

0.5
TP TP

1.5

2.5

3.5
TP

4
TP

1 0.5

0.15

0.3

after the removal of lowfrequency drift of the oddsymmtery function as shown in plot (b) TP TP TP TP TP: True Positive FN: False Negative

time (sec)
Fig. 3. Illustration of the maximum nding task. The maximum value of the enve (t ). lope function r(t) corresponds to the zero-crossing point of the r

0 0.5 0 0.5 1 1.5 2 2.5 3 3.5 4

time (sec)

instantaneous amplitude and frequency of the signal. The HT of a real signal x(t) is dened as (t ) = H[x(t )] = x 1 1 x(t ) = t

Fig. 4. Effectiveness of the HT-based peak-nding logic for different envelopes: (a) normal ECG with small relative peak-amplitude (RPA) variation and RR = 0.55 s. (b) Abnormal ECG with large RPA variation and RR = 0.55 s. (c) Performance of the logic after the removal of LF drift shown in (b).

x( ) d . t

(7)

The Hilbert transform dened in the time domain is a convolution (t ) is given between 1/ t and x(t). The Fourier transform (FT) of the x by (f ) = F X 1 x(t ) = F t 1 F[x(t )] = jsgn(f )X (f ). t (8)

Then, the Hilbert transform of the signal x(t) can be computed as (f )] (t ) = IFT [X x (f ) = where X jX (f ) jX (f ) f<0 f>0 (9)

where IFT denotes the inverse Fourier transform, and X(f) is the Fourier transform of the signal x(t). To demonstrate the maxima nding task using the Hilbert transform, the even function, r(t) = 1/(1 + t2 ), is considered as a R-wave envelope model. The (t ) = Hilbert transform of the even function, r(t), is given by r (t ) is shown t/(1 + t 2 ). The graphical representation of the r(t) and r in Fig. 3. It can be observed that the maximum value of the enve (t ) lope function r(t) corresponds to the zero crossing point of the r which is referred as odd-symmetry function (OSF). In practice, the strength of peaks in the ltered ECG is high around the R-wave portions. The amplitudes of the peaks in the smoothed envelogram are smaller for the low-amplitude and wide QRS complexes. Therefore, effectiveness of the peak-nding logic is studied using different envelopes. Fig. 4(a) clearly shows that the positive zero-crossing (or negative-to-positive transition) points of the odd-symmetry function correspond to locations of the peaks in the envelogram, and the performance of the peak-nding logic is excellent. Fig. 4(b) indicates the failure instance of the detection logic due to the low-frequency drift in the odd-symmetry function. It can be observed that the zero-crossing points of the third and sixth peaks are shifted in positive and negative directions, respectively. The degree of shift in a zero-crossing point and its direction is directly related to the relative peak amplitude and spacing of the two maxima and the sign of the peak difference. In practice, lowfrequency (LF) drift may arise because of the large peak-amplitude variation and the baseline shift of the peaks. In such cases, the peaknding logic may fail to detect small amplitude candidate R-peaks, and removal of low-frequency drift is most important. Therefore, moving average (MA) lter is used in this work. The low-frequency drift is effectively removed by subtracting the output of the MA lter from the original input. The result is shown in Fig. 4(c) for the

drifted odd-symmetry function in Fig. 4(b). It clearly shows that the method had perfect detections. The choice of the lter length is important for computing the low-frequency drift that mainly depends on the heart rate. For our sample rate of 360 samples/s, the MA lter length (L) is 900 samples (2.5 s). We noted that the performance of the peak-nding logic is better when the difference between two successive peak amplitudes is very small. But amplitudes of candidate R-peaks depend on temporal and spectral parameters of the QRS complex. However, the proposed Shannon energy-based preprocessor provides small deviations between the successive candidate R-peaks under time-varying QRS morphologies. The various signal transformations at different stages of the proposed method using the ECG segment taken from the record 205 of the MIT-BIH arrhythmia database are shown in Fig. 5. The output waveforms of the bandpass lter and rst-order forward derivative operation are shown in Fig. 5(b) and (c), respectively. The Shannon energy envelogram of the normalized dECG and the output of the Hilbert transformation of the envelogram are presented in Fig. 5(d) and (e), respectively. We can observe that the zero-crossing points are drifted in negative direction due to the large amplitude difference between the two successive peaks. Here, the low-frequency waveform drift is eliminated by subtracting the output of the moving average (MA) lter from the input waveform shown in Fig. 5(e). The output of LF drift removal stage is shown in Fig. 5(f). Finally, the zero-crossings accompanied by negative to positive transition are detected and used as guides to locate candidate R-peaks in the Shannon energy envelogram. The output of positive zero-crossing point (ZCP) detector is shown in Fig. 5(g), which shows that the locations of the impulses correspond to the peaks of candidate R-wave. The low-amplitude R-peaks of the record 205 can be successfully detected only when the output of LF drift eliminator [Fig. 5(f)] is processed. Experiments clearly demonstrate that the Shannon energy approach and Hilbert-transform based peak-nding logic play a key role in the detection of R-peak. The proposed decision stage does not require any information about the previously detected R peaks. 2.4. True R-peak detection Experiments show that the locations of candidate R-peaks differ slightly from the time instants of true R-peaks in an original ECG signal. Therefore, a simple true R-peak locator is incorporated

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx 5

0.5 0 0.5 0.1 0 0.1 1 0.5 0 0.5 6 4 2 2 0 2 4 2 0 2 1

x[n]

(a)

f[n]

(b)

SEE, s[n] norm. d[n]

(c)

(d)

HT of s[n]

(e)

z[n]

(f)

ZCPs

(g)
0

Final, Rpeaks

0.5 0 1 2 3 4 5 time (sec) 6 7 8 9 10

(h)

0.5

Fig. 5. Proposed R-peak detector: (a) ECG signal, x[n], taken from a record 205. (b) Output of bandpass lter. (c) Output of differentiator. (d) Output of SEE estimator. (e) Output of Hilbert transformer. (f) Output of LF drift eliminator. (g) Output of positive ZCP nder. (h) Output of true R-peak locator.

that nds the correct time instants of the R-peaks in a ECG signal by searching the largest amplitude within 25 samples of the identied location of the candidate R-peak in the previous step. Fig. 5(h) shows the original signal and the detected R-peaks using the proposed four-stage methodology.

algorithm, the sensitivity (Se), the positive predictivity (+P), and the detection error rate (DER) can be computed by using the following equations, respectively Se = +P = TP 100%, TP + FN TP 100%, TP + FP FP + FN 100%. TP (10) (11) (12)

3. Results and discussion The proposed R-peak detection method is evaluated using the MIT-BIH arrhythmia database. It contains 48 half-hour of twochannel ECG recordings sampled at 360 Hz with 11-bit resolution over a 10 mV range. The ECG records from this database include signals with acceptable quality, sharp and tall P and T waves, negative QRS complex, small QRS complex, wider QRS complex, muscle noise, baseline drift, sudden changes in QRS amplitudes, sudden changes in QRS morphology, multiform premature ventricular contractions, long pauses and irregular heart rhythms. In this study, we consider the entire ECG recordings since the proposed method does not require any learning phase. Episodes of ventricular utter in ECG record 207 are excluded from the performance analysis for better comparison with the other detection methods [1,9]. The proposed algorithm was implemented on a 2.4-GHz Intel core 2 Quad CPU using MATLAB version 7.1, and was tested on the ECG signals taken from the rst channel of the MIT-BIH arrhythmia database. In this study, the smoothing lter length (M) and the moving average lter length (L) of the detector are set as (M, L) = (55, 900) samples. The average processing time required for performing our method on each 30 min ECG data in the MIT-BIH database is approximately 2.24 s. From the detection results, we calculated three quantitative results: true-positive (TP) when a R-peak is correctly detected by the proposed algorithm, false-negative (FN) when a R-peak is missed, and false-positive (FP) when a noise spike is detected as R-peak. To evaluate the performance of the proposed detection

DER =

The overall performance of the method is measured in terms of the detection accuracy which is dened as Accuracy(Acc) = TP/(TP + FP + FN) 100%. (13)

The R-peak detection rates for the rst-channel (each) of 48 ECG recordings of the MIT-BIH arrhythmia database are summarized in Table 1. The proposed method produces 79 false-negative (FN) beats and 140 false-positive (FP) beats for a total detection failure of 219 beats. But the individual detection accuracies of the ECG records vary from 98.99% to 100% depending on the characteristics of normal and pathological ECG signals, and different noises. In the MIT-BIH arrhythmia database, ECG records 104, 105, 108, 200, 203, 210, and 228 contain high-grade noise and artifact. Records 108, 111, 112, 116, 201, 203, 205, 208, 210, 217, 219, 222, and 228 include severe baseline drifts and abrupt changes. Records 201, 202, 203, 219 and 222 exhibits various irregular rhythmic patterns. Records 201, 219 and 232 include long pauses up to 6 s in duration. Records 108 and 222 contain tall sharp P waves. Record 113 has tall sharp T waves. For these ECG recordings, the number of false positive detections is more in all the algorithms. Records 200, 203 and 233 contain multiform ventricular arrhythmia, negative QRS polarity and sudden changes in QRS morphology. Record 208 has wider premature ventricular contractions (PVCs). Record 223 exhibits sudden changes in QRS amplitudes. Records 116 and

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11 6

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx FN (beats) 0 2 0 0 0 8 0 0 4 0 0 0 0 0 1 16 0 0 0 0 0 0 0 0 0 0 11 0 0 8 0 6 9 0 2 0 1 0 0 0 0 1 6 0 2 0 2 0 79 FP (beats) 0 4 0 0 14 18 2 0 12 0 0 0 3 0 3 8 0 3 0 2 0 0 0 6 1 7 5 0 0 5 0 3 0 0 3 0 2 2 0 0 0 0 7 2 9 18 0 1 140 DER (%) 0 0.322 0 0 0.628 1.011 0.099 0 0.908 0 0 0 0.167 0 0.205 0.995 0 0.132 0 0.107 0 0 0 0.231 0.051 0.328 0.537 0 0 0.44 0 0.339 0.328 0 0.221 0 0.136 0.093 0 0 0 0.038 0.633 0.088 0.700 1.011 0.065 0.036 0.205 Se (%) 100 99.89 100 100 100 99.69 100 100 99.77 100 100 100 100 100 99.95 99.34 100 100 100 100 100 100 100 100 100 100 99.63 100 100 99.73 100 99.77 99.67 100 99.91 100 99.95 100 100 100 100 99.96 99.71 100 99.87 100 99.94 100 99.93 +P (%) 100 99.79 100 100 99.38 99.30 99.90 100 99.32 100 100 100 99.83 100 99.85 99.66 100 99.87 100 99.89 100 100 100 99.77 99.94 99.67 99.83 100 100 99.83 100 99.89 100 100 99.87 100 99.91 99.91 100 100 100 100 99.66 99.91 99.43 99.00 100 99.96 99.86 Accuracy (%) 100 99.68 100 100 99.38 98.99 99.90 100 99.10 100 100 100 99.83 100 99.80 99.01 100 99.87 100 99.89 100 100 100 99.77 99.94 99.67 99.46 100 100 99.56 100 99.66 99.67 100 99.78 100 99.86 99.91 100 100 100 99.96 99.37 99.91 99.30 99.00 99.94 99.96 99.79

Table 1 Performance evaluation of the proposed R-wave detection method using rst channel of the MIT-BIH arrythmia database with the detection parameters such as smoothing lter length (M) and MA lter length (L)), (M, L) = (55, 900) samples. ECG record 100 101 102 103 104 105 106 107 108 109 111 112 113 114 115 116 117 118 119 121 122 123 124 200 201 202 203 205 207 208 209 210 212 213 214 215 217 219 220 221 222 223 228 230 231 232 233 234 Total (beats) 2273 1865 2187 2084 2229 2572 2027 2137 1763 2532 2124 2539 1795 1879 1953 2412 1535 2278 1987 1863 2476 1518 1619 2601 1963 2136 2980 2656 1862 2955 3005 2650 2748 3251 2262 3363 2208 2154 2048 2427 2483 2605 2053 2256 1571 1780 3079 2753 Overall

Table 2 Comparison of the numbers of false-positives (FPs) and false-negatives (FNs) for specic records of the MIT-BIH arrythmia database. Rec. no. Number of false-positive (FP) detections Ref. [8] 104 105 106 108 113 116 121 200 203 208 209 210 221 222 223 228 232 233 Total 3 53 1 50 2 4 1 3 14 9 2 2 1 40 0 19 3 0 207 Ref. [17] 20 35 5 68 6 15 47 23 2 0 8 4 5 28 38 26 1 331 Ref. [14] 0 15 0 2 1 20 1 1 79 13 0 5 0 27 0 1 0 1 166 Ref. [16] 7 7 21 10 10 4 13 4 3 3 2 16 4 1 4 10 14 7 140 Our method 14 18 2 12 3 8 2 6 5 5 0 3 0 0 0 7 18 0 103 Number of false-negative (FN) detections Ref. [8] 7 22 2 47 1 25 0 2 61 19 2 41 1 37 2 6 0 3 278 Ref. [17] 1 14 0 9 0 0 3 95 19 0 23 2 0 1 22 0 7 196 Ref. [14] 0 21 2 62 682 0 0 2 19 3 1 2 4 12 0 14 17 0 841 Ref. [16] 1 19 20 2 11 27 0 9 7 10 9 5 8 0 22 2 2 8 162 Our method 0 8 0 4 0 16 0 0 11 8 0 6 0 0 1 6 0 2 62

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx
1

ECG, x[n]

0.5 0 0.5 0 5 10 (a) 15 20 25

Detected Peaks output of HT, z[n] smooth SEE, s[n]

0.8 0.6 0.4 0.2 0 1 0.5 0 5 10

(b)

15

20

25

0.5 0 1 0.5 0 5 10

(c)

15

20

25

0.5 0 5 10 15 20 25

time (sec)
(d)
Fig. 6. Performance of the proposed R-peak detector for the ECG signal with baseline drift and low-amplitude QRS complexes (Record 103). The method has a detection accuracy of 100%.

208 contain smaller QRS complexes than the others. For these ECG recordings, most of the algorithms had higher false-negative detections. However, the proposed algorithm achieves a signicant improvement in the detection of R-peak under time-varying QRS complex morphology and different kinds of noise and artifacts. The effectiveness of the proposed method in terms of the number of false negatives and false positives is shown in Table 2. The wave-

forms of the different stages of the proposed method using the ECG segments taken from rst-channel of the different recordings of the MIT/BIH database are shown Figs. 612. In each of these gures, waveform depicted in (a) is the original ECG signal, x[n]. The waveform depicted in (b) is the smooth Shannon energy envelogram [n]. The waveform (c) is the nal output of the (SEE) of the signal d Hilbert transformation and low-frequency drift removal process.

ECG, x[n]

0.5 0 0.5 0 0.8 0.6 0.4 0.2 0 5 10 15 20 25 5 10

output of HT, z[n] smooth SEE, s[n]

(a)

15

20

25

(b)
0.5 0

0.5 1 0 1 0.5 0 5 10

(c)

15

20

25

Detected Peaks

0.5 0 5 10 15 20 25

time (sec)
(d)
Fig. 7. Detection performance for the ECG with continuously varying QRS complex morphology, sudden changes in beat-to-beat RR-interval, and tall T waves (Record 106).

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11 8


1

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx
0.5 0 0 5 10 15 20 25

ECG, x[n]

output of HT, z[n] smooth SEE, s[n]

(a)

0.8 0.6 0.4 0.2 0 5 10

(b)

15

20

25

0.5 0

0.5 1 0 1 0.5 0 5 10

(c)

15

20

25

Detected Peaks

10

15

20

25

time (sec)
(d)
Fig. 8. Detection performance for the ECG signal with wide premature ventricular contractions (PVCs), and small QRS complexes (Record 208). The method successfully detects low-amplitude QRS complexes and wide PVCs.

The waveform depicted in (d) shows the time instants of detected R-peaks using the proposed method. The detection performance for the ECG signal with the high sharp P-waves, negative polarities, and more noises is summarized in Table 2. Most of the R-peak detection methods have poor detection performance for the noisy records 104, 105, and 108. The proposed method has a total detec-

tion failure of 56 beats (44 FP beats and 12 FN beats). The digital lter-based method [8] and the EMD-based method [17] produced a total detection failure of 182 beats (106 FP beats and 76 FN beats), and of 147 beats (123 FP and 24 FN beats), respectively. For the noisy records, the detection performance of the proposed method is better than the existing methods, except the 3M ltering method [16]

ECG, x[n]

0.5 0 0.5 0 5 10

(a)

15

20

25

output of HT, z[n] smooth SEE, s[n]

0.8 0.6 0.4 0.2 0 5 10

(b)

15

20

25

0.5 0

0.5 1 0 1 0.5 0 0.5 0 5 10 15 20 25 5 10

(c)

15

20

25

Detected Peaks

time (sec)
(d)
Fig. 9. Detection performance for the ECG with different QRS morphologies, small QRS complexes and artifacts (Record 223).

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx
1

ECG, x[n]

0.5 0 0.5 0 5 10

output of HT, z[n] smooth SEE, s[n]

(a)

15

20

25

0.8 0.6 0.4 0.2 0 5 10

(b)

15

20

25

0.5 0 0.5 1 0 1 0.5 0 0.5 0 5 10 15 20 25 5 10

(c)

15

20

25

Detected Peaks

time (sec)
(d)
Fig. 10. Detection performance for the ECG signal with paced beats and severe muscle noise (Record 104).

with a total detection failure of 46 beats (24 FP beats and 22 FN beats). The numerous long pauses up to 6 s in duration are mainly found in record 232 that yields more false positive detections in most of the methods. The detection performance of the method for the RR-interval greater than 2 s is shown in Fig. 11. The method

has a failed detection of 18 FP beats. Fig. 8 shows the detection performance for the record 208 which has wide PVCs, and small QRS complexes. For this record, most of the ltering based methods had highest FN. To detect the missed ECG beats, many methods use a set of decision rules with adaptive thresholds estimated based

ECG, x[n]

0.5 0 0.5 0 5 10

(a)

15

20

25

output of HT, z[n] smooth SEE, s[n]

0.8 0.6 0.4 0.2 0 5 10

(b)

15

20

25

0.5 0

0.5 1 0 1 0.5 0 5 10

(c) FP

15

20

25

Detected Peaks

FP

FP

0.5 0 5 10 15 20 25

time (sec)
(d)
Fig. 11. Detection performance for the ECG with noise and numerous long pauses up to 6 s in duration (Record 232). The method has the highest false positives for the ECG segment with long RR-intervals greater than 2 s.

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11 10


1

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx
very small QRS complexes

ECG, x[n]

drift

1 0

10

(a)

15

20

25

output of HT, z[n] smooth SEE, s[n]

0.8 0.6 0.4 0.2 0 1 0.5 0 5 10

(b)

15

20

25

0.5 0 1 0.5 0 5 10

(c)
the number of FNs is high

15

20

25

Detected Peaks

0.5 1 0 5 10

FPs

15

20

25

time (sec)
(d)
Fig. 12. Detection performance for the ECG with severe baseline drift and very low-amplitude QRS complexes (Record 116). The method has higher false-negative (FN) detections similar to the other methods. The overall detection accuracy is better than the methods in [8,17,14,16].

on the information (amplitude, RR-interval and duration) of the previous detected R-peaks. The method with secondary threshold produces several spurious peaks. To reduce the number of false detections, the refractory period of 200 ms and T-wave discriminator (200360 ms) are used in most of the methods. These additional decision rules may yield the poorest results in the case of ECG signal with irregular heart rhythm and continuously varying QRS complex morphology. Furthermore, these methods require the learning phase. The performance comparison in Table 2 shows that the proposed method produces 103 FP beats and 62 FN beats, which are

lower than that of the other methods reported in [8,17,14], and [16]. Various experiments demonstrate that the proposed method with simple HT-based peak-nding logic provides better detection performance without using any amplitude threshold in the decision stage to determine location of the R-peaks in ECG signal. In this work, we can observe that the proper decision rule provides much higher detection performance. Finally, the overall performance of proposed method is compared with six R-peak detectors reported in the literature. Based on the results of Table 3, an average accuracy of 99.80%, a sensitiv-

Table 3 R-peak detection performance comparison with other methods. Ref. Methodology Preprocessing stage [8] Bandpass lter, derivative squarer and moving window integrator Bandpass lter, derivative and squarer Quadratic spline wavelet Primary threshold, pt Threshold coefcient predicted peak value Based on root mean square (RMS) of segment Four thresholds based on RMS value of the WT at the corresponding scales Threshold based on the SNR computed between wavelet coefcients at 1st and 5th level Threshold based on the maximum of the transformed ECG waveform Four thresholds based on modulus maxima and average of past values Hilbert transform-based peak-nding logic (no amplitude thresholds) Secondary threshold 0.3 pt Blanking Refractory (200 ms) and T-wave removal 200360 ms for T-wave removal Refractory (200 ms) 248 340 99.69 99.77 99.46 FP (beats) FN (beats) Se (%) +P (%) Acc (%)

[9] [1]

0.5 pt Searchback thresholds None

447 153

467 220

99.57 99.80

99.59 99.86

99.17 99.66

[14]

Coiet wavelet, squaring and moving averaging

None

214

1333

99.78

99.80

98.59

[16]

[17]

Our method

Multiscale morphology ltering, differentiation and multi-frame accumulation Empirical mode decomposition and denoising Bandpass lter, derivative Shannon energy and Smoothing

None

None

204

213

99.81

99.80

99.62

0.5 pt

refractory (300 ms)

467

244

99.77

99.56

99.33

None

None

140

79

99.93

99.88

99.80

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

G Model BSPC-247; No. of Pages 11

ARTICLE IN PRESS
M.Sabarimalai Manikandan, K.P. Soman / Biomedical Signal Processing and Control xxx (2011) xxxxxx 11

ity of 99.93%, and a positive predictivity of 99.86% are obtained against the rst-channel of the ECG recordings of the MIT-BIH arrhythmia database. The proposed method achieved signicantly better performance than the other detection methods [717]. Based on the detection results, we concluded that the proper design of preprocessing and decision stages can improve the accuracy of detection of R peaks in ECG recordings with negative QRS polarities, low-amplitude R peaks, and wide PVCs, sudden changes in QRS amplitudes, sharp P and T waves, sudden changes in QRS morphologies, and irregular heart rhythm. The proposed method does not require additional decision rules with sets of thresholds based on the running estimates of the signal peaks and noise peaks, the average RR interval and rate limits, a set of tactics for blanking and T-wave discrimination, and training phase. 4. Conclusion In this paper, a novel, effective, and four-stage methodology has been developed for the automated detection of R-peaks in an ECG signal. The proposed preprocessor is based on a bandpass lter, rst-order forward derivative, amplitude normalization, Shannon energy estimation and zero-phase ltering with rectangular impulse response that provides a smooth envelogram of the ECG signal. The decision stage is based on Hilbert transform and moving average lter, which is a new and simple strategy to determine the location of the R-wave peak. Experiments showed that the SE-based preprocessor signicantly increases the detection accuracy for ECG recordings with low-amplitude, and wide QRS complexes. Also, the Hilbert transform-based peak-nding technique simplies the determination of locations of the Rpeaks. This approach does not require any amplitude threshold and prior knowledge of the past detected R-peaks. The standard MIT-BIH arrhythmia database (48 ECG records of 30 min each) is used to test the effectiveness of the proposed method whose detection performance was measured in terms of the number of false positives, true positives and false negatives for each record. The detection results obtained are presented, discussed and compared with the existing R-peak detection methods. The method achieves average detection accuracy of 99.80%, a sensitivity of 99.93%, and a positive predictivity of 99.86%. Despite all these various morphologies of the QRS complexes and different kinds of noise and artifacts contained in the ECG signals of the database, the proposed method achieves much higher detection rates than those produced by the other existing methods. The average time required for processing each sample is about 3.45 s.

Acknowledgments The authors would like to thank Professor Robert Allen, Editorin-Chief, and the anonymous referees for their valuable suggestions and comments. References
[1] J.P. Martnez, R. Almeida, S. Olmos, A.P. Rocha, P. Laguna, A wavelet-based ECG delineator: evaluation on standard databases, IEEE Trans. Biomed. Eng. 51 (4) (2004) 570581. [2] Y. Gahi, M. Lamrani, A. Zoglat, M. Guennoun, B. Kapralos, K. El-Khatib, Biometric Identication System Based on Electrocardiogram Data, New Technologies, Mobility and Security, Tangier, 2008, pp. 15. [3] M.S. Manikandan, S. Dandapat, Wavelet threshold based TDL and TDR algorithms for real-time ECG signal compression, Biomed. Signal Process. Control 03 (2008) 4466. [4] B.U. Kohler, C. Hennig, R. Orglmeister, The principles of software QRS detection, IEEE Eng. Med. Biol. Mag. 21 (2002) 4257. [5] O. Pahlm, L. Srnmo, Software QRS detection in ambulatory monitoringa review, Med. Biol. Eng. Comput. 22 (1984) 289297. [6] Y.-C. Yeha, W.-J. Wanga, QRS complexes detection for ECG signal: the difference operation method, Comput. Methods Prog. Biomed. 91 (2008) 245254. [7] J. Pan, W.J. Tompkins, A real time QRS detection algorithm, IEEE Trans. Biomed. Eng. 32 (3) (1985) 230236. [8] P.S. Hamilton, W.J. Tompkins, Quantitative investigation of QRS detection rules using the MIT/BIH arrhythmia database, IEEE Trans. Biomed. Eng. 33 (1986) 11571165. [9] N.M. Arzeno, Z.-D. Deng, C.-S. Poon, Analysis of rst-derivative based QRS detection algorithms, IEEE Trans. Biomed. Eng. 55 (2) (2008) 478484. [10] S. Benitez, P.A. Gaydecki, A. Zaidi, A.P. Fitzpatrick, The use of the Hilbert transform in ECG signal analysis, Comput. Biol. Med. 31 (2001) 399406. [11] C. Meyer, J.F. Gavela, M. Harris, Combining algorithms in automatic detection of QRS complexes in ECG signals, IEEE Trans. Inf. Technol. Biomed. 10 (3) (2006) 468475. [12] L. Romero, P.S. Addison, N. Grubb, R-wave detection using continuous wavelet modulus maxima, IEEE Proc. Comp. Cardiol. 30 (2003) 565568. [13] F. Abdelliche, A. Charef, R-peak detection using a complex fractional wavelet, in: International Conference on Electrical and Electronics Engineering, Bursa, 2009, pp. 267270. [14] M. Elgendi, M. Jonkman, F. De Boer, R wave detection using Coiets wavelets, in: IEEE 35th Annual Northeast Bioengineering Conference, Boston, MA, 2009, pp. 12. [15] Y.L. Chen, H.L. Duan, A QRS complex detection algorithm based on mathematical morphology and envelope, in: Proceedings of the 27th Annual International Conference of the IEEE EMBS, Shanghai, China, 2005, pp. 46544657. [16] F. Zhang, Y. Lian, QRS detection based on multi-scale mathematical morphology for wearable ECG devices in body area networks, IEEE Trans. Biomed. Circuits Syst. 3 (4) (2009) 220228. [17] X. Hongyan, H. Minsong, A new QRS detection algorithm based on empirical mode decomposition, in: Proceedings of the 2nd International Conference on Bioinformatics and Biomedical Engineering, 2008, pp. 693696. [18] K.V. Surez, J.C. Silva, Y. Berthoumieu, P. Gomis, M. Najim, ECG beat detection using a geometrical matching approach, IEEE Trans. Biomed. Eng. 54 (4) (2007) 485489. [19] B. Abibullaev, H.D. Seo, A New QRS detection method using wavelets and articial neural networks, J. Med. Syst. (2010), doi:10.1007/s10916-009-9405-3. [20] H. Liang, S. Lukkarinen, I. Hartimo, Heart sound segmentation algorithm based on heart sound envelogram, IEEE Proc. Comp. Cardiol. 24 (1997) 105108.

Please cite this article in press as: M.Sabarimalai Manikandan, K.P. Soman, A novel method for detecting R-peaks in electrocardiogram (ECG) signal, Biomed. Signal Process. Control (2011), doi:10.1016/j.bspc.2011.03.004

Вам также может понравиться