# ECG-Based Subject Identification Using Statistical Features and Random Forest

Authors: Turky N. Alotaiby; Saud Rashid Alrshoud; Saleh A. Alshebeili; Latifah M. Aljafar
Journal: Journal of Sensors
 (2019)

---

## Abstract

In this work, a nonfiducial electrocardiogram (ECG) identification algorithm based on statistical features and random forest classifier is presented. Two feature extraction approaches are investigated: direct and band-based approaches. In the former, eleven simple statistical features are directly extracted from a single-lead ECG signal segment. In the latter, the single-lead ECG signal is first decomposed into bands, and the statistical features are extracted from each segment of a given band and concatenated to form the feature vector. Nonoverlapping segments of different lengths (i.e., 1, 3, 5, 7, 10, or 15 sec) are examined. The extracted feature vectors are applied to a random forest classifier, for the purpose of identification. This study considers 290 reference subjects from the ECG database of the Physikalisch-Technische Bundesanstalt (PTB). The proposed identification algorithm achieved an accuracy rate of 99.61% utilizing the single limb lead (I) with the band-based approach. A single chest lead (V1), augmented limb lead (aVF), and Frank’s lead (Vx) achieved an accuracy rate of 99.37%, 99.76%, and 99.76%, respectively, using the same approach.


---

## Body

## 1. Introduction

