I am trying to find the peaks of a 2D array using the find peaks function. I noticed however that when i request any other value than 3 for the number of peaks I obtain a subscripted assignment dimension mismatch error. The for loop code is shown below
for i = 1 : count [ peak(i,:), location(i,:) ] = findpeaks( low_time_signal(i,:), 'NPEAKS', 3); end
The variable count is equivalent to the number of rows in low_time_signal.
Best Answer