# how can i find the three peak points of the histogram..

조회 수: 18(최근 30일)
user06 12 Jan 2015
댓글: Image Analyst 19 Jan 2015
i can find 1st peak point, then how can i find the 2nd and 3rd peak of the histogram?

로그인 to comment.

### 답변(3개)

doc findpeaks
if you have the Signal Processing Toolbox.
Although you don't say which histogram you are referring to.
If you don't have the Signal Processing toolbox you can search for find peaks or similar on Matlab Exchange for code that will do the same.

#### 댓글 수: 9

표시 이전 댓글 수: 6
Image Analyst 13 Jan 2015
Did you try his original suggestion of using findpeaks()? Why not?
user06 14 Jan 2015
actually i didn't getting how to apply that findpeaks()function.. if u provide me the right example or syntax then i will try..
The help page for findpeaks gives something like 7 or 8 examples. I haven't memorised the syntax so you might as well look at the examples yourself rather than me spend time doing it just to repeat them for you here!

로그인 to comment.

Stalin Samuel 13 Jan 2015
sort the data in descending order & take first three values

#### 댓글 수: 3

user06 13 Jan 2015
how can i sort the values of the histogram?? sry i don't know this as i m new to matlab.. plz help by giving by some example.
That won't give you peaks. Quite likely it will give you the largest peak and the two values either side of it.
user06 13 Jan 2015
that code what i posted is only giving me the largest peak.. but i want to know how to find the three peaks of the histogram... and i also wants the same for the lowest point.. plz help its very important for me.

로그인 to comment.

mouh nyquist 15 Jan 2015
you can save your histogram as a variable and then use the file (peak finder in matlab exchange file)

#### 댓글 수: 7

표시 이전 댓글 수: 4
user06 19 Jan 2015
and how can i find the three minimum points of the same histogram.???
mouh nyquist 19 Jan 2015
I think it is easy , you need to read a little :-)
Image Analyst 19 Jan 2015
You can use findpeaks() like Adam already told you, but you just have to invert your signal so that valleys now become peaks.
upsidedownSignal = max(signal) - signal;
theValleys = findpeaks(upsidedownSignal);
In the future, you can make this a lot faster and more effective if you attach your data so people have something to work with. See this link

로그인 to comment.

이 질문에 답변하려면 로그인을(를) 수행하십시오.

Translated by