<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Comparison of ECG Beat Classification methods on a Mobile System</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Fernando Arena Varella</string-name>
          <email>favarella@inf.ufrgs.br</email>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Guilherme L. de Lima</string-name>
          <email>gllima@inf.ufrgs.br</email>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Cirano Iochpe</string-name>
          <email>ciochpe@inf.ufrgs.br</email>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Valter Roesler</string-name>
          <email>roesler@inf.ufgrs.br</email>
        </contrib>
      </contrib-group>
      <abstract>
        <p>The constant evolution of mobile technologies has lead to several systems with focus on the mobile electrocardiogram (ECG) telemonitoring of patients. They usually present a client-server architecture, where a web server centralizes the storage, management and processing of the patient's signals, and a mobile phone is responsible for acquiring and transmitting the data over the internet (WAP or 3G) to the server. However, there are countries, like Brazil, whose mobile network services do not present full coverage, even in large urban areas. This leads to a lack of security under certain situations like emergency calls or critic patient's monitoring when the patient is in an area without mobile network coverage. In these situations, the patient's vital signals must be analyzed as soon as possible, in order to allow fast preventive or reactive actions to be taken. An alternative way to deal with this problem is to support the analysis of vital signals in a mobile phone which can be either offline or communicating through a cell phone network. Though, since mobile phones, compared to PCs, have slower CPUs and less internal memory, it's important to select an ECG wave analysis method that is not costly with respect to computation time and memory usage. In this paper, we present comparison study made in order to select a reliable method for ECG beat classification running in a mobile phone. Three ECG beat classification methods were selected to be analyzed and implemented in a mobile phone. Tests were made in regions with limited cell phone network coverage in south Brazil. Test results were compared in order to choose a method whose implementation is efficient enough to run in a mobile phone and can achieve high accuracy on the classification of the ECGs, even if running in a phone with limited CPU as well as memory resources.</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>2 I9Access Tecnologia Ltda</p>
    </sec>
    <sec id="sec-2">
      <title>1. INTRODUCTION</title>
      <p>
        Heart and cardiocirculatory diseases are the most common
causes of death in the majority of western countries,
including Brazil where more than 30% of the deaths are
related to them [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]. An important characteristic of some
heart disease treatments is the need for constant monitoring
of the patient´s heart beat waves. This monitoring is
typically performed by either an electrocardiographer or a
holter. More important yet, in emergency situations, it is
crucial the fast access to the patient’s vital signals by the
physician, allowing him or her to take preventive or
reactive actions in order to save the patient’s life.
The evolution of telecommunications helped the
development of several systems with focus on the ECG
telemonitoring of patients, allowing them to stay at home,
instead of in a hospital in various situations. It helps to
reduce the high cost with patients internment and transport
and to shorten the long waits for hospital beds. Another
usage for the ECG telemonitoring is in critical situations
like strokes or heart stops, when the patient’s signals must
be analyzed as soon as possible. Most of the systems used
in such situations rely on a mobile phone to transmit the
data acquired by the electrocardiographer to a central
server, where it can be analyzed by the physicians almost in
real time. However, in countries like Brazil, where mobile
network coverage is not ideal, even in large urban areas
with dense people concentration, this strategy can be risky
to the patients since network communication is not reliable
in a number of regions. To deal with this problem, we
suggest to perform the ECG analysis through an application
running in the cell phone itself when it is impossible to
transmit the ECG waves to the remote server. This could
make the overall system fail-safe with respect to the lack of
good network coverage.
      </p>
      <p>Many computational methods have been proposed to
automate the process of ECG waves analysis, helping
physicians to diagnose anomalies on ECG exams. Although
these methods have achieved very good performances,
many of them rely on heavy computational algorithms and
can be very costly in terms of CPU and memory usage.
Considering this, we present, in this paper, a comparison of
some of the most reliable ECG beat classification methods.
Our main objective is to point out one or more methods that
can successfully classify ECG beats with high accuracy and
fast response even when implemented and running in a
mobile phone with limited CPU as well as memory
resources.</p>
      <p>The next sections are organized as follows. Section 2
introduces the ECG beat classification problem and the
most commonly used techniques to solve it. Section 3 is
reports on the implementation of some classification
methods in mobile devices. In section 4 we comment on the
results obtained in the evaluation of the implemented
methods. Finally, in Section 5 we present our conclusions
and point out to future work.</p>
    </sec>
    <sec id="sec-3">
      <title>2. ECG ANALYSIS BACKGROUND</title>
      <p>The automatic ECG classification methods apply
