You are on page 1of 5

2014 International Conference on Circuit, Power and Computing Technologies [ICCPCT]

Prediction of Sudden Cardiac Death Using


Support Vector Machine
C. Jenefar Sheela

L. Vanitha

PG Scholar
Loyola Institute of Technology
Palanchur, Chennai

Assistant Professor,
Loyola Institute of Technology,
Palanchur, Chennai
The organization of this paper is as follows:
Literature survey is discussed in Section II, Section
III describes the methodology for the proposed
cardiac arrest prediction system. The different
modules of the work are executed in Matlab and the
results are summarized and discussed in Section IV.
Section V gives the conclusion and future work.

Abstract - Sudden death from cardiac arrest is a major


health problem and is responsible for almost half of all
heart disease deaths. In Sudden Cardiac Death (SCD),
the cardiac arrest occurs for a very short time which is
preceded and followed by normal ECG. Thus, it is
difficult to detect such conditions, using only ECG. This
work predicts sudden cardiac arrest before 30 minutes of
its occurrence on the basis of time domain and frequency
domain features of Heart rate variability (HRV) obtained
from ECG and using SVM classifier to classify SCD
patient from Normal patient. The database of cardiac
patients obtained from physionet is used to check the
validity of the proposed work. Performance of SVM is
better giving the classification efficiency of 88%.

II

A number of detection and analysis


techniques have been evolved to classify Cardiac
arrests from normal sinus rhythm (SR). With classical
linear techniques Elias Ebrahimzahed [1] used timefrequency methods to predict cardiac arrest before 2
minutes with an accuracy of 73%. Using wavelet
transformation, Yongquin Li [2] described an
evaluation algorithm which is used to predict arrest
with an accuracy of 78%. A modified form of the
scoring system was also presented by Mithun
Manjnath Nayak with significant accuracy using
logistic regression but it is designed only for inhospital patients [3]. Using Spectral domain analysis
the ECG of a normal healthy person is distinguished
from ECG of a cardiac death patient in terms of energy
and frequency [12]. Mark Van Gils [6] analyzed the
brain status, during cardiac arrest in EEG, using
wavelength band entropy. American Heart Association
[8], proved that there a significant change in frequency
domain parameters of heart rate variability during
cardiac arrests.

Keywords-Cardiac arrest, ECG, Sudden Cardiac Death


(SCD), Heart rate Variability (HRV), Support vector
machine (SVM)

INTRODUCTION

A heart attack or myocardial infarction


occurs when a coronary artery, one of the arteries that
supplies blood to the heart muscle, becomes suddenly
blocked. This sudden blockage robs a portion of the
heart muscle of its vital blood supply, and the muscle
dies. Thus, a heart attack is the death of a part of the
heart muscle. A cardiac arrest, in contrast, is caused
by a sudden heart arrhythmia called ventricular
fibrillation. In ventricular fibrillation, the electrical
signals within the heart, which controls the timing
and the organization of the heartbeat, suddenly
become completely chaotic, hence the heart suddenly
stops beating and leads to death.
The treatment for a cardiac arrest is to begin
immediate cardiopulmonary resuscitation (CPR) to
support the victims circulation, and, as soon as
possible, to deliver a large electrical shock to the
heart with a device called defibrillator. The large
shock allows the hearts electrical signal to
reorganize itself, and the heart starts beating again
[26]. Unfortunately, because death occurs within a
few minutes of cardiac arrest unless expert help is
available, the majority of individuals who suffer
cardiac arrest are not successfully resuscitated. Hence
it is very essential to predict these cardiac arrests
before it happens.

978-1-4799-2397-7/14/$31.00 2014 IEEE

LITERATURE SURVEY

III

METHODOLOGY

The proposed work consists of four


modules. Figure 1 shows the basic block diagram of
the proposed cardiac arrest prediction system
representing the four modules.
1.
2.
3.
4.

377

Data Acquisition
HRV Determination
Feature vector extraction
Classification

2014 International Conference on Circuit, Power and Computing Technologies [ICCPCT]

