borderstat (Aug2004) |
rjtools
|
borderstat (Aug2004) |
borderstat
borderstat - return statistics in an image border as task parameters
borderstat image border [lower] [upper] [binwidth] [verbose] [label]
- image = ""
- Name of image to compute image statistics for.
- border = 1
- Width (in pixels) of the image border to use for computing the image
statistics.
- lower = INDEF
- Only consider pixels with values larger than 'lower'. All pixels are above
the default value.
- upper = INDEF
- Only consider pixels with values smaller than 'upper'. All pixels are below
the default value.
- binwidth = 0.1
- Bin width in units of the standard deviation of the histogram bins used for
computing the midpoint (median) and the mode.
- verbose = no
- Print the resulting statistics to the standard output (screen)?
- label = yes
- Label the output column headers when 'verbose = yes'?
- (npix) [int]
- Parameter returning the number of pixels in 'image' with values between
'lower' and 'upper' used to compute the image statistics
- (mean) [real]
- Parameter returning the average pixel value
- (midpt) [real]
- Parameter returning the midpoint, an estimate of the median pixel value
- (rmode) [real]
- Parameter returning an estimate of the modal pixel value
- (stddev) [real]
- Parameter returning the standard deviation if 'npix' > 1 and 0. otherwise.
- (min) [real]
- Parameter returning the minimum pixel value
- (max) [real]
- Parameter returning the maximum pixel value
- (sum) [real]
- Sum of all pixel values between 'lower' and 'upper'
Task based on 'imutil.imstatistics' to return image statistics in a 'border'
pixels wide strip all around the perifery of an image as task parameters
so that they may be accessed by other procedures. An image extension and/or
image section may be supplied as part of the image name (see 'rpparse')
Pixels with values outside the range defined by 'lower' and 'upper' are not
considered in computing the statistics.
To determine the statistics of the background in an image where the central
parts contain an object sufficiently bright and extended to affect the
statistics of the full image (or in this example: full image section -- the
border here is the border of the section, not of the full image):
rj> borderstat N5888B.fits[175:350,175:350] 10 lo=INDEF up=INDEF verb+
npix mean midpt mode stddev min max sum
6640 150.2901 150.1182 149.6910 8.267945 121.9126 208.0715 997926.3
while the statistics in the full image (image section) are:
rj> imgstat N5888B.fits[175:350,175:350] lo=INDEF up=INDEF verb+
npix mean midpt mode stddev min max sum
30976 173.8457 154.9907 151.8420 81.55000 115.9042 5207.035 5385044.
imstatistics, iterstat, imgstat, chkimg, rpbuild