The aim of a biometric system is to uniquely identify or authenticate persons based on one or more behavioral and/or physiological characteristics, including the retina, fingerprint, or gait [1, 2]. Subject recognition is essential for many modern applications, which touch different aspects of our daily lives such as financial transactions, data protection, access control, entertainment, cars, and smartphones [3–5]. However, the current biometric traits used have different operational trade-offs in terms of performance, robustness, measurability, and detection of liveness [6–10]. Around three decades ago, Forsen et al. suggested the use of the electrocardiogram (ECG) as a biometric trait [11]. Biel et al.’s [12, 13] works are considered the first attempt to use ECGs for biometric purposes, considering the biometric characteristics of measurability (ease with which the characteristic is obtained), permanence (no change over time), universality (possession of the characteristic by the individual), and uniqueness (no two individuals share the same characteristic) [14–17]. Since then, many researchers have proposed various ECG-based identification approaches [1, 4, 18–27] using private and/or public databases [28, 29].Biometric identification system involves three main phases: the signal denoising, feature extraction, and classification. Signal denoising [30–34] is an important task, which is required due to the susceptibility of the ECG signal to noise of many sources such as power interference and electrode movement [35, 36]. Feature extraction is needed to provide unique biomarkers for a given ECG signal. Feature extraction methods can be grouped into three main categories: fiducial-based approaches which extract features while preserving the characteristics of the ECG signal, e.g., the amplitudes and intervals of heartbeats [20, 31, 37–43], non-fiducial-based approaches which do not require such precise knowledge of ECG characteristics [44–53], and hybrid-based approaches [54, 55].The classifier is the last stage of a biometric identification system. Different classifiers have been used in the literature such as neural network (NN), k-nearest neighbors algorithm (k-NN), support vector machine (SVM), and random forest [30, 31, 33, 49, 54–56]. Recently, deep learning has also been proposed for an ECG biometric identification system [57, 58].In this study, we propose a new nonfiducial method for subject identification based on statistical features and random forest classifier. For feature extraction, we are proposing two approaches: direct and band-based approaches. In the first approach, eleven statistical features are extracted directly from the single-lead ECG signal and fed to a random forest classifier. While in the band-based approach, the single-lead ECG signal is first decomposed into bands, and the statistical features are extracted from each band and concatenated to form the feature vector, which is then fed to the random forest classifier.This study uses the Physikalisch-Technische Bundesanstalt (PTB) dataset, which is a publicly available database. This database is compiled by the National Metrology Institute of Germany. It contains combinations of digitized ECGs of both normal and abnormal subjects’ recordings, which are provided for research via the linkhttps://PhysioNet.org [29]. Fifteen concurrently measured signals are included in each record: three limb leads (I, II, and III), three augmented limb leads (aVR, aVL, and aVF), six chest leads (V1, V2, V3, V4, V5, and V6), and three Frank leads (Vx, Vy, and Vz).The present study offers several advantages over other existing methods due to the following:(1)
It uses simple statistics for feature extraction, including the mean, standard deviation, median, maximum value, minimum value, range, interquartile range, interquartile first quarter (Q1), interquartile third quarter (Q3), kurtosis, and skewness of the ECG signal. We show by the t-distribution stochastic neighbor embedding (t-SNE) algorithm that subjects’ features based on these statistics are separable, which leads to high subject identification rate. The t-SNE is a nonlinear dimensionality reduction technique, which is utilized to visualize N-dimensional feature space using a two-dimensional space [59]
(2)
It provides extensive investigations using a reference population of 290 subjects (238 nonhealthy subjects and 52 healthy subjects) from the PTB ECG database. To the best of our knowledge, this is the largest number of subjects considered in the literature to produce results in the context of subject identification using ECG signals. Further, this study is the first to show identification results using 290 subjects from the signals of each of the 15 previously mentioned leads; see Tables1 and 2
(3)
It reports high identification accuracy results for 290 (healthy and nonhealthy) subjects using features extracted from simple statistics. Specifically, it has been found that a data segment length of 7 seconds from a single limb lead (I) gives an average accuracy of 99.61% using band-based approach. While a single chest lead (V1), augmented limb lead (aVF), and Frank’s lead (Vx) give an average accuracy of 99.73%, 99.76%, and 99.76%, respectively, using the same approachTable 1
Direct approach classification results using 290 subjects of the PTB dataset with segment lengths of 1, 3, 5, 7, 10, and 15 sec.
Lead
1 second
3 seconds
5 seconds
7 seconds
10 seconds
15 seconds
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
I
78.22
76.42
99.92
85.52
83.51
99.95
88.7
86.96
99.96
90.36
89.14
99.97
90.15
86.67
99.97
92.59
90.23
99.97
II
75.47
73.27
99.92
83.82
81.08
99.94
84.38
81.66
99.95
87.2
85.26
99.96
86.37
84.11
99.95
86.42
83.68
99.95
III
73.67
72.39
99.91
82.32
80.3
99.94
84.6
82.6
99.95
87.2
84.64
99.96
84.88
81.93
99.95
86.42
83.28
99.95
aVR
78.81
76.23
99.93
84.36
81.26
99.95
86.09
83.94
99.95
87.84
86.07
99.96
89.81
87.21
99.96
87.3
83.05
99.96
aVL
76.72
75.11
99.92
84.59
83.43
99.95
88.09
86.56
99.96
90.52
89.91
99.97
89.35
86.84
99.96
89.77
87.07
99.96
aVF
75.3
73.14
99.91
82.15
79.91
99.94
83.16
80.36
99.94
85.39
82.69
99.95
85.91
83.19
99.95
85.19
82.47
99.95
V1
84.53
82.59
99.95
91.13
89.58
99.97
92.96
91.17
99.98
93.44
90.86
99.98
94.5
91.81
99.98
92.77
89.54
99.97
V2
87.3
86.07
99.96
92.49
91.35
99.97
95.24
94.3
99.98
95.42
93.69
99.98
94.16
91.44
99.98
95.41
93.45
99.98
V3
89.19
87.98
99.96
94.56
93.65
99.98
95.68
94.34
99.99
96.29
96.1
99.99
95.88
94.48
99.99
95.59
94.02
99.98
V4
89.61
88.52
99.96
93.73
93.13
99.98
94.74
94.22
99.98
96.21
95.48
99.99
95.42
93.42
99.98
95.94
94.08
99.99
V5
87.27
85.84
99.96
92.23
91.38
99.97
92.69
92.39
99.97
94.31
93.55
99.98
94.04
93.05
99.98
93.3
91.38
99.98
V6
84.69
83.57
99.95
89.46
88.04
99.96
90.86
89.86
99.97
92.58
91.76
99.97
92.67
90.52
99.97
92.59
90.52
99.97
Vx
88.17
86.84
99.96
92.03
90.94
99.97
93.8
92.64
99.98
93.29
91.45
99.98
93.59
91.26
99.98
93.12
91.03
99.98
Vy
80.75
79.13
99.93
86.62
85.58
99.95
87.76
86.29
99.96
90.36
89.24
99.97
89.46
87.24
99.96
86.42
83.16
99.95
Vz
87.81
86.28
99.96
92.73
91.72
99.97
93.85
93.43
99.98
94.63
94.1
99.98
94.04
92.18
99.98
94.18
92.7
99.98Table 2
Band-based approach classification results using 290 subjects of the PTB dataset with segment lengths of 1, 3, 5, 7, 10, and 15 sec.
Lead
1 second
3 seconds
5 seconds
7 seconds
10 seconds
15 seconds
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
Avg. Acc.
Avg. Sen.
Avg. Spe.
I
98.15
97.84
99.99
99.17
98.76
100
99.34
98.92
100
99.61
99.66
100
98.97
98.39
100
98.42
97.59
99.99
II
97.79
97.47
99.99
99.04
98.76
100
99.17
98.77
100
99.06
98.34
100
98.97
98.1
100
97.89
96.95
99.99
III
97.44
96.98
99.99
99.17
98.77
100
99.17
98.9
100
99.21
98.76
100
98.75
97.73
100
98.07
97.13
99.99
aVR
98.02
97.57
99.99
99.53
99.48
100
99.5
99.19
100
99.37
98.9
100
99.77
99.54
100
98.42
97.53
99.99
aVL
97.46
97.18
99.99
98.9
98.75
100
99.06
98.68
100
98.82
98.41
100
98.86
98.62
100
97.72
96.67
99.99
aVF
97.58
97.11
99.99
99.17
98.87
100
99.12
98.6
100
99.37
99.17
100
98.63
97.84
100
98.07
96.72
99.99
V1
98.38
98.09
99.99
99.53
99.36
100
99.45
98.77
100
99.76
99.52
100
99.54
99.37
100
98.6
97.87
100
V2
98.4
98.19
99.99
99.24
99.21
100
99.61
99.53
100
99.21
99.03
100
98.86
98.79
100
98.25
97.18
99.99
V3
98.89
98.77
100
99.37
99.27
100
99.61
99.17
100
99.45
98.69
100
98.63
97.87
100
98.25
97.18
99.99
V4
98.75
98.65
100
99.5
99.38
100
99.61
99.53
100
99.53
99.03
100
99.09
98.71
100
98.6
97.87
100
V5
98.41
98.32
99.99
99.5
99.43
100
99.28
98.99
100
99.61
99.1
100
98.86
98.28
100
98.25
97.36
99.99
V6
98.35
98.21
99.99
99.47
99.26
100
99.34
98.79
100
99.61
99.38
100
99.09
97.96
100
98.6
97.41
100
Vx
98.84
98.75
100
99.63
99.56
100
99.5
99.43
100
99.76
99.79
100
98.97
98.07
100
98.95
98.62
100
Vy
98.23
97.85
99.99
99.34
99.11
100
99.56
99.36
100
99.53
99.03
100
99.32
98.94
100
98.25
96.55
99.99
Vz
98.56
98.36
100
99.63
99.45
100
99.56
99.48
100
99.69
99.45
100
99.54
99.08
100
98.95
98.33
100The rest of the paper is organized as follows. Section2 describes the proposed identification method. Section 3 presents the performance evaluation results for the proposed approaches and compares them to state-of-the-art identification systems. Finally, Section 4 gives concluding remarks.