B. Feature Extraction
The time intervals between consecutive
heart beats are customarily measured in the
electrocardiogram from the beginning of a QRS
complex to the beginning of the next QRS complex,
so these intervals might be called QQ intervals, but
they are conventionally named RR intervals. The
intervals between normal (sinus) beats are usually
called NN intervals.
Heart rate variability (HRV) measures are
usually divided into two broad categories: time
domain measure and frequency domain measures. In
time domain, SDNN (Standard deviation of all NN
intervals) and RMSSD (Square root of the mean of
the squares of differences between adjacent NN
intervals) and in frequency domain of HRV
parameters consists of LF (Low frequency), HF
(High frequency) and LF/HF (Ratio of LF power to
HF power).HRV (R-R interval) is determined from
ECG signal for 0-10min, 10m 20 min, 20 30 min,
5 15 min, 15 25 min. Time domain parameters,
SDNN, RMSDD and frequency domain parameters,
LF, HF, LF/HF is determined.

ECG SIGNAL FROM MIT-BIH


DATABASE

HRV DETERMINATION

FEATURE VECTOR EXTRACTION

SVM CLASSIFIER

With cardiac arrest

Normal

C. Classification

SVM has proven its efficiency over neural


networks. Unlike neural networks, this model
does not need hypothesizing number of neurons
in the middle layer. SVM uses an optimum
linear separating hyperplane to separate two set
of data in a feature space. This optimum
hyperplane is produced by maximizing
minimum margin between the two sets.
Therefore the resulting hyperplane will only be
depended on border training patterns called
support vectors.
The support vector machine operates on two
mathematical operations: (1) Nonlinear mapping
of an input vector into a high-dimensional
feature space that is hidden from both the input
and output. (2) Construction of an optimal
hyperplane for separating the features
discovered in step 1. Support vectors are
determined by using the equations 5 -12.

Figure 1: Block diagram of cardiac arrest prediction


system
A. Data Base
The ECG signals were obtained from the MIT
BIH physionet database [27]. The MIT BIH
database consists of many ECG data sets of different
diseases. Two databases were selected for analysis:
Normal sinus Rhythm (NSR) database, Sudden
Cardiac Death (SCD) database. 20 Signals of patients
from each of the above databases were selected, thus
a total of 40 signals are taken. In the database for
each patient more than one hour ECG recordings are
given, from which the 30 minutes ECG data just
before cardiac arrest occurrence is considered in this
work. As 5 minutes ECG signal is sufficient to
extract the features from HRV, in this work
overlapping window of size 10 minutes is used to
extract the features. Thus for each patient 5, 10
minutes signals are obtained. Thus, in a total of 200
signals, 100 normal and 100 cardiac arrest signals are
obtained. One group was used for analysis or training
and the other for testing. 150 signals (75 normal and
75 cardiac arrest signals) are considered for training
phase and for testing phase, 50 signals ( 25 normal
and 25 cardiac arrest occurred signals) are
considered.

Variable definition:
1. Let x denote a vector drawn from the input
space, assumed to be of dimension mo.
2. Let {j(x)} for j=1 to m1, denote a set of
nonlinear transformations from the input space
to the feature space.
3. m1 is the dimension of the feature space.
378

2014 International Conference on Circuit, Power and Computing Technologies [ICCPCT]

4. {wj} for j=1 to m1 denotes a set of linear


weights connecting the feature space to the
output space.
5. {j(x)} represent the input supplied to the
weight wj via the feature space.
6. b is the bias
7.i is the Lagrange coefficient
8. di corresponding target output

D. Performance Evaluation
To evaluate the performance of the
classifier, the following statistical measures are used.
True Positive (TP): The subject is having cardiac
arrest and the classifier correctly identifies the
cardiac arrest signal.
False Positive (FP): The subject is normal but the
classifier misinterprets the subject had cardiac arrest.

9. Hyperplane acting as the decision surface is


defined as

True Negative (TN): The subject is normal and the


