Produced by IDL 7.1.1
User Documentation

./toolbox
awv.pro

Last modification date:
Wed Sep 28 13:27:10 2016

awv

function awv(data, vel, brange, erange, mode, fract, [lefthorn=float], [righthorn=float], [rms=float], [/quiet])

Function to find the area, width, and velocity of a galaxy profile.

There are four ways in which the left and right (low channel number and high channel number) edges of the galaxy profile can be determined. The mode parameter selects one of these methods:

In the first 3 modes, the final left and right edge are linear interpolations to get the fractional channel where data value crossed the threshold given by fract for that particular mode.

If an edge is not found, a warning is issued and the appropiate end-point of the region of interest is used. Only the data values within the region of interest are used here.

The returned value is a 6-element array with these values, in this order.

Blanked data is ignored by this routine. Since the velocities used to calculate widths and centers come from the centers of the valid channels, ignoring the blanked data is equivalent to replacing the blanked data by it's nearest non-blanked neighbor in the direction of the edge searches. If the data is all blanked in the region of interest, the returned values are all 0.

This code adapted from code in use at Arecibo. This particular version was originally from Karen O'Neil.

Option 4 added by Karen Masters as part of work for GBT06A-027, GBT06B-021, GBT06C-049, GBT08B-003: "Mapping Mass in the Nearby Universe with 2MASS".

Contributed By: Karen O'Neil, Bob Garwood, and Karen Masters.

Returns
the values in a 3 element array: [0] is the area, [1] is the width and [2] is the velocity. Returns 0.0 for all 3 values on error.
Version
$Id$

Parameters
data
in, required
float array
The data values.
vel
in, required
float array
The velocities at each data point, in km/s.
brange
in, required
integer
The first channel to use.
erange
in, required
integer
The last channel to use.
mode
in, required
integer
The method to use in finding the returned values.
fract
in, required
float
Used in locating the edges of the galaxy profile. See the documentation for more details.

Keywords
lefthorn
in, optional
float
The location (in channels) of the left (low channel number) peak in the profile. Used only in mode 3. If this or righthorn are not provided, the user is asked to use the cursor to mark these locations.
righthorn
in, optional
float
The location (in channels) of the right (high channel number) peak in the profile. Used only in mode 3. If this or lefthorn are not provided, the user is asked to use the cursor to mark these locations.
rms
in, optional
float
Used in modes 2 and 3 as described above. If this is not supplied, defaults to the stddev of data within the region of interest.
quiet
in, optional
boolean
When set, the results are not printed to the terminal (they are still returned).


Produced by IDLdoc 1.6 on Wed Sep 28 13:27:37 2016