Sie sind auf Seite 1von 12

c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31

journal homepage: www.intl.elsevierhealth.com/journals/cmpb

Development of QRS detection algorithm designed for


wearable cardiorespiratory system

Mourad Adnane, Zhongwei Jiang ∗ , Samjin Choi


Department of Mechanical Engineering, Yamaguchi University, 2-16-1, Tokiwadai, Ube, Yamaguchi, 755-8611, Japan

a r t i c l e i n f o a b s t r a c t

Article history: An in-home sleep monitoring system was developed previously in our laboratory for moni-
Received 21 January 2008 toring electrocardiography (ECG) and respiratory signals. However, the ECG signal acquired
Received in revised form with this system is prone to high-grade noise caused by motion artifact. Since the detection
18 July 2008 of the QRS complexes with high accuracy is very important in a computer-based analysis
Accepted 23 July 2008 of the ECG, a high accuracy QRS detection algorithm is developed and based on the com-
bination of heart rate indicators and morphological ECG features. The proposed algorithm
Keywords: is tested both on 16 h data acquired using the two sensors of our cardiorespiratory belt
QRS detection system, i.e., the polyvinylidene fluoride (PVDF) film and the conductive fabric sheets, and
HRV on all 48 records of the MIT/BIH Arrhythmia Database. Satisfying results are obtained for
RR interval both databases, the sensitivity Se and positive predictivity P+ were calculated for each case
Cardiorespiratory belt sensor and results show Se = [96.98%, 93.76%] and P+ = [97.81%, 99.48%] for conductive fabric and
PVDF film sensors, respectively, and Se = 99.77% and P+ = 99.64% in the case of the MIT/BIH
Arrhythmia Database. Further, heart rate variability (HRV) measures were calculated using
our system and a commercial system. A comparison between systems’ results is done to
show the usefulness of our developed algorithm used with our cardiorespiratory belt sensor.
© 2008 Elsevier Ireland Ltd. All rights reserved.

1. Introduction addition, the ECG signals acquired by our cardiorespiratory


system are prone to high-grade noise. Hence, in this paper
Monitoring physiological signals during sleep is an efficient a novel QRS detection algorithm designed for our laboratory-
way to diagnosis several cardiorespiratory diseases such as made belt sensor is proposed and described in detail. Many
arrhythmia and apnea [1,2]. However, conventional systems QRS detection algorithms, with different approaches, have
used in sleep monitoring, such as polysomnography, are been proposed by other researchers in the literature [5–11].
constrictive and are mainly designed for use in hospital envi- Chen et al. [5] proposed a moving averaging method with
ronment. In order to monitor the cardiorespiratory disorders wavelet denoising. Although this method is simple, however
in-home with less constraint, our laboratory has developed a it does not provide very good results. Actually, the moving
belt type sensor, which can measure both electrocardiography averaging is more of a smoothing technique than a noise fil-
(ECG) and respiratory signals [3]. Using this cardiorespiratory tering technique. Therefore, no significant effects are noticed
belt sensor, we aim to detect the sleep related disorders based on high-grade noisy signals. Pan and Tompkins [6] proposed
on the heart rate variability (HRV) measurement. However, a detection method with use of the morphological parame-
to calculate the HRV precisely, it is important to make an ters such as the amplitude, slope thresholds, and the limits of
accurate recognition of the QRS complex fiducial point [4]. In RR intervals, although better results could be obtained using


Corresponding author. Tel.: +81 836 85 9137; fax: +81 836 85 9137.
E-mail addresses: j501wc@yamaguchi-u.ac.jp (M. Adnane), jiang@yamaguchi-u.ac.jp (Z. Jiang), choi@yamaguchi-u.ac.jp (S. Choi).
0169-2607/$ – see front matter © 2008 Elsevier Ireland Ltd. All rights reserved.
doi:10.1016/j.cmpb.2008.07.010
c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31 21

heart rate indicators. Christov [7] proposed a combined thresh-


old method for one, two or more ECG leads. However, many
applications such as portable monitoring systems use only
one lead. Lee et al. [8] proposed the usage of phase portrait
for R-peak detection. This technique showed good results, but
it might not be suitable for time-varying morphological sig-
nals. Bragge et al. [9] proposed a combination of interpolation
method, non-linear wave estimation and linear fitting. This
method required heavy computational tasks and its efficiency
was not provided by the authors. However, their method may
Fig. 1 – Schematic of the belt sensor probe.
introduce good ideas about precise detection of QRS complex
fiducial point.
As mentioned above, the literature related to QRS detection
is very wide but mainly concerns two types such as methods
[5,10] focusing on filtering techniques for noise suppression,
and methods [7–9,11] focusing on the morphology of a signal
for making rule-based decision to use in the detection process.
Actually, a combination of the above-mentioned techniques
is needed. The ECG signals are contaminated with various
noises such as power line interference, muscle noise, baseline
wander, motion artifacts and T-wave. However, the filtering
techniques such as linear filters [6], or wavelets decomposi-
tion method [5] are not efficient for dealing with certain noises
such as motion artifacts. On the other hand, when the timing
and the morphological information in ECG are used together,
the QRS detection and ectopic beat identification tasks can be
performed without any manual correction on HRV measure-
Fig. 2 – Belt sensor device.
ment [12].
Therefore, in this study, we propose a method to detect
the QRS complex fiducial point based on a set of heart rate
For example, Fig. 3 shows the ECG signals obtained both
indicators combined with the morphological characteristics of
by the commercial three leads ECG device (Fig. 3a) and our
the ECG signals. The algorithm to decrease false peak detec-
belt sensor (Fig. 3b) during sleep. Fig. 3(c) shows the peaks
tion consists of a search back technique, adaptive thresholds
that should be detected (solid lines), the wrongly detected
and the limits of RR intervals. The detection algorithm was
peaks (dotted lines), and the missed peaks (cycles). These pos-
designed for the belt sensor and was tested with 16 h data
sible detection errors are induced by noisy signal due to body
acquired with our laboratory-made belt sensor. It was also
movement. Short periods of bad quality signals induce false
tested on all 48 records of the MIT/BIH Arrhythmia Database
or missed peaks as shown in Fig. 3. These misdetections affect
(MITADB) [13] excluding only the beats from ventricular flut-
the accuracy of HRV measurement that needs precise QRS
ter wave episodes, only present in the record 207. Furthermore,
detection. Therefore, a reliable and powerful QRS detection
the HRV measures obtained from our system and a commer-
algorithm designed for the belt sensor is developed to decrease
cial system were compared for validating the efficiency of our
the misdetections.
proposed method with the belt sensor.