techniques from several computing areas, like
computational statistics, pattern recognition, support
vectors machines, etc. However, there is a basic set of
common steps between these methods: Beat Detection,
Feature Extraction and Beat Classification. The next
sections will introduce the ECG classification process and
review the most used techniques.</p>
    </sec>
    <sec id="sec-4">
      <title>2.1 ECG Analysis Process</title>
      <p>
        The Beat Detection step is usually made using common
annotated ECG database, easing the detection process and
unifying the data sets used amongst the majority of the
authors. When applied to real ECGs, this stage must be
made by a QRS detector algorithm, like the Pan Tompkins
method [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ].
      </p>
      <p>The Feature Extraction follows the beat detection, and it is
responsible for transforming the raw ECG signal, mapping
the original values to meaningful features. This is a very
important stage, and the most successful classification
methods rely on a good feature extraction stage to achieve
high performances.</p>
      <p>Finally, the Beat Classification stage will be performed
over the features extracted on the second stage. The authors
employ several classification and pattern recognition
techniques, allowing them to distinguish the type of each
beat that is being classified.</p>
      <p>Many authors have already employed these steps on the
past, building classifiers that can achieve high accuracy
rates on the classification task. We analyzed the results and
implementation of many methods, aiming the selection of
one of them for the usage on a mobile system. Thus, the
method must be efficient in time and in memory usage, at
the same time as it must achieve high accuracy to guarantee
that it can improve the capacity of the system to save
human lives.</p>
      <p>
        Mehmet Engin [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] developed a method that unifies a
Multilayer Perceptron (MLP) Artificial Neural Network
(ANN) with the fuzzy c-means (FCM) clustering algorithm,
forming a neuro-fuzzy network. His method uses the
discrete wavelet transform (DWT) to extract the feature set.
Similarly, Güler e Übeyli [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] proposed a method that uses a
set of small MLPs combined with a larger MLP to perform
the classification task and has its feature extraction step
based on the DWT. In this case, the data is first classified
by a set of MLPs, and then classified again by a final MLP.
Yu and Chen [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ] also used the DWT for the feature
extraction, but the classification step is made by a
Probability Neural Network. On their other work [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ], they
allied the DWT with the Higher Order Statistics (HOS) to
build the feature set, and used a MLP as the classifier. Yu
and Chou [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ] introduced a switchable scheme for the
classification task. They have 2 feature sets, both extracted
using the DWT allied to the Independent Component
Analysis (ICA). Depending on some characteristics of the
feature sets, they switch between the minimum Euclidean
Distance classifier, minimum Mahalanobis Distance
classifier or a Bayesian classifier. Finally, Minhas and Arif
[
        <xref ref-type="bibr" rid="ref8">8</xref>
        ] developed a method similar to the Chen and Yu’s
method, they rely on the HOS and the DWT to build the
feature set and perform the classification with the
KNearest Neighbor (KNN) Neural Network.
      </p>
      <p>However there is a basic set of common steps between
these methods: Beat Detection, Feature Extraction and
Classification.</p>
      <p>The Beat Detection is a signal processing consisting of
QRS complex detection. The QRS complex detection
methods already have excellent solutions and are not
addressed in this work. What is true highlight is that the
following step will process only segments of the QRS
complexes. The feature extraction stage consists in
transforming the signal into a suitable format to perform
the classification. Finally we perform classification of
extracted features in a certain class amongst the classes that
the method is able to identify, such as normal beat,
pacemaker beat, etc.</p>
    </sec>
    <sec id="sec-5">
      <title>2.2 Materials and Methods</title>
      <p>The three methods that this work analyzes uses discrete
wavelet transform together with mathematical procedures
to extract the features that will be classified.
2.2.1</p>
      <sec id="sec-5-1">
        <title>Discrete Wavelet Transform</title>
        <p>The wavelet functions are widely used in signal processing.
While the Fourier Transforms work only in frequency
domain, the wavelet analysis works also in the time
domain, a fact which facilitates the analysis of local
characteristics of signal, what is very important for
classification of ECG beats. Both the Fourier analysis and
wavelet analysis intend to approximate a signal by a linear
combination of sines and cosines (Fourier analysis) or
wavelets. The approximation of the signal in wavelet
analysis is performed by a process called wavelet transform
which has the continuous and discrete variants.</p>
        <p>
          The continuous wavelet transform (Continuous Wavelet
Transform - CWT) of a signal f is the inner product of the
signal by a wavelet, in this case called mother wavelet ψ, as
it appears in the following formula:
The mother wavelet ψ is given by the following formula:
The Discrete Wavelet Transform (DWT) of a signal
expressed as a vector of samples X = (x0, x1,, …, xT)t can
be expressed as:
However, in practice, this turns into the use of a pyramidal
algorithm, where a series of low pass and high-pass filters
are applied to the signal. The Pyramid algorithm that
computes the wavelet transform was proposed by Stephane
G. Mallat [
          <xref ref-type="bibr" rid="ref11">11</xref>
          ], and is shown graphically in Figure 1.
