How do I select a specific peak in a repeating pattern?
이전 댓글 표시
y is my data and I am trying to find the first peak of each repeating part, but in the third part, the last peak is greater than the first peak so the last peak is the peak that gets selected. This problem only occurs when the last peak is greater than the first peak. Nothing I have tried has been working.
pks = findpeaks(y,'MinPeakHeight', 200,'MinPeakDistance',4000)
채택된 답변
추가 답변 (1개)
Image Analyst
2017년 9월 5일
편집: Image Analyst
2017년 9월 5일
0 개 추천
OK, not too hard (a variety of ways to do it probably), but you forgot to attach your data, so I'll wait for that, as will probably most people. I'd probably threshold and find each group, then scan within the group to find out when the data stops increasing and starts decreasing. You can use diff() for that.
댓글 수: 1
Spencer Smith
2017년 9월 5일
편집: Spencer Smith
2017년 9월 5일
카테고리
도움말 센터 및 File Exchange에서 Descriptive Statistics에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
