Professional Documents
Culture Documents
Project 3
Project 3
METHODOLOGY
4.1 Introduction
The ANS functions can be studied by using HRV data of an individual is a well
known fact. The HRV analysis plays an important role in individuals with diabetes,
hypertension, physical fatigue, sleep apnea, coronary artery diseases and in addictions.
In the present work, stratification of subjects for HRV analysis has been done. It
was based on age, number of years of addiction (alcohol, smoking, stress). Age group
selected was basically young population (17 to 23 yrs.) as the identification in them helps
in prevention of diseases. A detailed questionnaire was administered to acquire the
personal information and consent was taken to analyze their ECG signals and
confidentiality was maintained.
In the present work, subjects selected age group between 17 to 23 years were
studied by stratifying the individuals based on the questionnaires administered for
acquiring patient data. Personal history consisted of;
I. Name:
II. Age:
III. Sex:
IV. Marital Status:
V. Blood Group:
VI. Height:
VII. Weight:
VIII. Smoking Since (in Years):
IX. No. of Cigarettes per day:
X. Alcoholic Since (in Years):
XI. Diabetes Since (in Years):
XII. Hypertension Since (in Years)
XIII. Drug History (Mention if you are taking any regular medication):
4.2 HRV Extraction for identification of Addictions (Smokers and Alcoholics)
Analysis of Preprocessing
Heart Rate Kubios and peak
Variability Software detection using
Matlab
Figure 4.1: Block diagram used to analyze HRV by extractingsoftware
ECG
Step1: Start
Step2: Acquire ECG data using three lead electrodes
Step3: Read the ECG data
Step4: Remove the artifact in the ECG signal
Step5: Plot the artifact reduced ECG signal using Matlab software
Step 6: Detect positive peaks of the data by comparing 3 successive samples when
The second data is higher with respect to the first and third data or the first
And second data are equal and higher than the third data checked
Step7: Copy the detected samples to peak array else check successive samples
Step8: Find the maximum peak value of peak array and set 70% of it as threshold
Value
Step9: If array value is less then threshold then load 0 in that respective samples
Step10: If peak value is greater than 0 then suppress next successive 20 arrays
Values to 0
Step11: Store the peak value in an array
Step12: Read the peak value array and extract it to Kubios Software tool
Step13: Perform Time-domain analysis and non-linear analysis
Step14: Read the statistical values which are available on the tool
Step15: Stop.
4.3.1 Flow chart for the analysis of HRV using ECG
Start
Peak detection
Have NO
read ECG
data for 5
minutes.
YES
Kubios Software
software
Time domain,
Frequency domain and
non-linear analysis
results
Analysis of HRV
Stop
Figure 4.3: Flow chart for Extracting HRV parameters using ECG Signal
The obtained ECG signals are filtered and the peaks of the signals were detected.
The detected peak were saved such that it has read for five minutes and is loaded to
kubios software for extracting HRV parameters. The flow chart is shown in figure 4.3 for
extracting HRV parameters.
Start
Read ECG
data into an
array
A
A
B
If(a>0)a
nd(b<0)
If(a==0)a YES
nd (b<0)
i=i+1 Peak [i]=file[i]
++1
Peak[i]=0
If
I=length
(file)-1
C
C
Th=max (peak)*0.5
i-1
If peak
NO
[i]<=Th
YES
If
N i=length
O
(Peak)
YES
Plot peak
Stop
Figure 4.5(a):ECG signal with baseline Figure 4.5(b):ECG signal after removing
wanderance baseline shift
Fingertip Acquisition
PPG
of the of PPG
Sensor
subject Signal
Pre
Analysis of Kubios processing
Heart Rate and peak
Software
Variability detection in
Matlab
software
Figure 4.9: Block Diagram for Analyzing HRV by extracting PPG
The block diagram of data acquisition and HRV analysis by using PPG signals is
shown in figure 4.9. PPG signals are taken from individual persons using bio kit at a
sample rate of 256 samples / second. The frequency response for PPG is 0.05-10Hz. It is
obtained by using reflection type PPG sensor, these signals are amplified using a PPG
amplifier and are interfaced with the PC using DAQ card 6009. The peaks of the PPG
signals are detected and the peaks are loaded to kubios software for HRV analysis.
4.6 Algorithm for HRV Analysis using PPG
Step1: Start
Step2: Acquire PPG data in Lab VIEW
Step3: Read the PPG data
Step4: Plot PPG data with artifacts in Matlab software
Step5: Remove the artifacts in the PPG signal
Step6: Plot the artifact free PPG signal
Step7: Detect positive peaks of the data by comparing 3 successive samples when the
Second data is higher with respect to the first and third data or first and second
data are equal and higher than the third data
Step8: Copy the detected samples to peak array else check successive samples
Step9: Find the maximum peak value of peak array and set 70% of it as threshold
value
Step10: If array value is less then threshold then load 0 in that respective samples
Step11: If peak value is greater than 0 then suppress next successive 20 array values
to 0
Step12: Store the peak value in an array
Step13: Read the peak value array and extract it to Kubios Software tool
Step14: Perform Time-domain analysis and non-linear analysis
Step15: Read the statistical values which are available on the tool
Step16: Stop.
4.6.1 Flow Chart of Present Study for HRV Analysis using PPG Signal
Start
Peak detection
Have NO
read 5
min.
data?
YES
Kubios Software
software
Time domain,
Frequency domain and
non-linear results
Analysis of HRV
Stop
Figure 4.10: Flow chart for extracting HRV parameters with PPG Signals
The PPG signals are obtained and it is filtered. The filtered PPG signals peaks are
detected and by using Kubios software HRV parameters are obtained. The flow chart for
obtaining HRV parameters is as shown in figure 4.10.
Start
File=Read
PPG data
A
A
B
If(a>0)a
nd(b<0)
If(a==0)a YES
nd (b<0)
i = i+1 Peak [i]=file[i]
Peak[i]=0
If
I=length
(file)-1
C
C
Th=max (peak)*0.7
i-1
If peak
NO
[i]<=Th
YES
If
N i=length
O
(Peak)
YES
Plot peak
Stop
It is also called the statistical analysis and is a common approach for studying
HRV because of its simplicity in application. The results of time-domain are the mean
RR intervals, Standard deviation of RR interval, NN50, PNN50, TINN values and
Triangular index values. Figure 4.15 shows the results of time-domain analysis of the
HRV signal.
Kubios Software is a user friendly tool for extracting HRV parameters. Also,
Kubios Software is an open source and its results are obtained with considerable accuracy
.Kubios Software assists for HRV analysis with both linear and nonlinear parameters, the
GUI in the software is designed such that it is simple and easily accessible. GUI includes
both the graphical representation and displayed values. When compared to other open
source software for HRV analysis Kubios Software tool was found to be much advanced.
The methodology mentioned above gives the algorithms, flowchart and GUIs of
the software used for the present study of HRV analysis. Kubios Software was found to
be advanced and sophisticated software compared to other open source softwares
available. Hence the above methodology was adopted for the present study.