The algorithm uses a low-pass filters l and h high-pass to
calculate the approximation and detail coefficients,
respectively. On the first level, the approximation
coefficients are calculated by the convolution of the signal
with the low-pass filter, and the detail coefficients by the
convolution with the high-pass filter. After this process, the
resulting coefficients are downsampled, since the
convolution modifies the size of the resulting signals. For
every new level of coefficients, the approximation
coefficients from the previous level are taken as the
original signal, and the same process is applied.
        </p>
        <p>
          The filters depend on the type of wavelet-mother used on
the transform. The most commonly used is the Haar
wavelet, and its low-pass and high-pass filters are shown
below:
h = [0.70710678118654757, 0.70710678118654757]
l = [0.70710678118654757, 0.70710678118654757]
Some authors use the à trous wavelet transform [
          <xref ref-type="bibr" rid="ref12">12</xref>
          ],
whose main difference to the Mallat’s algorithm is the lack
of the downsampling after the application of the filters.
This difference helps to preserve the temporal resolution
and the time-invariant property of the signal on different
scales [
          <xref ref-type="bibr" rid="ref13">13</xref>
          ].
2.2.2
        </p>
      </sec>
      <sec id="sec-5-2">
        <title>Statistical Measurements</title>
        <p>Several statistical measurements are used by the ECG beat
classification methods, including the variance, standard
deviation, auto correlation and relative amplitudes.
The variance is defined like the average of the square of the
distance of each value from the mean, it shown the
difference of a value in relation to the mean value. Can be
expressed by the following formula:
From the variance we can calculate the standard deviation
which is defined as the square root of the variance, or even
the average distance of each value to the average, which
shows how the sample is distributed to the extent that
deviates from the mean.</p>
        <p>Another important measure is the auto correlation, which is
considered a measure of similarity between a sample and
its shifted version. The auto correlation can be expressed as
follows:
where x(n) is a sample of size N. This calculation tells how
much a certain value influences the neighborhood values,
i.e., how related are the values of a sample.</p>
        <p>We still have the relative amplitude, which is nothing more
than the ratio between the minimum and maximum value
for a given sample, which shows morphological
characteristics of the sample.
2.2.3</p>
      </sec>
      <sec id="sec-5-3">
        <title>Principal Components Analysis</title>
        <p>The Principal Component Analysis (PCA) reduces the
dimension of matrices building a smaller matrix only with
the principal information of the original one. For example,
considering the training and testing sets that will be
classified, it is possible to reduce a 10-dimensional feature
set to a 5-dimension, extracting the higher five principal
components. The process to find principal components is
the process to find eigenvectors of a covariance matrix R
formed by the feature set. The covariance matrix R is given
by:
The eigenvalues and eigenvectors are the obtained solving
the eigenvalue problem. For this problem, ten eigenvalues
and ten eigenvectors are obtained, the five eigenvectors
corresponding to the highest five eigenvalues will be used
to build a new feature set.</p>
        <p>The new feature set is obtained by the multiplication of
each sample by the five eigenvectors, yk:
2.2.4</p>
      </sec>
      <sec id="sec-5-4">
        <title>Higher-order Statistics - Cumulants</title>
        <p>
          A cumulant is a Higher Order Statistics measure that is
commonly used in physics. They can be seen as a set of
quantities that provide an alternative to the moments of the
signal, providing useful information about the probabilities
distribution of the signal [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ].
it depends on the presence of the training instances on the
classification stage. The network’s topology is composed of
four layers: Input Layer, Pattern Layer, Summation Layer
and Output Layer. That topology can be seen in Figure 2.
As it can be seen on Figure 2 and Figure 3, the employment
of the cumulants on the task of classifying ECG beats can
help to remove the variability between beats from the same
type, and to enhance the differences between beats of the
different types.
2.2.5
        </p>
      </sec>
      <sec id="sec-5-5">
        <title>Probabilistic Neural Network</title>
        <p>
          The Probabilistic Neural Network (PNN) is a neural
network used primarily as a classifier, but it can also be
seen as an alternative way to implement a statistical
algorithm called discriminant [
          <xref ref-type="bibr" rid="ref5">5</xref>
          ]. It is instance-based, since