## 2. Method

The proposed method comprises two phases: enrollment and identification. Each phase consists of ECG signal acquisition and preprocessing and feature extraction. After enrolling all the subjects, the registered ECG signals are used to train the random forest classifier. In the identification phase, the trained model is adapted to identify the subjects. Figure1 shows the process of the proposed method. The details of each stage are presented in the following subsections.Figure 1
Subject identification ECG-based approach using statistical features and random forest.


### 2.1. Data Acquisition and Preprocessing

The PTB database is constructed utilizing 15 leads, each of which measuring a specific electrical potential difference. Each signal is sampled at 1000 samples/sec with 16-bit resolution. The length of the recording session for each subject was between 31 and 120 sec. The PTB database has undergone two main preprocessing operations: detrending and inverting. The first operation is required due to the presence of some linear trend in the database signals, possibly originating from different sources (e.g., voltage fluctuations in the recording device and subject’s muscle movements), which can potentially hinder the data analysis, and thus requires removal before further processing. Detrending is achieved by subtracting from each lead the least-squares-fit straight line of data. ECG signals are upside down in some cases, thus requiring inversion. Figures2 and 3 show the time domain of processed 5 sec I, aVR, V1, and Vx lead signals and the frequency domain for the same leads of a healthy subject (S104). The Frank lead Vx signal has the highest amplitude, as shown in the time domain, while in the frequency domain we notice that most of the energy is concentrated below 35 Hz in all leads.Figure 2
Time domain of four processed signals.Figure 3
Frequency spectrum of four leads.


