function [xx] = reducetopeak (xx)
xx(xx(:,:) <=(2*std(xx)), :) = 0; %brings noise level down to zero
r = find(xx); % find the first nonzero element...so finding the first peak
peakCount = r(1,1); %specifying the first peak for while loop to begin
count = peakCount + 1; %defining the next...
function [xx] = reducetopeak (xx)
xx(xx(:,:) <=(2*std(xx)), :) = 0; %brings noise level down to zero
r = find(xx); % find the first nonzero element...so finding the first peak
peakCount = r(1,1); %specifying the first peak for while loop to begin
count = peakCount + 1; %defining the next...
This is the code that I have written thus far, but I get error messages. The error message is a line 5: peakCount = r(1,1). . Anyone have any ideas?
function [xx] = reducetopeak (xx)
xx(xx(:,:) <=(2*std(xx)), :) = 0;
r = find(xx);
peakCount = r(1,1);
count = peakCount + 1;test
while (count <...
Hi All,
I have a logic problem I am having trouble solving with MATLAB. My objective is to select and count peaks in a dataset. However, findpeaks and peakseek function will not work.
My dataset consist mostly of electronic noise, with intermittent high frequency oscillations generated by...