PROFILE

The PROFILE function extracts a profile from an image and returns a floating-point vector containing the values of the image along the profile line marked by the user.

This routine is written in the IDL language. Its source code can be found in the file profile.pro in the lib subdirectory of the IDL distribution.

Using PROFILE

To mark a profile line after calling PROFILE, click in the image with the left mouse button to mark the beginning and ending points. The pixel coordinates of the selected points are displayed in the IDL command log.

Calling Sequence

Result = PROFILE( Image [, XX, YY] )

Arguments

Image

The data array representing the image. This array can be of any type except complex.

XX

A named variable that will contain the X coordinates of the points along the selected profile.

YY

A named variable that will contain the Y coordinates of the points along the selected profile.

Keywords

NOMARK

Set this keyword to inhibit marking the image with the profile line.

XSTART

The starting X location of the lower-left corner of Image . If this keyword is not specified, 0 is assumed.

YSTART

The starting Y location of the lower-left corner of Image . If this keyword is not specified, 0 is assumed.

Example

Display an image, select a profile and plot that profile in a new window.

A = BYTSCL(DIST(256)) ; Create an image.

TV, A ; Display the image.

R = PROFILE(A) ; Extract a profile from the image .

Mark two points on the image with the mouse.

WINDOW, /FREE ; Create a new plotting window .

PLOT, R ; Plot the profile .

See Also

PROFILES