How to exclude different sections of an ECG signal?
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I want to process various ECG signals, however, they all contain artifacts. Using a custom Matlab GUI, I shaded the artifacts of each datasets and were saved as a .mat file. Below is an example of an arifact being shaded. I also included the files of this signal here.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/363094/image.jpeg)
The .mat file contains the ECG signal, respiration signal, time, and the shaded data of the ECG and respiration signal. The shaded data contains 2 columns: first column being the start time and the second column being the end time of the shaded artifact, the rows correspond to the number of artifacts shaded in the signal (as seen below).
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/363097/image.jpeg)
I want to be able to exclude these shaded data when processing the ECG signal and I will have to do this for 40 datasets. Though I'm not sure how to approach this with my basic knowledge of using Matlab. Is there a way to automatically exclude the artifacts from the ECG signal using the shaded data?
2 Kommentare
Image Analyst
am 19 Sep. 2020
Do you want the artifact zones to be found automatically, or are you okay with manually indicating where they are?
Antworten (1)
Ameer Hamza
am 19 Sep. 2020
Try something like this
idx1 = t > AX1_Shade(:,1);
idx2 = t < AX1_Shade(:,2);
idx = idx1 & idx2;
idx = any(idx);
t(idx) = [];
fbsum(idx) = [];
Similar thing can be done for respiration data.
0 Kommentare
Siehe auch
Kategorien
Mehr zu Discrete Fourier and Cosine Transforms finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!