MATLAB: Extract signals from EMG

emg signalsignal processing

Hi,
I have 2 EMG signals, from which i need to extract signals are specific time increments.
Does anyone have any idea how i can go about this?
Any advice/help would be appreicated, thankyou!

Best Answer

Try this
t = linspace(0,100,10000); % time vector
y = rand(size(t)); % random signal
t_edge = 0:20:ceil(t(end)/20)*20; % edges of each partition
part_idx = discretize(t, t_edge);
part_signals = splitapply(@(x) {x}, y, part_idx); % partitioned signal
Related Question