3. Methods
2. System overview
The QRS detection algorithm process, as shown in Fig. 4, can
The belt sensor probe made in our laboratory is composed of a be divided into two stages such as the signal preprocessing
couple of conductive fabric sheets and a polyvinylidene fluo- stage and a decision stage. Preprocessing stage is composed
ride (PVDF) film. The PVDF film is used to detect both the ECG of a linear BPF, normalization, differentiation and squaring fol-
and the respiratory signals and the conductive fabric sheets lowed by, a decision stage where QRS complexes are detected
are used mainly to detect the ECG. These sensing materials and corrected.
are assembled together into a wearable belt as shown in Fig. 1.
In order to acquire the ECG and the respiratory signals from 3.1. Signal preprocessing
the belt sensor, hardware instrument (Fig. 2) was developed [3].
Three basic high quality and flexible hardware modules, i.e., In order to cancel the unwanted components caused by the
pre-amplifier module with 500 Hz low-pass filter (LPF), high power line, muscle noise, baseline wander and T-waves, a
quality band-pass filter (BPF) module and voltage controlled BPF-based software filtering algorithm with the cut-off fre-
voltage source (VCVS) band-rejection filter (BRF) module, were quency of 10–20 Hz is designed. The filter is composed of a
designed and assembled together for satisfying each sensor cascade of four digital filters, i.e., a 3rd-order Butterworth high
requirements. pass filter (HPF) with a cut-off frequency of 15 Hz, a 3rd-order
22 c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31

Fig. 3 – Examples of ECG signals detected by (a) the


commercial ECG device and (b) the proposed belt sensor. (c)
Show the true peaks expressed by solid lines and
misdetections expressed by dotted lines, and the missed
peaks marked by circles. Nu expresses normalized unit.

Fig. 5 – Plot of preprocessed ECG signals for the record 100


Butterworth BRF for canceling the 60 Hz power line interfer- of the MIT/BIH Arrhythmia Database. (a) Original signal, (b)
ence, a 4th-order Butterworth LPF with a cut-off frequency of normalized signal, (c) squared signal and (d) differentiated
25 Hz and finally a 2nd-order Butterworth LPF with a cut-off signal.
frequency of 10 Hz.
Suppose that the discrete signal obtained after filtering is
denoted as x[n]. The signal is first normalized (Eq. (1)) and then
Here c is a constant introduced to set the amplitude of x3 [n]
treated in two processes; so-called squaring process (Eq. (2))
in the same range as the other signals x1 [n] and x2 [n], which
and the differentiation process (Eq. (3)), given by
is set experimentally as c = 360. Notice that n represents sam-
ple’s discrete times, i.e. n*T, where T is the sampling period.
x[n]
x1 [n] = , n = 1, . . . , N, (1) Hereinafter, n is used instead of n*T.
MAX(x[n])
For example the preprocessed signals for the record 100 of
the MITADB are depicted in Fig. 5. Fig. 5(a) shows the origi-
2
x2 [n] = (x1 [n]) , n = 1, . . . , N, (2) nal signal, Fig. 5(b) shows the normalized signal x1 [n], Fig. 5(c)
shows the squared signal x2 [n], and Fig. 5(d) shows the differ-
x3 [n] = c(x1 [n + 1] − x1 [n]), n = 1, . . . , N − 1, (3) entiated signal x3 [n].

Fig. 4 – Block diagram of QRS detection algorithm.


c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31 23

Fig. 6 – Schematic of QRS detection algorithm steps.

3.2. QRS complex detection method The ECG signal slope (Fig. 7b) is compared to a negative
slope threshold THVn for every new sample until it is infe-
After signal preprocessing, the processed signal enters the rior to the threshold. Then, a crossed point of the slope on
decision stage. The steps in the decision stage are shown in THVn is defined as S̃n and the corresponding point in ECG
Fig. 6. signal is also defined as Pt2 .
Fig. 7 shows the QRS detection method based on the com- (3) QRS peak detection by THVa .
bination of the amplitude threshold (THVa ), the positive slope The third step corresponds to the calculation of the max-
threshold (THVp ), and the negative slope threshold (THVn ). imum amplitude between the two points Pt1 and Pt2 . The
Our purpose is to detect the QRS peak precisely. Conventional maximum amplitude in the range of Pt1 –Pt2 is compared
methods to detect QRS peak use either the amplitude or slope to an amplitude threshold THVa . If it is superior to the
information. To improve the precision of detection and to threshold then the corresponding point is defined as QRS
reduce the number of misdetections, we propose a new QRS peak.
complex detection method as follows:

