findpeaks in Matlab replaced by handwritten 'findPeaks'