### 2.2. Feature Extraction

We propose two approaches to extract features from the ECG signal: direct and band-based approaches. In the first approach, the preprocessed ECG signal is segmented, where statistical features are extracted from each segment to form the feature vector. While in the second approach, the preprocessed ECG signal is decomposed into bands, each signal’s band is segmented. The statistical features are then extracted from each segment. The feature vector is formed by concatenating the statistical features of each segment from all bands. Figure4 presents the two approaches.Figure 4
Feature extraction approaches: (a) direct-based approach and (b) band-based approach.
(a)
(b)The normal ECG signal’s frequency spectrum ranges from 0.01 to 100 Hz, where 90% of the energy lies in the range of 0.25 Hz to 35 Hz [60]. Therefore, direct single-lead identification accuracy can be improved by considering multiple spectral components. Here, the single-lead ECG signal is decomposed into seven subbands by employing a filter bank using seven finite impulse response band-pass filters. Each filter is of band 5 Hz, as follows: 0.1-5, 5-10, …, 30-35 Hz. Figure 5 shows the frequency responses of the filters employed to perform signal decomposition.Figure 5
Frequency response of the filter bank.A nonoverlapping sliding window (1, 3, 5, 7, 10, or 15 sec) is applied for partitioning the ECG data into segments. Different window sizes are used to examine the effect of segment length on the identification system, irrespective of the individual heartbeats or specific characteristics of ECG waves.Eleven statistical features are extracted from each segment, as listed in Section1. These features are selected to measure certain ECG signal characteristics. Note that we estimate the mean and median to measure the ECG signal central tendency. While we use the standard deviation, range, and interquartile range to measure the statistical dispersion. The kurtosis and skewness are also used to measure the sharpness of the peak and asymmetry of the ECG signal distribution, respectively. The other statistics (the minimum value, maximum value, interquartile first quarter, and interquartile third quarter) are self-explained. The definitions of these statistics and their estimation from a data record of length N samples are well known and can be found in [61]. Figure 6 shows their histograms for a data segment of length 7 sec.Figure 6
Histograms of statistical features for a data segment of 7 sec length.


### 2.3. The Random Forest Classifier