The input layer distributes the samples to neurons of
pattern layer, and all entries are propagated to all the
neurons of layer pattern. Each sample of the training set
corresponds to a unit-layer pattern, thus, the hidden layer
will have the same number of neurons as the size of the
training set. Each hidden layer neuron has a
multidimensional Gaussian kernel, capable of estimating the
probability density function (PDF) of the input relatively to
that pattern. The summation layer has the same number of
neurons as the number of classes on the training set, and
each neuron in this layer responsible for accumulating the
PDFs of all neurons from the pattern layer that have the
same class.
        </p>
        <p>The classification phase of this neural network is simple,
yet costly. Each input from the training set will have its
PDF estimated for every neuron from the Pattern Layer.
The next layer, the Summation Layer will compute the
probability of the sample of being of each class
accumulating the values from the pattern layer and
grouping them by class. Finally, the Output Layer will
select the neuron with a higher value from the Summation
Layer to be the class of the sample.</p>
        <p>To estimate the probability density function of a given
sample is performed using the kernel density estimation
approach, also called Parzen window, which is basically a
technique of data interpolation. Given an instance x, the
Parzen window PDF estimates b fx(x) for each sample data
set. As the following expression:
where K is the kernel function, h is a smoothing parameter
and n is the number of samples in the data set.</p>
        <p>The kernel function most used is a Gaussian that can be
represented by:</p>
        <sec id="sec-5-5-1">
          <title>Thus, the expression (1) is denoted by: Finally, the PNN has fast training, the training set is used directly in the kernel, and converges to the optimal Bayesian decision surface.</title>
          <p>2.2.6</p>
        </sec>
      </sec>
      <sec id="sec-5-6">
        <title>Nearest Neighbor</title>
        <p>
          The K Nearest Neighbors algorithm calculates the
euclidean distance of a testing sample with all the training
samples. The input sample is classified with the same class
of the mode class of the k nearest neighbor according to the
euclidean distance [
          <xref ref-type="bibr" rid="ref8">8</xref>
          ]. The pseudo code is described in the
figure 3.
The Euclidean distance is defined as the distance between
two points, is based on the Pythagorean formula, can be
expressed like the square root of the square of the
difference between the points:
The sort procedure only order the distances vector, from the
smaller to the bigger distance. The mode procedure
chooses, between the k smaller distances, the mode class
point.
        </p>
      </sec>
      <sec id="sec-5-7">
        <title>2.2.7 Feed forward Back propagation Neural</title>
      </sec>
      <sec id="sec-5-8">
        <title>Network (MLP)</title>
        <p>The Multi-Layer Perceptron (MLP) is a neural network that
is usually used to solve classification problems. A common
type of MLP is the Feed forward Back propagation Neural
Network (FFBNN), whose name is given because the input
is forward propagated and the errors are back propagated to
correct the neurons weights.</p>
        <p>To explain the behavior of the FFBNN, consider the
topology described in figure.
The input layer propagates the input values to the hidden
layer, multiplying the value of each neuron with the
respective weight. The final value on the hidden layer
neurons are obtained applying the activation function on
the summation of all weighted values. The value of the
output layer neurons are calculated with the same
procedure, however, this value is compared with the
desired value from the training set, and the difference (the
error) is backpropagated to correct the neuron weights for
all layers.</p>
        <p>
          One efficient method to backpropagate the error,
minimizing the overall error of the network, was proposed
by Broyden-Fletcher-Goldfarb-Shanno (BFGS) as a generic
optimization algorithm. It is a quasi-Newton non-linear
method for optimization that transforms the error problem
on a minimization problem solving the hessian matrix
approximation problem [
          <xref ref-type="bibr" rid="ref15">15</xref>
          ]
        </p>
      </sec>
    </sec>
    <sec id="sec-6">
      <title>3. THE IMPLEMENTATION OF THE</title>
    </sec>
    <sec id="sec-7">
      <title>METHODS</title>
      <p>Although in the previous sections we presented only a
subset of the methods that have been proposed in the
literature, we have chosen these methods relying on their
accuracy and the sensitivity rates. Thus, the most efficient
methods are covered by this study.</p>
      <p># beats</p>
      <p>Accuracy
(%)</p>
      <p>Lesser
Sensitivity
Method</p>
      <sec id="sec-7-1">
        <title>Engin</title>
      </sec>
      <sec id="sec-7-2">
        <title>Güler e Übeyli</title>
      </sec>
      <sec id="sec-7-3">
        <title>Yu and Chen</title>
      </sec>
      <sec id="sec-7-4">
        <title>Yu and Chou</title>
      </sec>
      <sec id="sec-7-5">
        <title>Chen and Yu</title>
        <p>
          Minhas and Arif