(1) Positive slope onset point (Pt1 ) detection by THVp . Four important values Pa (m), Sp (m), Sn (m), and Za (m) with
The ECG signal slope (Fig. 7b) is compared to a positive regard to every detected peak, are recorded to use them in
slope threshold THVp for every new sample until it is supe- the different steps of the algorithm. These values correspond
rior to the threshold. Then, a crossed point of the slope on to the peak number m and they are the amplitude (Pa ), the
THVp is defined as S̃p and the corresponding point in ECG positive slope (Sp ), the negative slope (Sn ) and the time index
signal (Fig. 7a) is also defined as Pt1 . (Za ) of peak, respectively, as shown in Fig. 7. The fluctuations of
(2) Negative slope onset point (Pt2 ) detection by THVn . the ECG signal lead to low performance in the case of methods
based on constant thresholds. Therefore, the values Pa , Sp , and
Sn corresponding to successive peaks were used to update the
new threshold values and the value Za was used as the time
index of QRS peak by our method. Details of the decision stage
steps are explained in the following six subsections.

3.2.1. Automatic thresholds calculation


The usage of fixed thresholds results in missing many real
peaks. So, it is important to use adaptive thresholds corre-
sponding to the variation of the amplitude and slope of a
signal. In this study, the adaptive thresholds are calculated
and updated for each new detected peak by using successive
five detected peaks. That is, a set of the positive slope Sp , the
negative slope Sn , and the amplitude Pa is used to calculate
the adaptive thresholds as follows:

 
1 
m

Fig. 7 – QRS complex detection concept. (a) ECG signal THVp [m] = ˛ Sp [l] (4)
5
sequence and (b) differentiated ECG signal. l=m−4
24 c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31

Fig. 9 – Schematic of QRS complex detection based on the


Fig. 8 – Detection error for three conditions (˛) ˛ varying, ˇ
positive and negative slopes.
and  fixed; (ˇ) ˇ varying, ˛ and  fixed and ()  varying, ˛
and ˇ fixed.
started. The choice of t1 value is explained in Section 3.2.4.
  The average slope Sp and condition are given by
1 
m
THVn [m] = ˇ Sn [l] (5) 
n
5 1
l=m−4 Sp [p] = x3 [i] (7)
5
  i=n−4

1 
m
THVa [m] =  Pa [l] (6) subject to
5
l=m−4
Sp [p] ≥ THVp and x3 [i] > 0. (8)
where ˛, ˇ and  are the coefficients which have the values
between 0 and 1, and m = 5, . . ., M (M is the total number of where n = 5, . . ., N and p = 1, . . ., P (P < N).
peaks). How to determine the coefficient values is discussed
in following. 3.2.3. Negative slope detection
First, the coefficients ˛, ˇ and  were arbitrarily chosen. An After detecting positive slope, the negative average slope Sn is
optimal range with minimal detection error is then found by calculated by
means of empirical testing. The ranges with minimal detec-
tion error are 0.15–0.2 for the case of the coefficient ˛, 0.1–0.15
1 
n

for the case ˇ, and 0.2–0.25 for the case . With those ranges, we Sn [q] = x3 [j] (9)
5
temporarily choose the values as ˛ = 0.18, ˇ = 0.14, and  = 0.23, j=n−4
followed by, the detection of the optimal coefficient values
investigated such as one coefficient was varied from 0.1 to 0.3 subject to
and the others were fixed. As a function of the coefficient, the
percentage of false detection for three conditions such as (˛) Sn [q] ≤ THVn and x3 [j] < 0. (10)
varying ˛, fixed ˇ and , (ˇ) varying ˇ, fixed ˛ and , and ()
varying , fixed ˛ and ˇ, is depicted in Fig. 8. The records 104, where n = 5, . . ., N and q = 1, . . ., Q (Q < N). The negative average
105, 108, 200, 203, 207 and 208 of the MITADB were used to cal- slope is compared to a negative threshold slope THVn . In other
culate false detection. It can be observed from Fig. 8 that the words, if Eq. (10) is satisfied, then the negative slope detection
minimal detection errors can be obtained from the ranges of process continues to next step, otherwise it is performed again
0.1–0.2 for ˛, 0.1–0.15 for ˇ, and 0.2–0.3 for ␥. Based on these for new samples during time t2 , which has the same value
results, the coefficients values were set at ˛ = 0.18, ˇ = 0.14, and of t1 used for detecting the positive slope. Actually, after the
 = 0.25 and these values were used in the following steps. slope changes sign (from positive to negative), the algorithm