The random forest (RF) is an ensemble learning method developed by Breiman [62] and used for classification and regression. It includes a large number of decision tree classifiers. The classification process in the decision tree can be thought of as asking a series of questions about the available data until reaching at a decision. Each tree in the forest is constructed with a randomly selected subset of the training dataset with replacement and grows without pruning. A tree consists of nodes which are either branches (have children nodes) or leafs (terminal nodes). The best split on each node in a tree is found by employing feature random selection methods [51–53]. Figure 7 presents an illustrative example of splitting a node. The node has balanced samples, 20 red and 20 blue. The aim is to find the best split that generates child nodes with the least diversity which leads to a more certain decision. The figure shows three suggested splits A, B, and C that are generated by randomly selecting a set of features and a threshold value. We can see that tree C has the best split, with the set of features number 3 and threshold value of 0.23, since it produced branches with the highest certainty. The first branch has 0.77 (17 over 22) probability of the red class. The second branch has 0.83 (15 over 18) probability of the blue class. The next step of the decision tree creation process is to find the best split on both child nodes. The random forest makes decisions based on the average of the probabilities predicted by the trees. The major advantages of random forest are that it does not suffer from overfitting problem [62], produces high classification accuracy, and provides feature importance analysis [63].Figure 7
Example of node splitting in a decision tree.
(a)
(b)
(c)The classifier undergoes two stages: training and testing. In the training phase, each tree is constructed using a sample with replacement of the training dataset. In the testing phase, each tree classifies the testing instance and a majority voting technique is used to classify the instance. Random forest has been used in various domains such as astronomy [64] and medicine [65–68]. In this work, 100 decision tree classifiers are employed.


## 2.1. Data Acquisition and Preprocessing

The PTB database is constructed utilizing 15 leads, each of which measuring a specific electrical potential difference. Each signal is sampled at 1000 samples/sec with 16-bit resolution. The length of the recording session for each subject was between 31 and 120 sec. The PTB database has undergone two main preprocessing operations: detrending and inverting. The first operation is required due to the presence of some linear trend in the database signals, possibly originating from different sources (e.g., voltage fluctuations in the recording device and subject’s muscle movements), which can potentially hinder the data analysis, and thus requires removal before further processing. Detrending is achieved by subtracting from each lead the least-squares-fit straight line of data. ECG signals are upside down in some cases, thus requiring inversion. Figures2 and 3 show the time domain of processed 5 sec I, aVR, V1, and Vx lead signals and the frequency domain for the same leads of a healthy subject (S104). The Frank lead Vx signal has the highest amplitude, as shown in the time domain, while in the frequency domain we notice that most of the energy is concentrated below 35 Hz in all leads.Figure 2
Time domain of four processed signals.Figure 3
Frequency spectrum of four leads.


## 2.2. Feature Extraction

We propose two approaches to extract features from the ECG signal: direct and band-based approaches. In the first approach, the preprocessed ECG signal is segmented, where statistical features are extracted from each segment to form the feature vector. While in the second approach, the preprocessed ECG signal is decomposed into bands, each signal’s band is segmented. The statistical features are then extracted from each segment. The feature vector is formed by concatenating the statistical features of each segment from all bands. Figure4 presents the two approaches.Figure 4
Feature extraction approaches: (a) direct-based approach and (b) band-based approach.
(a)
(b)The normal ECG signal’s frequency spectrum ranges from 0.01 to 100 Hz, where 90% of the energy lies in the range of 0.25 Hz to 35 Hz [60]. Therefore, direct single-lead identification accuracy can be improved by considering multiple spectral components. Here, the single-lead ECG signal is decomposed into seven subbands by employing a filter bank using seven finite impulse response band-pass filters. Each filter is of band 5 Hz, as follows: 0.1-5, 5-10, …, 30-35 Hz. Figure 5 shows the frequency responses of the filters employed to perform signal decomposition.Figure 5
Frequency response of the filter bank.A nonoverlapping sliding window (1, 3, 5, 7, 10, or 15 sec) is applied for partitioning the ECG data into segments. Different window sizes are used to examine the effect of segment length on the identification system, irrespective of the individual heartbeats or specific characteristics of ECG waves.Eleven statistical features are extracted from each segment, as listed in Section1. These features are selected to measure certain ECG signal characteristics. Note that we estimate the mean and median to measure the ECG signal central tendency. While we use the standard deviation, range, and interquartile range to measure the statistical dispersion. The kurtosis and skewness are also used to measure the sharpness of the peak and asymmetry of the ECG signal distribution, respectively. The other statistics (the minimum value, maximum value, interquartile first quarter, and interquartile third quarter) are self-explained. The definitions of these statistics and their estimation from a data record of length N samples are well known and can be found in [61]. Figure 6 shows their histograms for a data segment of length 7 sec.Figure 6
Histograms of statistical features for a data segment of 7 sec length.


