Institut für Astronomie und AstrophysikAbteilung AstronomieSand 1, D-72076 Tübingen, Germany |
SKY
Determine the sky level in an image using the the procedure MMM
Approximately 10000 uniformly spaced pixels are selected for the computation. Adapted from the DAOPHOT routine of the same name.
SKY, image, [ skymode, skysig, HIGHBAD= , READNOISE= ,/SILENT /NAN, CIRCLERAD= ]
IMAGE - One or two dimensional array
SKYMODE - Scalar, giving the mode of the sky pixel values of the array IMAGE, as determined by the procedure MMM. SKYSIG - Scalar, giving standard deviation of sky brightness
CIRCLERAD - Use this keyword to have SKY only select pixels within specified pixel radius of the center of the image. If CIRCLERAD =1, then the radius is set equal to half the image width. Can only be used with square images. HIGHBAD - scalar value of the (lowest) "bad" pixel level (e.g. cosmic rays or saturated pixels) If not supplied, then there is assumed to be no high bad pixels. /NAN - This keyword must be set to ignore NaN values when computing the sky. Note that the CIRCLERAD, HIGHBAD and /NAN are not exclusive, e.g. one can set both /NAN and CIRCLERAD /SILENT - If this keyword is supplied and non-zero, then SKY will not display the sky value and sigma at the terminal READNOISE - Scalar giving the read noise (or minimum noise for any pixel). Normally, MMM determines the (robust) median by averaging the central 20% of the sky values. In some cases where the noise is low, and pixel values are quantized a larger fraction may be needed. By supplying the optional read noise parameter, MMM is better able to adjust the fraction of pixels used to determine the median.
A grid of points, not exceeding 10000 in number, is extracted from the image array. The mode of these pixel values is determined by the procedure MMM. In a 2-d array the grid is staggered in each row to avoid emphasizing possible bad columns
MMM, DIST_CIRCLE
Written, W. Landsman STX Co. September, 1987 Changed INDGEN to LINDGEN January, 1994 Fixed display of # of points used March, 1994 Stagger beginning pixel in each row, added NSKY, READNOISE, HIGHBAD W. Landsman June 2004 Adjustments for unbiased sampling W. Landsman June 2004 Added /NAN keyword, put back CIRCLERAD keyword W. Landsman July 2004
[Home Page] [Software, Documentation] [IDL Documentation] [Quick Reference] [Feedback]