continues to test new samples for detecting negative slope
3.2.2. Positive slope detection (Eq. (10)). If the test is not verified for a period of time t2 , the
An average slope Sp (Eq. (7)) is calculated for each five con- previously detected positive slope is canceled and algorithm
secutive positive samples, set to ensure of slope onset. A goes back to positive slope detection step. The choice of t2
comparison is made to a threshold slope THVp . In other words, value is explained in Section 3.2.4.
if Eq. (8) is satisfied, then the positive slope detection pro- In addition, a time t3 is set to avoid detecting false peaks
cess continues to next step, otherwise it is performed again as shown in Fig. 9. Actually, after slope changes sign (from
for new samples during time t1 , as shown in Fig. 9. Actually, positive to negative), if new positive slope is detected, it states
after detecting positive slope, the algorithm searches for the the presence of fluctuations in the signal and a limit of time is
negative slope and if the slope does not change sign (remain necessary to avoid recognizing large waves or spurious peaks
positive) for a period of time t1 , then the detected positive as R-peak. The choice of t3 value is also explained in Section
slope is canceled and a new detection of positive slope is 3.2.4.
c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31 25

Fig. 10 – Schematic of false peaks checking algorithm steps.

3.2.4. Maximum amplitude calculation [15] used a limit of RR intervals, 300–1500 ms. Jezior et al. [16]
Maximum amplitude is calculated within an interval of time reported that a short RR interval lower than 250 ms is a strong
(t1 + t2 ), as shown in Fig. 9. Furthermore since QRS duration indicator of sudden death. Bjerregaard [17] stated that only 5%
is generally less than 120 ms in normal cases [14], both the of patients had a pause RR interval exceeding 1750 ms. Based
positive and negative slopes should happen within the time on the above-stated literature, a limit for RR interval should
interval (t1 + t2 ) so that t1 and t2 are better to be chosen as be within the range of 250–1750 ms. Therefore, we used a limit
half of this interval, i.e., t1 = t2 = 60 ms. On the other hand, t3 of 263–1675 ms, which corresponds to 36–228 bpm.
is better to be chosen as half of t1 value, i.e., t3 = 30 ms. As a The search back subsystem proposed for false peaks check
result, the maximum amplitude is calculated within the inter- is shown in Fig. 10. This algorithm is based on examining the
val between the positive and negative slopes, and is defined conditions by applying some limits to the successive RR inter-
as the candidate amplitude P̃a . And the corresponding time vals and the relationships between adjacent RR intervals as
index is also defined as the candidate time index Z̃a . follows:

3.2.5. Peaks detection RR[m] = Za [m + 1] − Za [m], m = 1, . . . , M − 1 (12)


The candidate amplitude P̃a is compared to the threshold
RR[m + 1]
amplitude THVa to ensure of peak detection. In other words, R[m] = , m = 1, . . . , M − 2 (13)
RR[m]
if Eq. (11) is satisfied, the detection is confirmed and the can-
didate amplitude and time index [P̃a , Z̃a ] are defined as [Pa , RR[m] = RR[m + 1] − RR[m], m = 1, . . . , M − 2 (14)
Z̃a ]. The corresponding positive and negative slopes are also
defined as [Sp , Sn ]. Also, a test is done in parallel, that is, where RR[m] is the RR intervals, R[m] is the ratio of adjacent
the squared signal (Eq. (2)), P̃2a is compared to a fixed thresh- RR intervals, and RR[m] is the difference between the adja-
old THVs like Eq. (11). This test is done to eliminate spurious cent RR intervals. The missed peaks generally happen when
peaks caused by T-waves. The value of the threshold was set the successive RR intervals (RR) have abnormally high value
empirically at THVs = 0.02. or the ratio of adjacent RR intervals (R) is superior to a sus-
pect limit that reflects physiologically unreasonable values.
P̃a [m] ≥ THVa [m − 1]. (11) Pan and Tompkins [6] proposed that a peak is missed when
the current RR interval is 1.66 times greater than an average
3.2.6. False peak check RR interval, de Chazal et al. [1] used 1.8 times as a factor. How-
Since some false peaks are still detected as true or some true ever, according to our tests, those factors may be too low and
peaks are missed. Then, a method based on RR intervals is lead to much spurious detections. Furthermore, the heart rate,
introduced to identify whether the detected peaks are false considering age categories and health states, has the range of
or true. First of all, it is important to define the physiologi- 50–200 bpm that is equivalent to 300–1200 ms. In the suspi-
cally reasonable value of RR interval and its limits [1]. Arner cious cases of missed peak, heart rate is logically superior to
26 c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31

Fig. 11 – Examples of ECG sequences: (a) normal sequence; (b) spurious peak in second position; (c) spurious peak in third
position; (d) spurious peak in fourth position.

1200 ms. Then, we used two conditions as: TP


Se = (18)
TP + FN
R[m] ≥ 3 (15)
TP
P+ = (19)
RR[m] ≥ 1375ms (16) TP + FP

In order to search the suspected cases of missed peak, con-