classifier correctly interprets that the subject is
normal.

(1)

Where
K(x,xi) = T(x)(xi) represents the inner product
of two vectors induced in the feature space by
the input vector x and input pattern xi pertaining
to the ith example. This term is referred to as
inner-product kernel.

False Negative (FN): The subject had cardiac arrest


but the classifier misinterprets that the subject is
normal.
Sensitivity: Refers to the ability of the classifier to
correctly identify the subject having cardiac arrest.

where

x , x ,,
0 (x) = 1 for all x
wo denotes the bias b

(2)

Specificity: Refers to the ability of the classifier to


correctly identify the subject is normal.

(3)

11. The Lagrange multipliers {i} for i = 1 to N


that maximize the objective function Q(),
denoted by 0,i is determined.
d

(10)

Negative Predictive Value (NPV): The probability


that the subject is not having cardiac arrest, when the
classifier identifies that the subject is not having
cardiac arrest.

K x ,x
(4)

Subject to the following constraints:

0
C
for i 1,2, , N
0

(9)

Positive Predictive Value (PPV): The probability that


the subject is actually having cardiac arrest, when the
classifier identifies that the subject is having cardiac
arrest

10. The requirement of the kernel K(x,xi) is to


satisfy Mercers theorem. The kernel function is
selected as a RBF learning machine.

1
2

(8)

(5)
(6)

(11)

Classification Accuracy of the Classifier: It is the


ratio of the total number of correct assessments to the
Total number of assessments.

4. The linear weight vector w0 corresponding to


the optimum values of the Lagrange multipliers
are determined using the following formula:

(12)

(7)
,
(xi) is the image induced in the feature space
due to xi.
w0 represents the optimum bias b0.

IV

RESULTS AND DISCUSSION

The normal and cardiac arrest signals are taken from


the physionet database. The signals are divided into
10minutes overlapping signals and HRV is

379

2014 International Conference on Circuit, Power and Computing Technologies [ICCPCT]

determined from the ECG for both normal and


cardiac arrest signals. The time domain parameters
and frequency domain parameters are extracted from
the HRV and a sample of one normal patient and one
cardiac arrest patient values are tabulated in Table 1
and Table 2 respectively. Thus, 200 signals (100
normal and 100 cardiac arrest signals) are divided
into 150 signals for training phase and 50 signals for
testing phase. SVM classifier with RBF kernel is
used. The classification efficiency during training
phase was 95 % and during testing phase was 88 %.
The results of the different performance measures
during training and testing phase are tabulated in
Table 3.

Patient 5:
TIME

SDNN

RMSSD

LF

HF

1.2628

0.1026

0.0421

0.5133

0.5084

10-20

1.3635

0.0874

0.4134

0.6860

0.7987

20-30

1.1758

0.7998

0.6376

0.6308

0.9251

05-15

1.1024

0.5606

0.2534

0.3354

0.3851

1525

1.0061

0.1525

0.0813

0.0720

0.0872

LF/HF

SDNN

RMSSD

LF

HF

LF/HF

0.3085

0.6915

HF

LF/HF
0.4462

10-20

0.0228

0.0274

0.3085

0.6915

0.4462

20-30

0.0228

0.0274

0.3085

0.6915

0.4462

05-15

0.0228

0.0274

0.3085

0.6915

0.4462

1525

0.0228

0.0274

0.3085

0.6915

0.4462

TIME
0- 10

SDNN
1.2628

RMSSD
0.1026

LF
0.0421

HF
0.5133

LF/HF
0.5084

10-20

1.3635

0.0874

0.4134

0.6860

0.7987

20-30

1.1758

0.7998

0.6376

0.6308

0.9251

05-15

1.1024

0.5606

0.2534

0.3354

0.3851

1525

1.0061

0.1525

0.0813

0.0720

0.0872

SDNN
0.2687
0.4293
0.1032

RMSSD
0.3269
0.3494
0.1867

Patient 2:
TIME
0- 10
10-20
20-30

Patient 2:
TIME