4
4
6
6
6
6
98,0
96,94
99,65
99,51
99,70
99,49
95,3
95,56
99,04
98,24
98,88
98,92
measure can cause. Considering these facts, we decided to
choose three methods to compare and implement on a
mobile device, they are: Chen and Yu method [
          <xref ref-type="bibr" rid="ref6">6</xref>
          ], Minhas
and Arif method [
          <xref ref-type="bibr" rid="ref8">8</xref>
          ] and Yu and Chen method [
          <xref ref-type="bibr" rid="ref5">5</xref>
          ].
The selected methods were implemented in the Java
Language because it can be easily ported to the mobile
phones. With little adaptations, the methods were capable
of executing on PCs and on a mobile phone with the
Google’s Android Operational System, allowing us to
analyze the results on a real mobile phone. The mobile
phone used for the tests was a Motorola Milestone A853,
which has 256Mb RAM memory, an Arm Cortex A8 CPU,
which has a frequency of 600MHz and runs the version 2.2
of the Android system.
        </p>
        <p>The following subsections will review the selected
methods.</p>
      </sec>
    </sec>
    <sec id="sec-8">
      <title>3.1 Yu &amp; Chen method</title>
      <p>
        The method proposed by Yu and Chen [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ] is based on a
Probabilistic Neural Network (PNN) to classify up to six
different ECG beat types – including Normal beat (N), left
(L) and right (R) bundle branch block beats, premature
ventricular contraction (PVC), atrial premature beat (APB)
and paced beat (P). The features are extracted calculating
statistical measurements from the DWT coefficients of the
raw signal.
      </p>
      <sec id="sec-8-1">
        <title>3.1.1 Feature Extraction</title>
        <p>The DWT is applied on the raw ECG signals to perform the
extraction of the features. From the first and second level
wavelet (WT) detail coefficients (D1 and D2), and from the
second level approximation coefficients (A2) several
statistical measurements are calculated, including the
variance of the coefficients, the variance of the auto
correlation function of the coefficients, the ratio between
the maximum and minimum values and the interval
between the current beat and the last one.</p>
        <p>The authors proposed two feature sets, namely: FS1 and
FS2. FS1 includes the variance of the original signal, the
variance of D1, D2 and A2, the variance of the
autocorrelation of D1, D2 and A2 and the ration between
the maximum and minimum values of D1, D2 and D3, for a
total of 10 features. FS2 contains all the features of FS1
plus the instantaneous RR interval, since it is an important
information for arrhythmias.</p>
        <p>After the feature extraction, each feature is normalized,
using the hyperbolic tangent sigmoid function to map the
values of each feature to the range [-1, +1].</p>
      </sec>
      <sec id="sec-8-2">
        <title>3.1.2 Classification</title>
        <p>Yu and Chen use a PNN to perform the classification of the
beats. All the training instances must be loaded on the
network at the moment of the classification, thus, this
method is very costly in terms of memory usage. The fact
that the PNN is instance-based also implies that the method
is costly in terms of time, because it needs to process the
whole training set to classify each testing instance.
For each sample that needs to be calculated, the algorithm
needs to compute its PDF relative to each instance from the
training set. After this phase, which is made on the Pattern
Layer, the Summation layer will sum the results of all
neurons from the Pattern Layer, grouping by the class of
the neuron and making a weighted average of the value.
Finally, the Decision Layer will classify the instance with
the class that had the higher average on the Summation
Layer.</p>
      </sec>
    </sec>
    <sec id="sec-9">
      <title>3.2 Minhas &amp; Arif method</title>
      <p>
        The method developed by Minhas and Arif [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ] is similar to
the Yu and Chen method, they use the same statistical
measurements to build the feature set, but there are some
differences on the DWT and on the classifier. The authors
also apply a resampling on the records from 360Hz to
250Hz.
      </p>
      <sec id="sec-9-1">
        <title>3.2.1 Feature Extraction</title>
        <p>To perform the feature extraction the à trous DWT, using
the Quadratic Spline Wavelet as the mother wavelet, is
applied to the samples.</p>
        <p>The first and second level detail coefficients, and the
second level coefficients are selected as a base for the
feature set. From them, the same statistical features as the
FS2 from the Yu and Chen method are calculated.
The authors also employed the Principal Component
Analysis to generate a second feature set, with a reduced
dimensionality. However, this procedure also reduced the
accuracy of the method, thus, we will focus only on the
original feature set, which contains 11 features for each
sample.</p>
      </sec>
      <sec id="sec-9-2">
        <title>3.2.2 Classification</title>
        <p>Minhas and Arif employed a k-Nearest Neighbor algorithm