where TP is the number of true positive detections which
ditions of Eqs. (15) and (16) were used at the beginning of the
means correctly detected beats, FN is the number of false
search back system as shown in Fig. 10. Once the conditions
negative detections which means undetected beats, FP is
of Eqs. (15) and (16) are satisfied, the search back subsys-
the number of false positive detections which means falsely
tem is started and then the threshold values are decreased
detected beats, and Total beats, used in Tables 1, 2 and 4,
to search a new peak in the last RR interval. Next, whether
refers to TP + FN which means the total annotated beats. The
the suspected peak is a false or a missed peak is checked.
sensitivity Se is defined as the ability of the algorithm in the
When the ratio of adjacent RR intervals is bigger than 3.55,
detection of true beats, the positive predictivity P+ is defined as
R[m] ≥ 3.55, the suspected peak may be a false peak so that
the ability of the algorithm to discriminate between true and
the algorithm examines where false peak is, by means of the
false beats and the detection error De expresses the accuracy
last four peaks (three RR intervals). Herein, we can consider
of the algorithm. Meyer et al. [18] stated that a QRS complex
four ECG sequences as shown in Fig. 11. Fig. 11(a) shows the
could be considered correctly detected if it was detected less
normal ECG sequence and Fig. 11(b) to (d) show all possible
than 100 ms from an annotated time. Therefore, we considered
spurious ECG sequences. In particular, Fig. 11(b) is a case where
the QRS complex to be correctly detected if it was detected less
RR[m − 2] and RR[m − 1], caused by a false peak which is in
than 100 ms, by the window [t − 100 ms to t + 100 ms], from the
second position, are irregular RR intervals. Fig. 11(c) is a case
annotated time t.
where RR[m − 1] and RR[m], caused by a false peak which is in
the third position, are irregular RR intervals. Fig. 11(d) is a case
where RR[m], caused by a false peak which is in the fourth posi-
4.1. MIT/BIH arrhythmia database (MITADB)
tion, is irregular RR interval. These sequences are corrected by
eliminating the peak whose RR intervals fit less RR sequence
The first database is the MIT/BIH Arrhythmia Database. This
based on using the successive RR intervals, the ratio of adja-
database contains 48 records, which were digitized at 360 Hz.
cent RR intervals, and the differences between the adjacent
Two ECG leads for slightly over 30 min and annotations (the
RR intervals. Finally, when the RR interval is less than 263 ms,
marked events such as normal, abnormal, unclassified and
RR[m] < 263 ms, one of the two last detected peaks is false.
artifacts) are also provided for each record. Furthermore, the
annotations contain rhythm labels, signal quality labels, and
4. Results comments and the time of occurrence of each QRS complex. In
this study, we just used one of the two ECG leads and the anno-
In order to evaluate the performance of our algorithm, we tations were used to check the reliability of our results. All 48
tested it on two databases. Its reliability was assessed by the records of the MITADB were tested without exception, exclud-
detection error rate De , the sensitivity Se and the positive pre- ing only the beats from ventricular flutter wave episodes, only
dictivity P+ as follows: present in the record 207. The results are reported in Table 1.
Our algorithm succeeded in detecting correctly 99.41% of
FP + FN total peaks, further, the sensitivity and the positive predictiv-
De = (17)
TP + FN ity are Se = 99.77% and P+ = 99.64%.
c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31 27

Table 1 – The performance results of the R-peak detection algorithm for the MIT/BIH Arrhythmia Database
Record (no.) Total (beats) FP (beats) FN (beats) FP + FN (beats) De (%)

100 2273 0 0 0 0.00


101 1865 5 1 6 0.32
102 2187 0 0 0 0.00
103 2084 0 0 0 0.00
104 2229 63 12 75 3.36
105 2572 28 6 34 1.32
106 2027 2 17 19 0.94
107 2137 0 1 1 0.05
108 1763 55 28 83 4.71
109 2532 0 12 12 0.47
111 2124 3 1 4 0.19
112 2539 4 0 4 0.16
113 1795 0 1 1 0.06
114 1879 2 1 3 0.16
115 1953 0 0 0 0.00
116 2412 3 20 23 0.95
117 1535 0 0 0 0.00
118 2278 12 0 12 0.53
119 1987 0 0 0 0.00
121 1863 6 1 7 0.38
122 2476 0 0 0 0.00
123 1518 0 0 0 0.00
124 1619 1 0 1 0.06
200 2601 47 0 47 1.81
201 1963 0 3 3 0.15
202 2136 0 2 2 0.09
203 2980 27 53 80 2.68
205 2656 0 1 1 0.04
207 1860 13 7 20 1.08
208 2955 5 30 35 1.18
209 3005 1 0 1 0.03
210 2650 8 29 37 1.40
212 2748 1 0 1 0.04
213 3251 2 3 5 0.15
214 2262 3 3 6 0.27
215 3363 0 0 0 0.00
217 2208 1 2 3 0.14
219 2154 0 0 0 0.00
220 2048 0 0 0 0.00
221 2427 0 4 4 0.16
222 2483 3 0 3 0.13
223 2605 0 1 1 0.04
228 2053 76 6 82 3.99
230 2256 2 0 2 0.09
231 1571 0 0 0 0.00
232 1780 20 0 20 1.12
233 3079 0 7 7 0.23
234 2753 0 1 1 0.04

48 patients 109494 393 253 646 0.59

4.2. Belt sensor database sor detects the vibration due to each heartbeat. And then, the
PVDF signals represent heart beat occurrences rather than the
The second database is composed of two sets of signals ECG waveforms. In order to test the performance of our algo-
acquired using our cardiorespiratory belt sensor, i.e., the rithm, we analyzed five ECG records of the conductive fabrics
conductive fabric sensor and the PVDF sensor. Also, a con- and two heart beat records of the PVDF sensor, in which:
ventional three leads ECG was simultaneously acquired and
used as reference signal, i.e., to get the time of occurrence of (1) Conductive fabric sensor records
each QRS complex and use it to confirm correct detection in Record 1: Signal acquired from a male aged 30 years in a
the same manner the annotations made for the MITADB are supine position during sleep. The sampling frequency was
used. The difference between the two sets of data acquired by set to 200 Hz and the total length of the record is 23460 s.
the belt sensor is that conductive fabric sensor measures the Record 2: Signal acquired from a male aged 22 years in a
electrical potential in the surface of the body while PVDF sen- supine position during sleep. The sampling frequency was
28 c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31

