Draws intensity profiles of an image
[hprofile,vprofile]=improfile(matrix[,option,maximal_luminance])
Draws the values of pixels on a line and/or a row. Can draw profiles on the image or in separate windows. With the option=2, you can determine radius w of a laser beam, which allows you to find the beam waist.
This function was created (and tested) only with gray level images.
http://siptoolbox.sourceforge.net