to classify the testing set. This classifier is extremely easy
to implement, since it’s depends only on a ordered list of
distances between the sample that is being classified and all
other samples from the training set. The Euclidean Distance
was the selected distance metric, and the k parameter was
set to 3.</p>
      </sec>
    </sec>
    <sec id="sec-10">
      <title>3.3 Chen &amp; Yu method</title>
      <p>The method proposed by Chen and Yu uses Higher Order
Statistics with the DWT to build a large feature set for each
ECG beat, what is classified by a Multilayer Perceptron.
The classifier covers the same beat types set as the Yu &amp;
Chen method.</p>
      <sec id="sec-10-1">
        <title>3.3.1 Feature Extraction</title>
        <p>To be successful on the difficult task of finding a reliable
feature set the authors employed Higher Order Statistics
allied to the DWT.</p>
        <p>Three higher order statistics features are selected to be help
to build the feature set, namely: second order cumulant,
third order cumulant and fourth order cumulant. The
authors use the à trous DWT, with the ‘sym6’ as the
mother wavelet, to calculate five levels of coefficients. The
2nd, 3rd and 4th order cumulants are extracted from the detail
wavelet coefficients of level 3, 4 and 5. As a result, nine
cumulants are calculated for each beat, and from them
several features are calculated, including: Cumulant
Variance and Normalized Summation for each cumulant,
the Number of Zero-Crossings on the cumulants of the
level 5 coefficients and the Symmetry of the 3rd and 4th
order cumulants. Additionally, three RR-interval related
features are defined, including: current RR interval,
previous RR interval and the ratio between the current and
the previous RR interval. In summary, the feature set is
formed by 30 features.</p>
      </sec>
      <sec id="sec-10-2">
        <title>3.3.2 Classification</title>
        <p>The classification stage of this method is performed by a
MLP, which is a neural network composed by, in this case,
three layers of neurons. The first layer only propagates the
inputs signal, while the hidden and output layers will
combine the inputs with a set of neuron weights and apply
an activation function to compute the output. The output is
compared to the desired output and an error value is
produced. This error is used to adjust the previous neurons
weights in a process called Backpropagation training.
The authors empirically defined that the hidden layer is
formed by sixty neurons, and the activation function of the
network is the hyperbolic tangent sigmoid. The
Backpropagation training uses the BFGS method to
minimize the error.</p>
      </sec>
    </sec>
    <sec id="sec-11">
      <title>4. RESULTS ANALYSIS</title>
      <p>
        To evaluate the behavior of the implemented methods we
used 23 records from the MIT/BIH arrhythmia database
[
        <xref ref-type="bibr" rid="ref9">9</xref>
        ], which consists of a large database of annotated
electrocardiograms containing several types of arrhythmias.
We used the same dataset to test all the implemented
methods in order to avoid overestimating of any of them.
      </p>
      <p>MIT/BIH Record
# Training
# Testing
103, 113, 115, 123,
220, 234
109, 111, 207, 214
118, 124, 212, 231
119
221
209
222
232
200, 233
107, 217
600
600
600
200
150
400
150
100
600
600
600
600
600
200
150
400
150
100
600
600
Type
N
LBBB
RBBB
PVC
APB
PB
Total
11600
11600</p>
      <p>Table 2 shows details of the records from the MIT/BIH
database that were used to form the training and testing
instance sets. Since neural networks need large training sets
to achieve a good performance, we used 11,600 instances
on each set.</p>
      <p>Our implementation of the Chen and Yu method is not fully
functional yet. We need to review the feature extraction
phase in order to achieve better results. In our experiments,
it achieved at most 89.52%, while the authors reported an
accuracy of 99.70% in their work.</p>
      <p>Statistical Measurement</p>
      <sec id="sec-11-1">
        <title>Accuracy %</title>
      </sec>
      <sec id="sec-11-2">
        <title>Specificity %</title>
      </sec>
      <sec id="sec-11-3">
        <title>Sensitivity % LBBB</title>
      </sec>
      <sec id="sec-11-4">
        <title>Sensitivity % RBBB</title>
      </sec>
      <sec id="sec-11-5">
        <title>Sensitivity % PVC</title>
      </sec>
      <sec id="sec-11-6">
        <title>Sensitivity % APB</title>
      </sec>
      <sec id="sec-11-7">
        <title>Sensitivity % PB</title>
        <p>Minhas
and Arif</p>
        <p>Yu
Chen</p>
        <p>and
99.0
Our experiments for the Minhas and Arif method and for
the Yu and Chen methods were successful on the PC and
on the mobile phone, achieving an accuracy of 99.0% and
98.67%, respectively.</p>
        <p>Due to the heavy computations needed by the classification