LF

0.0274

Patient 1:

Patient 1:

0- 10

RMSSD

0.0228

Table 2: Sudden Cardiac Arrest Patient Parameters

Table 1: Normal Person Parameters

TIME

SDNN

0- 10

LF
0.2432
0.2401
0.2448

HF
0.7568
0.7599
0.7552

LF/HF
0.3214
0.3159
0.3242

05-15

0.0449

0.1006

0.2572

0.7428

0.3462

1525

0.0921

0.1774

0.2485

0.7515

0.3307

Patient 3:

0- 10

0.017

0.0129

0.2148

0.7852

0.2736

10-20

0.0111

0.0193

0.2151

0.7849

0.2741

20-30

0.0129

0.0142

0.2536

0.7464

0.3397

TIME
0- 10

SDNN
0.0166

RMSSD
0.0306

LF
0.2481

HF
0.7521

LF/HF
0.3298

05-15

0.0282

0.0423

0.2066

0.7934

0.2604

10-20

0.0095

0.0101

0.2522

0.7478

0.3372

0.4681

20-30

0.0066

0.0092

0.2501

0.7499

0.3335

05-15

0.0129

0.0261

0.2521

0.7479

0.3371

1525

0.0111

0.0175

0.2499

0.7501

0.3331

1525

0.0159

0.016

0.3189

0.6811

Patient 3:
TIME

SDNN

RMSSD

LF

HF

LF/HF

0- 10

0.0231

0.0183

0.29

0.71

0.4084

10-20

0.0109

0.0163

0.2524

0.7476

0.3375

20-30

0.0087

0.0155

0.2738

0.7262

05-15

0.0071

0.0142

0.2495

0.7505

1525

0.0199

0.0203

0.2857

0.7143

Patient 4:
RMSSD

LF

HF

LF/HF

0- 10

0.1918

0.1541

0.2454

0.7546

0.3252

0.3771

10-20

0.1471

0.1239

0.2321

0.7679

0.3022

0.3324

20-30

0.1909

0.1108

0.2709

0.7291

0.3716

0.4001

05-15

0.1724

0.3354

0.2232

0.7768

0.2874

1525

0.1577

0.1437

0.2484

0.7516

0.3304

TIME

Patient 4:
TIME

SDNN

Patient 5:
SDNN

RMSSD

LF

HF

LF/HF

0- 10

0.0273

0.0227

0.2145

0.7855

0.2731

10-20

0.0238

0.0245

0.2979

0.7021

0.4244

20-30

0.0473

0.0235

0.209

0.791

0.2642

05-15

0.0394

0.04

0.2017

0.7983

0.2526

1525

0.0226

0.0233

0.3177

0.6823

0.4656

TIME

380

SDNN

RMSSD

LF

HF

LF/HF

0- 10

0.0815

0.0362

0.2371

0.7631

0.3107

10-20

0.0781

0.0325

0.2532

0.7468

0.3391

20-30

0.0812

0.0903

0.2392

0.7608

0.3143

05-15

0.0661

0.0594

0.2508

0.7492

0.3348

1525

0.0789

0.0322

0.2503

0.7497

0.3339

2014 International Conference on Circuit, Power and Computing Technologies [ICCPCT]

[6]

Table 3 : Performance measures of the Cardiac Prediction


System during Training phase and Testing phase

Training
Phase

Testing
Phase

Total Number of Signals

150

50

True Positive

73

23

False Positive

70

21

True Negative

False Negative
Sensitivity

2
97

2
92

Specificity

93

84

Positive Predictive Value

94

85

Negative Predictive Value

97

91

Accuracy

95

88

[7]

Mikka Ermes, Mark Van Gils and Tapani Salmi,


Prediction of Poor Outcome Using Detector of
Epileptiform EEG in ICU Patients Resuscitated After
Cardiac Arrest, IEEE Conference,2007.
Maria Teresa La Rovera and Franco Cobelli ,Short
Term Heart Rate Variability Strongly Predicts Sudden
Cardiac
Death
in
Chronic
Heart
Failure
Patients,American Heart Association,2003.

