EDA Signal Analysis - A Complete Tour
Difficulty Level:
Tags other☁eda☁filter

Physiological signals are informational resources containing a great potential of knowledge to be extracted, however, this knowledge is not directly accessible after signal acquisition.

In order to convert information into knowledge, physiological signals should be pre-processed, ensuring noise attenuation from unwanted sources and removal of unexpected artifacts. After pre-processing the signal, researcher can be totally secure that its valuable informational resource is ready to be processed, through the extraction of parameters.

Each one of the extracted parameters defines an objective way to analyse the acquired and pre-processed physiological data. Subsequent interpretation of the results/extracted parameters will be extremely important to understand which type of events/mechanism are taking place inside the human organism and, at this point, an amazing journey is reaching its fundamental stage with the horizon of achievable discoveries becoming observable by the eyes of knowledge.

The current Jupyter Notebook belongs to a set of Notebooks entitled "Complete Tour", where it is presented, in a sequential way, a guide containing recommended steps to be followed, namely: 1) sensor/electrode placement; 2) pre-acquisition notes; 3) pre-processing methods (filtering and motion artifact reduction); 4) detection of specific events and 5) parameter extraction procedures.

A - Electrodermal Activity (EDA) | Electrode Placement

Taking into consideration the great density of sweat glands (depending on the type of sweat glands reactions such as body temperature control, or emotional/stressful environment feedback can took place) in the palm of the hands and in the fingers , these become the ideal sites to place the EDA electrodes, as demonstrated in the illustrative example of the following figure:

B - Pre-Acquisition Requirements

In research literature it is considered that the typical informational band of EDA signal is in the range:

Accordingly to these articles, informational content of EDA signal reach, at the most broader criteria, the 35 Hz frequency components. So, applying the widely known Nyquist Theorem , before starting the data collection, the signal acquisition device must be configured to support sampling rates of at least 70 Hz , avoiding aliasing problems during the analog-to-digital conversion procedure.

C - Pre-Processing Stage

C0 - Importing Packages and load signal

In [1]:
# biosignalsnotebooks own package.
import biosignalsnotebooks as bsnb

# Scientific programming package.
from numpy import average, array, reshape, sqrt, sort, diff, where, argmax, max
from numbers import Number

# Pacakge dedicated to Wavelet decomposition algorithms.
from pywt import swt, iswt

# Machine-learning dedicated package.
from sklearn.mixture import GaussianMixture

# Gaussian Distribution function.
from scipy.stats import norm

# Built-in packages.
from copy import deepcopy
In [2]:
# Load entire acquisition data.
data, header = bsnb.load("/signal_samples/eda_hot_surface.txt", get_header=True)

# Store the desired channel (CH3) in the "signal" variable
signal = data["CH3"]

# Sampling rate definition.
sr = header["sampling rate"]

# Raw to uS sample value conversion.
signal_us = bsnb.raw_to_phy("EDA", "bitalino_rev", signal, 10, "uS")
In [3]:
from numpy import linspace
time = linspace(0, len(signal) / sr, len(signal_us))
bsnb.plot([time], [signal_us], y_axis_label="Electrodermal Response (uS)")