필터 지우기
필터 지우기

How to find the maximum peaks from histogram ?

조회 수: 6 (최근 30일)
Priyanka Roy
Priyanka Roy 2015년 10월 23일
답변: Image Analyst 2015년 10월 23일
How can i find the maximum peaks from a histogram. I have tried findpeaks() function but it is giving large number of peak values.
Here image1 is the histogram of an image where in image2 i have pointed the peaks which are the maximum peaks. how can i find only the maximum peaks ?
  댓글 수: 1
Adam
Adam 2015년 10월 23일
findpeaks has plenty of options you can set to limit the number of peaks. It also returns both the peak values and their locations allowing you to filter them yourself based on an amplitude threshold if that is what you want.
You have to define what you want to count as a 'peak' though. The thresholds you can pass to findpeaks account for many of these.

댓글을 달려면 로그인하십시오.

채택된 답변

Image Analyst
Image Analyst 2015년 10월 23일
If you have the Statistics and Machine Learning Toolbox, you can use ksdensity() to get a smoother estimate of the pdf, then use findpeaks() on that. Or if you have the Signal Processing Toolbox, run the hist through sgolayfilt() to get a smoothed histogram, then run findpeaks on that.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Descriptive Statistics에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by