[8] C. J. C. Burges, A Tutorial on Support Vector


Machines for Pattern Recognition, Data Mining
and Knowledge Discovery, vol.2, 1998, pp.121167
[9]
[10]
[11]

[12]

CONCLUSION AND FUTURE WORK

[13]

In this paper, the cardiac prediction system


is proposed with HRV parameters as input and
support vector machines with RBF kernel as
classifier. The prediction system has demonstrated its
ability to generate human understandable factors, and
has shown its effectiveness to being a powerful
predictor of cardiac arrest before 30 minutes. The
experimental validations on a time domain and
frequency domain show that the proposed system is
able to achieve satisfactory prediction results. Hybrid
structure may be used to improve the classification
efficiency.

[14]

[15]

[16]
[17]
[18]

REFERENCES
[1]

Elias Ebrahimzadeth and Mohammad Pooyan, Early


Detection Of SCD by Using Classical Linear Techniques
and Time Frequency Methods On Electrocardiogram
Signals., J. Medical Science and Engineering, 2011,4,
699-706.
[2] .Yongqin Li, Joe Bisera, Max Harry Weil and Wanchun
Tang, An Algorithm Used for Ventricular Fibrillation
Detection Without Interrupting Chest Compression,
IEEE Transaction Biomedical Engineering ,Vol
59,No:1, Jan 2012.
[3] Deep Bera and Mithun Manjnath Nayak , Mortality risk
assessment for ICU patients using logistic regression,
Computing in cardiology , 2012.
[4] J.L.Vincent and R.Moreno,Clinical review:Scoring
systems in the critically ill, Crit.Care, vol.14,
p.207,2010.
[5] Yoeli Lu and Yisching Zhu,Predict the Neurological
Recovery Under Hypothermia after Cardiac Arrest
Using C0 Complexity Measure of EEG Signals, IEEE
EMBS Conference,August 20-24,2008

381

A Statistical Analysis and Digital Signal Processing,


Monson Hayes,Tata MacGraw Hill Publications.
Usman Rashed and Muhamad Javed Mizra,
Identification of Sudden Cardiac Death using Spectral
Domain Analysis Of ECG,IEEE Conference,2008.
L. Fei, X. Copie, M. Malik, and A. J. Camm, Shortand long-term assessment of heart rate variability for
risk stratification after acute myocardial infarction,
Amer. J. Cardiol., vol. 77, pp. 681684, 1996.
P. Ponikowski, S. D. Anker, T. P. Chua, R. Szelemej,
M. Piepoli, S. Adamopoulos, K. Webb-Peploe, D.
Harrington, W. Banasiak, K. Wrabec, and A. J. Coats,
Depressed heart rate variability as an in-dependent
predictor of death in chronic congestive heart failure
secondary to ischemic or idiopathic dilated
cardiomyopathy, Amer. J. Cardiol., vol. 79, pp. 1645
1650, 1997.
B. Goldstein and M. S. Ellenby, Heart rate variability
and critical illness: Potential and problems, Crit. Care
Med., vol. 28, pp. 39393940, 2000.
N. Liu, Z. Lin, Z. X. Koh, G.-B. Huang, W. Ser, and M.
E. H. Ong, Patient outcome prediction with heart rate
variability and vital signs, J. Signal Process. Syst., vol.
64, pp. 265278, 2011.
C. B. Pearce, S. R. Gunn, A. Ahmed, and C. D.
Johnson, Machine learning can improve prediction of
severity in acute pancreatitis using admission values of
APACHE II score and C-reactive protein,
Pancreatology, vol. 6, pp. 123131, 2006
C. C. Chang and C. J. Lin, LIBSVM: A library for
support vector ma-chines, ACM Trans. Intell. Syst.
Technol., vol. 2, pp. 127, 2011.
http://www.webmd.com/heart-disease/guide/suddencardiac-death
http://physionet.org/physiobank/database/mitdb

You might also like