## 2.3. The Random Forest Classifier

The random forest (RF) is an ensemble learning method developed by Breiman [62] and used for classification and regression. It includes a large number of decision tree classifiers. The classification process in the decision tree can be thought of as asking a series of questions about the available data until reaching at a decision. Each tree in the forest is constructed with a randomly selected subset of the training dataset with replacement and grows without pruning. A tree consists of nodes which are either branches (have children nodes) or leafs (terminal nodes). The best split on each node in a tree is found by employing feature random selection methods [51–53]. Figure 7 presents an illustrative example of splitting a node. The node has balanced samples, 20 red and 20 blue. The aim is to find the best split that generates child nodes with the least diversity which leads to a more certain decision. The figure shows three suggested splits A, B, and C that are generated by randomly selecting a set of features and a threshold value. We can see that tree C has the best split, with the set of features number 3 and threshold value of 0.23, since it produced branches with the highest certainty. The first branch has 0.77 (17 over 22) probability of the red class. The second branch has 0.83 (15 over 18) probability of the blue class. The next step of the decision tree creation process is to find the best split on both child nodes. The random forest makes decisions based on the average of the probabilities predicted by the trees. The major advantages of random forest are that it does not suffer from overfitting problem [62], produces high classification accuracy, and provides feature importance analysis [63].Figure 7
Example of node splitting in a decision tree.
(a)
(b)
(c)The classifier undergoes two stages: training and testing. In the training phase, each tree is constructed using a sample with replacement of the training dataset. In the testing phase, each tree classifies the testing instance and a majority voting technique is used to classify the instance. Random forest has been used in various domains such as astronomy [64] and medicine [65–68]. In this work, 100 decision tree classifiers are employed.


## 3. Results and Discussion