Table 2 – The performance results of the R-peak detection algorithm for our cardiorespiratory belt sensor database
Record Total (beats) FP (beats) FN (beats) FP + FN (beats) De (%)

Conductive fabrics
Record 1 32926 300 958 1258 3.82
Record 2 21240 763 403 1166 5.49
Record 3 4427 67 65 132 2.98
Record 4 5401 307 483 790 14.63
Record 5 3149 18 118 136 4.32
Total 67143 1455 2027 3482 5.19

PVDF
Record 6 4427 31 186 217 4.90
Record 7 3149 6 287 293 9.30
Total 7576 37 473 510 6.73

set to 1000 Hz and the total length of the record is 18085 s.


Records 3–5: Signals acquired from a male aged 22 years
5. Discussions
(the same as record 2) in a seating position during wake-
We developed a QRS detection algorithm for a wearable car-
fulness. The sampling frequency was set to 100 Hz. Total
diorespiratory system made previously in our laboratory. The
length of each record are 4025 s, 3632 s and 2257 s, respec-
algorithm was implemented in Matlab 7.1. ECG signal and
tively.
hertbeats are acquired with that system using conductive
(2) PVDF sensor records
fabrics and PVDF film sensors, respectively. Therefore we
Record 6: Signal acquired from a male aged 22 years (the
needed to process those signals which are prone to high-grade
same as records 2–5) in a seating position during wakeful-
noises, by using a special methods of QRS peak segmenta-
ness. The sampling frequency was set to 100 Hz and the
tion including adaptive thresholds and RR interval limits and
total length of the record is 4025 s.
R peak detection correction using successive RR intervals. 16 h
Record 7: Signal acquired from a male aged 22 years (the
data acquired using our cardiorespiratory system were used,
same as records 2–6) in a seating position during wakeful-
together with a widely known database which is the MITADB,
ness. The sampling frequency was set to 100 Hz and the
for validating algorithm performances.
total length of the record is 2257 s.

5.1. MITADB

The total length of the data reaches 16 h. All data were The results obtained with the MITADB confirmed the abil-
acquired in our laboratory in a separate room with bed and air ity of our algorithm to discriminate between true peaks and
conditioning. The sampling frequency is an important param- spurious ones by means of morphological checking, i.e., ampli-
eter in our QRS detection algorithm. Therefore, all records tude comparison, slope comparison and successive RR interval
were resampled at 360 Hz, the same frequency used for dig- checking. Those properties are also used to detect previously
itizing the MITADB records. missed peaks, by means of thresholds decreasing. In addi-
Our algorithm succeeded in detecting correctly 94.81% and tion, false peaks are found and eliminated using RR interval
93.27% of the peaks for the conductive fabric and PVDF sen- limits and using comparison between the successive RR inter-
sors, respectively. The sensitivity and the positive predictivity vals. However, our algorithm did not perform so well with
for conductive fabric and PVDF are Se = [96.98%, 93.76%] and some records such as 104, 108, 200, 203 and 228. Actually,
P+ = [97.81%, 99.48%]. The performance results are summa- 56.81% of total number of errors induced by our algorithm
rized in Table 2. for those datasets is due to those records. The reason is that
In order to demonstrate the efficiency of our algorithm used those records include multi origins problems such as high-
with our self-made belt sensor, we performed the HRV mea- grade noise and multiform premature ventricular contractions
surement in two cases named as case-1 and case-2. Case-1 (PVCs) for all of them, in other words, the paced beats (record
corresponds to ECG signals acquired from our belt sensor and 104), abnormal high P wave and high frequency noises (record
analyzed by commercial software attached in BIOPAC system 108), irregular RR events and QRS morphology change (record
[19] and case-2 corresponds to ECG signals acquired from our 203), QRS morphology change (record 200), and very big change
belt sensor and analyzed by our algorithm. The commercial in R peak amplitudes for adjacent peaks (record 228). Even
three leads ECG signals were used as a reference. The calcu- though our algorithm did not perform so well with the men-
lated results of seven HRV measures and error rate for the two tioned records, the results are still good where the worst error
cases, during 1985 s selected from record 2, are summarized rate for record 108 is 4.71%, which is quite low.
in Table 3. The error rate, in Table 3, means the relative error On the other hand, a comparison results with several other
expressed in percentage between case-1 or case-2 and the ref- researches [5–8] using five selected records are summarized
erence. The HRV measures were performed according to the in Table 4. In particular, Christov [7] counted false peak and
recommendations of The European Society of Cardiology and missed peak occurring very close in time (less than 200 ms) as
The North American Society of Pacing and Electrophysiology one error, called shifted positive and shifted negative. Then,
[4]. his results were recalculated by adding the shifted errors.
c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31 29

Table 3 – The results of HRV measures and error rate analyzed by commercial software algorithm (case-1) and our
algorithm (case-2) for belt sensor database
Mean (ms) SDNN (ms) RMSSD (ms) PNN50 (%) SDSD (ms) LF/HF HRV index

Reference 966.31 86.74 62.28 36.34 43.02 3.25 19.19


Case-1 965.84 93.07 82.33 37.49 65.60 2.25 20.14
Case-2 966.44 86.69 63.34 36.16 44.07 3.28 19.37