phase of the PNN and the KNN, the mobile phone needed
too much time to classify each beat. For the Yu and Chen
method, the PNN classifier needs to compute the PDF for
each of the 11,600 neurons from the Pattern Layer, perform
the summation and chose the desired class. The selected
mobile phone (Motorola Milestone A853) took an average
of 623ms to perform this task for each beat. The classifier
used by the Minhas and Arif method is the KNN, a
classifier that is similar to the PNN, however, instead of
finding the PDF for each neuron, it needs to compute the
distance of the beat to each other beat from the training set
and select the class of the closest class to be the target class
of the beat. The average time taken to classify each beat
with this method was 573ms.</p>
        <p>On an implementation that targets the monitoring of real
patients, the CPU will also be busy acquiring and decoding
the patient’s signal from the electrocardiographer, detecting
the QRS complexes to find the bounds of each beat and
extracting the features from the beat. As a result, all these
operations, together with the classification phase, can take
more than 800ms to be completed for each beat. A
traditional heart rate of 75bpm will generate 1 beat each
800ms, in other words, on the selected phone, these
methods would not be able to monitor patients with heart
rates higher than 75bpm, turning their use impracticable in
a real system.</p>
        <p>In contrast to them, the Chen and Yu method could be able
to classify each beat in a small time. Due the nature of the
MLP classifier, that just needs to propagate the inputs
through the network to find the target class, it achieved an
average of 27ms to classify each beat. However, as we have
already mentioned, our implementation of the method still
needs to be reviewed in order to achieve the accuracy
reported on the author’s paper.</p>
      </sec>
    </sec>
    <sec id="sec-12">
      <title>5. CONCLUSION AND FUTURE WORK</title>
      <p>In this paper, we presented a comparison study of ECG
beat classification methods destined to detect arrhythmias
running in a mobile phone. This study was motivated by
the need for a rapid response for the analysis of the exams
in some critical situations. Thus, our main objective was to
point one or more methods that can successfully classify
ECG beats on a mobile phone, with high accuracy fast
response.</p>
      <p>Relying on the specialized literature, we selected three
methods from the authors that reported the higher
accuracies together with high sensitivities, namely: Chen
and Yu method, Minhas and Arif method and Yu and Chen
method.</p>
      <p>As we reported in Section 4, our implementation of the
Chen and Yu method is not fully completed yet. By now, it
achieves at most an accuracy of 89.52%. On the other hand,
our implementation of both the Yu and Chen method, and
the Minhas and Arif method were successful for both the
PC and the mobile phone, achieving accuracies of 98.67%
and 99.00%. This performance could be observed in both
implementations, for the PC and for the mobile phone.
However, these two methods, when running in the mobile
phone were too slow to classify the beats. Both of them
need more than 500ms. This is indeed a problem, since
normal heart beat rates generate more than one beat per
second, and fast heart rates will generate more than one
beat per 500ms. Thus, both algorithms would not be able to
process all beats when running in a cell phone, at least in
our implementation.</p>
    </sec>
    <sec id="sec-13">
      <title>5.1 Future work</title>
      <p>To overcome the performance limitations found in our