In this section, performance evaluation results of the proposed approaches are presented. Also, we compare the performance of the proposed approaches with the state-of-the-art PTB-based identification systems. The results are obtained using the PTB dataset, which includes 290 subjects. Six segments of different lengths (1, 3, 5, 7, 10, or 15 sec) were considered to study the effect of segment’s length on the identification process. For each subject, the feature vectors are extracted and split into two sets training and testing. The first set consists of 70% of the features to train a random forest model and the remaining 30% of the features are used in the testing step. We used three widely used metrics to evaluate the performance of the proposed approach. These metrics include accuracy, sensitivity, and specificity [69] and are denoted by Avg. Acc., Avg. Sen., and Avg. Spe., respectively.Table1 presents the identification performance of direct feature extraction approach using different segment lengths averaged over all 290 subjects. For each segment’s length, 15 models were created, one model for each ECG lead. By virtue of Table 1, we observe that lead I achieved the best accuracy of 92.59% using a 15-second segment length. Lead II and lead III achieved the best accuracy of 87.2% and 87.2% using a 7-second segment length. Augmented limb aVL achieved the best accuracy of 90.52% using a 7-second segment length. Chest leads V1 to V6 achieved an average accuracy more than 90% when the segment length is greater than 3 seconds. Lead V3 achieved the best accuracy of 96.26% using a 7-second segment length. Frank’s leads Vx and Vz achieved the best accuracy, which is more than 92% using a segment length greater than one second. Figure 8 presents the average accuracy of direct feature extraction approach using different segment lengths. It is worth noting that the training phase using the 7-second segment length took 24.7 sec using a machine equipped with 3.3 GHz Intel core i7-processor, while the identification process of 290 subjects took 3.2 sec on the same machine.Figure 8
The accuracy of direct approach classification using 290 subjects of the PTB dataset with segment lengths of 1, 3, 5, 7, 10, and 15 sec.Table2 presents the identification performance of band-based feature extraction approach. All limb leads achieved a minimum accuracy rate with more than 97.44% using a 1-second segment length and an accuracy rate greater than 99% using the 3- to 7-second segment lengths. The augmented limb leads achieved an accuracy>97.46% using a 1-second segment length and an accuracy>98% using a segment length greater than three seconds. Among the augmented limb leads, lead aVR achieved the best accuracy of 99.77% using a 10-second segment length. The chest leads achieved an accuracy>98.35% using a 1-second segment length. Lead V1 achieved the best accuracy rate, which is 99.76% using a 7-second segment length. Leads V2 to V6 achieved the best accuracy rate, which is 99.61% using the 5- and 7-second segment lengths. Frank’s leads achieved an accuracy>98.23% using a segment length greater than 1 second. Lead Vx achieved an accuracy of 99.76% using a 7-second segment length. Figure 9 presents the average accuracy of band-based feature extraction approach using different segment lengths. The training phase in this approach using the 7-second segment length took 88.1 sec using a machine equipped with 3.3 GHz Intel core i7-processor, while the identification process of 290 subjects took 4.5 sec on the same machine.Figure 9
The accuracy of band-based approach classification using 290 subjects of the PTB dataset with segment lengths of 1, 3, 5, 7, 10, and 15 sec.Figure10 shows the confusion matrix of 290 subjects using the band-based approach with limb lead I signal of length 7 sec. We plot the confusion matrix in the form of a 3D figure to make it easier to visualize where the confusion and correct identification appear. Specifically, we observe from Figure 6 that using the band-based approach with limb lead I, all the subjects achieved 100% sensitivity except four subjects: S109 (Sen.=80%), S141 (Sen.=80%), S184 (Sen.=60%), and S262 (Sen.=80%). Twenty percent of the testing segments of subjects S109, S141, and S262 were misclassified with subjects S35, S97, and S219, respectively, while twenty percent of the testing segments of subject S184 were misclassified with subject S103, and also twenty percent of the testing segments of the same subject (S184) were misclassified with S119.Figure 10
The confusion matrix of 290 subjects using the band-based approach with limb lead I and 7 sec segment length.The results of Figure10 can be confirmed by investigating the separability of subjects using the t-SNE algorithm. Figure 11 shows the results of the t-SNE algorithm when it is applied to the dataset of the following ten subjects with 16 segments each: S35, S50, S97, S100, S109, S119, S141, S184, S219, and S262. The t-SNE algorithm visualizes the 77 dimensional space features of the band-based approach using a two-dimensional (2D) space. Therefore, the algorithm represents the feature vector of each segment by a single point in a 2D space.Figure 11
Separability investigation of band-based feature extraction approach using limb lead (I) signals of ten subjects.Figure11 shows the clusters of subjects’ segments. Note that the clusters of subjects S50 and S100 are well separated from other subjects’ clusters. However, the cluster of S35 has overlap with S109. Similar observations can be seen for the subjects S97, S109, S119, S141, S184, S219, and S262, which explains the misclassification revealed previously by the confusion matrix.Table3 shows the performance of the proposed approaches in comparison to the results of the state-of-the-art subject identification methods, which are available in literature and utilizing the PTB dataset. In the table, we list the reference, year of publication, number of subjects considered for identification, the segment’s length (if available), the sensitivity, and the method of identification used. Referring to Table 3, it is worthy of noting that the proposed approaches have been evaluated using 290 subjects, which is the largest number considered in the literature up to date. Further, the band-based approach, which is evaluated using such a large number of subjects and utilizing simple statistical features, has demonstrated performance greater than 99%, which makes it very attractive for practical applications. Note that the method of Wang et al. [76] is the closest in performance to our proposed method but considered only 100 subjects for identification. Further, it adopts the sparse coding which requires optimization involving l0 norm, which is an NP hard problem.Table 3
The proposed approaches in comparison with PTB-based subject identification methods.
References
Method
Year
NS
DU (s)
Sen
Agrafioti and Hatzinakos [45]
Autocorrelation and discrete cosine transform (DCT)
2006
14
10
100
Wübbeler et al. [70]
Fiducial features and simple distance measure
2007
74
10
99
Agrafioti and Hatzinakos [71]
Normalized autocorrelation coefficients and K-nearest neighbors (K-NN) as a classifier
2008
13
10
96.2
Agrafioti and Hatzinakos [72]
Same approach as in [70] with feature level and decision level fusions
2008
14
5
100
Wang et al. [73]
Autocorrelation (AC) in conjunction with a discrete cosine transform (DCT) and K-NN as classifier
2008
13
NA
84.61
Fatemian and Hatzinakos [36]
Templet-based
2009
13
NA
99.62
Safie et al. [74]
Pulse active ratio (PAR) technique for feature extraction and Euclidean distance
2011
112
30
93.60
Zhao et al. [49]
Ensemble empirical mode decomposition, Welch spectral analysis to extract significant features, principal component analysis (PCA) for dimensionality reduction, and K-NN as classifier
2013
25
NA
96.00
Tantawi et al. [75]Test set 1Test set 2
Fiducial feature set (with 28 features) and four feature reduction methods (PCA, linear discriminant analysis (LDA), information gain ratio (IGR), and rough sets) and neural network as a classifier
2013
146
~8
10083.3
Wang et al. [76]
Sparse representation and K-NN as classifier
2013
100
2-4
99.5
Jekova and Bortolan [77]
Correlation coefficient assessment, along with assessment of their linear and nonlinear combinations
2015
14
10
92.9
Brás and Pinho [78]
Information-theoretic data models for data compression and on similarity metrics related to the approximation of the Kolmogorov complexity
2015
52
20
99.9
Waili et al. [79]
Q-R-S feature points and multilayer perceptional neural network as a classifier
2016
14
121.02 heartbeats
96
Paiva et al. [25]
Three features ST, RT, and QT and support vector machines as a classifier
2017
10
30
97.5
Dong et al. [80]
Deterministic learning
2018
113
NA
92.8
Labati et al. [58]
The deep convolutional neural networks are used to extract the features from QRS complexes and soft-max as a classifier.
2018
52
10
100
Alotaiby et al. [81]
Common spatial pattern and support vector machine as a classifier
2019
200
7
Single-lead (I)
95.15
Single-lead (V3)
98.92
Proposed method
11 statistical features, DWT, and random forest as a classifier
290
7
Single-lead (I)
99.66
Single-lead (aVF)
99.17
Single-lead (V1)
99.52
Single-lead (Vx)
99.79
DU: duration; NA: the information is not available or computable; NS: number of subjects; Sen: sensitivity.