Error rate of case-1 to reference (%) 0.05 7.30 32.19 3.16 52.49 30.77 4.95

Error rate of case-2 to reference (%) 0.01 0.06 1.70 0.50 2.44 0.92 0.94

Chen et al. [5] did not show the records 106, 108 and 228 so results (case-1). This is due in large part to the usage of the
that their overall error was calculated for 45 records. fixed thresholds and limited range of acceptable heart rates,
In Table 4, the five records selected from 48 records of the 40–200 bpm, for the case of the commercial system software.
MITADB have the unique characteristics. In other words, the On the contrary, for the case of our algorithm, the usage of the
record 105 is the case of severe noisy ECG signals, record 108 flexible thresholds and the search back technique to search
is the case of the first degree arterial ventricule blocks, fusion for missed peaks in the previous RR interval enables us to find
PVCs and severe time-varying morphological changes, record many missed peaks.
201 is the case of multiformed and late-cycle PVCs, record
203 is the case of the multiformed PVCs, QRS morphological 5.3. Databases results comparison
changes, muscle artifacts and baseline shift and record 222 is
the case of paroxysmal atrial fibrillation and high-frequency As reported in Tables 1 and 2, our proposed algorithm achieved
artifacts. It can be observed from Table 4 that our algorithm good results with the two tested databases. In particular,
succeeds to have the best results for the records 105 and 201, the results concerning the MITADB were better than those
further, the second best results for the records 108, 203 and of the belt sensor. This is logical because of the presence of
222 whereas Lee et al. [8] show the best results for the records high-grade noises in the signals acquired by the belt sensor.
108 and 203. Furthermore, the overall error of our algorithm is Actually, the PVDF sensor by its nature detects any body move-
the second lowest among the five compared algorithms since ments which make very difficult the detection of heart beats.
Lee et al. showed the lowest error rate. The PVDF signals used in our tests were acquired in a seat-
ing position which induced less motion artifacts than other
5.2. Belt sensor database positions such as supine or sleep. On the other hand, the ECG
signals acquired by the conductive fabrics showed the same
In Table 3, although the signal (record 2) used for measur- patterns as conventional three leads ECG signals, although the
ing the HRV has somewhat a little lack on the information conductive fabrics were not attached to the body as it was in
in ST segment of ECG with comparison to the commercial the case of three leads. This is why motion artifacts act more
three leads ECG, the QRS complexes could be extracted quite on the conductive fabrics than the three leads ECG. However,
well by applying our algorithm. The overall results were very the results of the records 1 and 2 (conductive fabrics) showed
satisfactory and proved that our self-made belt sensor (case- very good results although they were recorded during sleep
2) analyzed by our algorithm can perform very good results where body motion and friction are more higher.
for unconstrained long time monitoring data and noisy ECG On the other hand, we have checked several selected
signals, comparing with the commercial system software’s records to make clear what the difference between our method

Fig. 12 – Example of ECG signals and the detected QRS complexes (marked by circles) for (a) record 201, (b) record 108, and
(c) record 105 of MIT/BIH Arrhythmia Database, and (d) belt sensor.
30 c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31

and Lee et al.’s method is and how comparable can be the

1.75
1.13
1.38
2.42
3.87

0.42
(%)
De
results obtained from the two databases. And then, four exam-
ples are demonstrated. Fig. 12 demonstrates the examples of

Lee et al. [8]


the ECG signals and QRS complexes detected by our algorithm.

(beats)
FN
The record 201 (Fig. 12a) shows the characteristics of time-

4
11
27
47
91

355
Table 4 – Comparison of our algorithm with some researcher’s algorithm for the MIT/BIH Arrhythmia Database (the slash “/” expresses not reported results)
varying morphological changes such as PVCs and ventricular
trigeminy. The record 108 (Fig. 12b) is characterized by PVCs

(beats)
FP and high frequency noises. The record 105 (Fig. 12c) presents

41
9
0
25
5

137
high-grade noises and artifacts. Our belt sensor ECG with sim-
ilar high-grade noises and artifacts is shown in Fig. 12(d).
Results showed that the method of Lee et al. is more pre-
2.29

0.51
3.15
0.04

0.62
(%)
De

7.2

cise in the presence of high frequency noises for the case of


record 108 and multi patterns problems signals such as the
Christov [7]

record 203. Our method is better in the case of time-varying


(beats)
FN

morphological change signals such as the records 201 and


10
4
60
65
0

288

222. As shown by the results presented by Lee et al., their


method is not suitable for time-varying morphological signals.
(beats)

On the other hand we noticed when screening the segments


FP

49
127
1
29
1

386

of the record 105 (Fig. 12c) and the belt sensor’s ECG (Fig. 12d)
that they present similar features and are completely differ-
ent from those of the records 108, 201, 203 and 222. Therefore,
according to the results reported in Table 4 and Fig. 12, it can
Pan and Tompkins [6]

3.46
12.54
0.51
2.78
7.33

0.72

be concluded that our method using the morphology as detec-


(%)
De

tion principle and RR timing for the checking and correction of


the detection is better for time-varying morphological signals
(beats)

and signals with high motion artifacts.


FN

22
22
10
30
81

277

6. Conclusion
(beats)
FP

67
199
0
53
101

507

A QRS detection algorithm combining heart rate timing


information and morphological ECG features is developed.
The algorithm’s performance is evaluated both for 16 h data
3.23

