For LOOP for splitting an ECG signal into different CHUNKS
Mostra commenti meno recenti
I have an ECG signal `[xx]` with length is 2000, I am trying to create "for loop function" that can split the signal into 10 separate chunks but I am experiencing difficulty. That is, I want to achieve something like this:
yy1 = xx(1:200) -----chunk 1;
yy2 = xx(201:400) ----chunk 2 ;
.
.
.
.
yy10 = xx(1801:2000)-----chunk 10;
A "for loop" will make this faster for me especially with a signal of larger length.
Please, any suggestion on how to do this with a for "loop"?
2 Commenti
Geoff Hayes
il 12 Feb 2020
Ola - consider using reshape to split the signal into a 200x10 array (assuming exactly 2000 elements in ECG signal).
Jon
il 12 Feb 2020
Sorry Geoff, I was busy writing my answer when you made the above suggestion. As you can see I also went for the reshape approach.
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Multirate Signal Processing in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!