## 4. Conclusion

This paper presents an ECG-based identification system that relies on statistical features and random forest classifier. Two feature extraction approaches are investigated: direct and band-based approaches. In the direct approach, the ECG signal is segmented and eleven statistical features are extracted from each segment to form the feature vector. In the second approach, the ECG signal is decomposed into seven bands, where the feature vector is formed by concatenating the statistical features extracted from each band’s segment. Six segment lengths are examined: 1, 3, 5, 7, 10, and 15 sec. The data is split into training and testing datasets. The feature vectors of the former are used to train the classifier (random forest) during the identification stage; the trained classifier is then tasked with identifying the subject using the testing data. The proposed method was evaluated using 290 reference subjects in the PTB database. Using the band-based feature extraction approach, the identification system achieved an accuracy rate of 99.61% utilizing a single limb lead (I). While a single chest lead (V1), augmented limb lead (aVF), and Frank’s lead (Vx) achieved accuracy rates of 99.37%, 99.76%, and 99.76%, respectively. It is known that variance in physical, mental, or emotional stimulation levels affects heart rate. Unfortunately, the ECG signals in the PTB dataset are recorded under the same conditions. Therefore, evaluating the proposed identification system under the effect of these stimulations will be the topic of our future work.



---

*Source: 6751932-2019-12-16.xml*