1.07
3.52
0.04

0.95
(%)
De

acquired using our self-made belt sensor and for all 48 records
/

of the MIT/BIH Arrhythmia Database. The capacity of our


Chen et al. [5]

cardiorespiratory belt sensor to measure the HRV using the


(beats)
FN

5
/
21
18
0

429

proposed algorithm is also demonstrated. Furthermore, the


results show that the proposed methods based on ECG mor-
phology are capable of giving good results in terms of QRS
(beats)

detection and are suitable to use with noisy and multiform


FP

78
/
0
87
1

459

ECG signals.

Conflict of interest statement


1.32
4.71
0.15
2.68
0.13

0.59
(%)
De

None declared.
Our work

(beats)
FN

6
28
3
53
0

253

Acknowledgements
(beats)

This research was partially supported by the Japanese Ministry


FP

28
55
0
27
3

393

of Education, Culture, Sports, Science and Technology, Grant-


in-Aid for Scientific Research (B), 2005, 13555064.
(beats)

2572
1763
1963
2980
2483

109494
Total

references
Record (no.)

[1] P. de Chazal, C. Heneghan, E. Sheridan, R. Reilly, P. Nolan, M.


48 records

O’Malley, Automated processing of the single-lead


electrocardiogram for the detection of obstructive sleep
105
108
201
203
222

apnoea, IEEE Transactions on Biomedical Engineering 50 (6)


(2003).
c o m p u t e r m e t h o d s a n d p r o g r a m s i n b i o m e d i c i n e 9 3 ( 2 0 0 9 ) 20–31 31

[2] M.G. Tsipouras, D.I. Fotiadis, Automatic arrhythmia [11] M.H. Song, K.J. Lee, Real-time classification of heartbeats
detection based on time and time-frequency analysis of using least square acceleration filter for ambulatory
heart rate variability, Computer Methods and Programs in monitoring, Computers in Cardiology 33 (2006)
Biomedicine 74 (2004) 95–108. 565–567.
[3] S. Choi, Z. Jiang, A novel wearable sensor device with [12] B. Acar, I. Savelieva, H. Hemingway, M. Malik, Automatic
conductive fabric and PVDF film for monitoring ectopic beat elimination in short-term heart rate variability
cardiorespiratory signals, Sensors and Actuators A 128 measurement, Computer Methods and Programs in
(2006) 317–326. Biomedicine 63 (2000) 123–131.
[4] Task Force of The European Society of Cardiology and The [13] MIT/BIH Arrhythmia Database, http://www.physionet.
North American Society of Pacing and Electrophysiology, org/physiobank/database/mitdb/, accessed: 13 July 2008.
Heart rate variability standards of measurement, [14] ACC/AHA Heart Failure Clinical Data Standards ACC/AHA
physiological interpretation, and clinical use, European Key data elements and definitions for measuring the clinical
Heart Journal 17 (1996) 354–381. management and outcomes of patients with chronic heart
[5] S.-W. Chen, H.-C. Chen, H.-L. Chan, A real-time QRS failure, Journal of the American College of Cardiology 6 (6)
detection method based on moving-averaging incorporating (2005).
with wavelet denoising, Computer Methods and Programs in [15] A.E. Arner, The reproducibility of short verses long-duration
Biomedicine 82 (2006) 187–195. Heart rate variability methods and relations to aerobic
[6] J. Pan, W.J. Tompkins, A real time QRS detection algorithm, fitness in normal adults Thesis submitted to the faculty of
IEEE Transactions on Biomedical Engineering BME-32 (3) Virginia Tech in partial fulfillment of the requirements for
(1985). the degree of master of science in clinical exercise
[7] I.I. Christov, Real time electrocardiogram QRS detection physiology, Blacksburg, Virginia, 2002, p. 49.
using combined adaptive threshold, Biomedical Engineering [16] M.R. Jezior, S.M. Kent, J.E. Atwood, Exercise testing in
Online 3 (2004) 28. Wolff–Parkinson–White syndrome: Case Report with ECG
[8] J.-W. Lee, K.-S. Kim, B. Lee, B. Lee, M.-H. Lee, A real time QRS and Literature Review, vol. 127, 2005, pp. 1454–1457 (Chest).
detection using delay-coordinate mapping for the [17] P. Bjerregaard, Mean 24 h heart rate, minimal heart rate and
microcontroller implementation, Annals of Biomedical pauses in healthy subjects 40–79 years of age, European
Engineering 30 (2002) 1140–1151. Heart Journal 4 (1983) 44–51.
[9] T. Bragge, M.P. Tarvainen, P.O. Ranta-aho, P.A. Karjalainen, [18] C. Meyer, J.F. Gavela, M. Harris, Combining algorithms in
High-Resolution QRS fiducial point corrections in Sparsely automatic detection QRS complexes in ECG signals, IEEE
Sampled ECG Recordings, Physiol. Meas. 26 (2005) 743–751. Transactions on Information Technology in Biomedicine 10
[10] O. Sayadi, M. B. Shamsollahi, Multiadaptive Bionic Wavelet (3) (2006).
Transform: Application to ECG Denoising and Baseline [19] BIOPAC Systems, Inc. http://www.biopac.com/, accessed: 1
Wandering Reduction, EURASIP Journal on Advances in May, 2008.
Signal Processing 2007 (2007) 11, Article ID 41274.

Das könnte Ihnen auch gefallen