See the help or read this: http://www.mathworks.com/matlabcentral/answers/6200-tutorial-how-to-ask-a-question-on-answers-and-get-a-fast-answer
You might also be interested in imregionalmax() or imdilate() if you have the Image Processing Toolbox.
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!