study so far, we will focus on the implementation of the
Chen and Yu method in order to be able to test it in a
mobile phone. Since the MultiLayer Perceptron’s
classification phase is not instance-based, it is not costly in
terms of CPU and memory usage. If we fail to fix our
implementation of the Chen and Yu method, we’ll try to
develop a novel ECG beat classification method to run with
acceptable performance in a cell phone implementation.
The new method will have to combine a fast classification
algorithm with a feature set that provides better results.
http://www.who.int/entity/healthinfo/statistics/bodgbd
deathdalyestimates.xls.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1] WHO - World Health Organization.
          <year>2004</year>
          .
          <article-title>Table 3</article-title>
          .
          <source>Estimated deaths per 100</source>
          ,
          <article-title>000 population by cause, and Member State</article-title>
          . World Health Organization. Available on:
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <surname>Pan</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ;
          <string-name>
            <surname>Tompkins</surname>
            ,
            <given-names>W. J.</given-names>
          </string-name>
          <year>1985</year>
          .
          <string-name>
            <given-names>A</given-names>
            <surname>Real-Time QRS Detection</surname>
          </string-name>
          <article-title>Algorithm</article-title>
          .
          <source>IEEE Trans. Biomed</source>
          . Eng., BME-
          <volume>32</volume>
          (
          <issue>3</issue>
          ):
          <fpage>230</fpage>
          -
          <lpage>236</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <surname>Engin</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          <year>2004</year>
          .
          <article-title>ECG beat classification using neuro-fuzzy network</article-title>
          .
          <source>Pattern Recognition Letters</source>
          , v.
          <volume>25</volume>
          .
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <surname>Güler</surname>
            ,
            <given-names>I.</given-names>
          </string-name>
          ;
          <string-name>
            <surname>Übeyli</surname>
            ,
            <given-names>E. D.</given-names>
          </string-name>
          <year>2005</year>
          .
          <article-title>ECG beat classifier designed by combined neural network model</article-title>
          .
          <source>Pattern Recognition.</source>
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <surname>Yu</surname>
            ,
            <given-names>S.-N.</given-names>
          </string-name>
          ;
          <string-name>
            <surname>Chen</surname>
            ,
            <given-names>Y.-H.</given-names>
          </string-name>
          <year>2007</year>
          .
          <article-title>Electrocardiogram beat classification based on wavelet transformation and probabilistic neural network</article-title>
          .
          <source>Pattern Recognition Letters.</source>
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <surname>Chen</surname>
            ,
            <given-names>Y.-H.</given-names>
          </string-name>
          ;
          <string-name>
            <surname>Yu</surname>
            ,
            <given-names>S.-N.</given-names>
          </string-name>
          <year>2007</year>
          .
          <article-title>Subband Feature Based on Higher Order Statistics for ECG Beat Classification</article-title>
          .
          <source>Proceedings of the 29th Annual International Conference of the IEEE EMBS. Lyon</source>
          , France.
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <surname>Yu</surname>
            ,
            <given-names>S.-N.</given-names>
          </string-name>
          ;
          <string-name>
            <surname>Chou</surname>
          </string-name>
          , K.-T.
          <year>2007</year>
          .
          <article-title>A switchable scheme for ecg beat classification based on independent component analysis</article-title>
          .
          <source>Expert Systems with Applications.</source>
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [8]
          <string-name>
            <surname>Minhas</surname>
          </string-name>
          , F.-U.-A. A.;
          <string-name>
            <surname>Arif</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          <year>2008</year>
          .
          <article-title>Robust electrocardiogram (ECG) beat classification using discrete wavelet transform</article-title>
          .
          <source>Physiological Measurement.</source>
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [9]
          <string-name>
            <surname>Mark</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          , Moody, G.
          <year>1988</year>
          .
          <article-title>MIT-BIH Arrhythmia Database Directory</article-title>
          . (Cambridge, MA: MIT Press).
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          [10]
          <string-name>
            <surname>Figueredo</surname>
            ,
            <given-names>M. V. M.</given-names>
          </string-name>
          ;
          <string-name>
            <surname>Dias</surname>
            ,
            <given-names>J. S.</given-names>
          </string-name>
          <year>2004</year>
          .
          <article-title>Mobile Telemedicine System for Home Care and Patient Monitoring</article-title>
          .
          <source>Proceedings of the 26th Annual International Conference of the IEEE EMBS.</source>
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          [11]
          <string-name>
            <surname>Mallat</surname>
            ,
            <given-names>S. G.</given-names>
          </string-name>
          <year>1989</year>
          .
          <article-title>A theory for multiresolution signal decomposition: The wavelet representation</article-title>
          .
          <source>IEEE Transactions on Pattern Analysis and Machine Intelligence</source>
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          [12]
          <string-name>
            <surname>Cohen</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kovacevic</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          <year>1996</year>
          .
          <article-title>Wavelets: the mathematical background</article-title>
          .
          <source>Proc. IEEE</source>
          84
          <fpage>514</fpage>
          -
          <lpage>22</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          [13]
          <string-name>
            <given-names>J. P.</given-names>
            <surname>Martίnez</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Almeida</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Olmos</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A. P.</given-names>
            <surname>Rocha</surname>
          </string-name>
          and
          <string-name>
            <given-names>P.</given-names>
            <surname>Laguna</surname>
          </string-name>
          ,
          <year>2004</year>
          .
          <article-title>A wavelet-based ECG delineator: evaluation on standard databases</article-title>
          .
          <source>IEEE Trans. Biomed</source>
          . Eng.
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          [14]
          <string-name>
            <surname>Osowski</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ; Linh,
          <string-name>
            <surname>T. H.</surname>
          </string-name>
          <year>2001</year>
          .
          <article-title>ECG Beat Recognition Using Fuzzy Hybrid Neural Network</article-title>
          .
          <source>IEEE Transactions on Biomedical Engineering</source>
          , v.
          <volume>48</volume>
          .
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          [15]
          <string-name>
            <surname>Flecher</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          <year>1980</year>
          .
          <article-title>Practical methods of optimization</article-title>
          .
          <source>Section 3</source>
          .2, p38.
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>