finding first and second maximum in an image/matrix
2 views (last 30 days)
Show older comments
Hello,
I have a 360x180 matrix. It has the normalised energy values in dB representing the beam pattern of microphone array in (1:360)° azimuth versus (1:180)° elevation angles.
When I plot it as imagesc(), I have a mainlobe at certain azimuth and elevation surrounded by few sidelobes.
Now I want to find the ratio of maximum sidelobe to the mainlobe. How can I do it?
Please help.
0 Comments
Answers (1)
Image Analyst
on 28 Jan 2012
Since your peaks probably have some width to them you can't simply sort the values and find the greatest. You also probably can't just threshold the image since the separate peaks may have different heights. Therefore I recommend using imregionalmax() in the Image Processing Toolbox. Then you can binarize the image and label it and call regionprops. For each peak you can get the max. (Actually you can get that without even calling regionprops.) But you probably need regionprops to find the centroids of all the peaks so you can determine which blobs are main peaks and which blobs are sidelobes of that main peak (say, the side lobe centroids are within a certain distance of the centroid of the larger main peak). Upload your image to tinypic.com if you need any help. It can get a little tricky if you have multiple clusters of peaks & side lobes and all those have different heights
15 Comments
See Also
Categories
Find more on Detection in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!