### JS9 Imexam Plugins

These tasks perform various types of image analysis using a rectangular box surrounding the selected region. That is, the actual region shape is ignored and the analysis reflects a rectangular section of image pixels. The selected section can be rotated for box, ellipse, and line regions. For a line region, the width is the length of the line, while the height is set to the value of the JS9.globalOpts.imexamLineHeight parameter (default is 1).

### Region Statistics

A rectangular box of image pixels is selected and some statistical values are computed from the data.

> #### Notes

> - Totcounts and bscounts

>   Totcounts are the total counts in the box region, while bscounts has the calculated background (see below) subtracted from the total.

> - Background and Noise

>   The background and noise are obtained from the outer 4 pixel-wide perimeter of the selected region. The background value is the median value of this area and the noise value is the RMS.

> - Centroid

>   The centroid is obtained by locating the brightest 9 pixel box and computing the centroid of the background subtracted data about this point.

> - FWHM

>   The FWHM is estimated from the image moments about the centroid, assuming a Gaussian distribution.

### X and Y Projection Plot

A rectangular box of image pixels is selected and the projection along the region's X (width) or Y (height) axis is plotted. The sum, average, or median of the projected pixels may be selected.

### Radial Profile

A rectangular box of image pixels is selected and the pixels values are plotted against their respective radii. A Gaussian is fit to the radial profile data and the result is also plotted. The fitted results of the 4 parameter fit are displayed with the plot.

The center pixel from which the radii are computed is determined from the background subtracted centroid taken about the brightest 9 pixels in the data (same centroid as is displayed in the region stats plugin).

### Pixel Value Histogram

A rectangular box of image pixels is selected and a histogram of the values is plotted. The selected pixels are binned into 250 bins between the minimum and maximum value found in the selected region.

### Encircled Energy

A rectangular box of image pixels is selected and background subtracted. The analysis radius is determined from the region as follows:

- circle: region radius
- annulus: max annulus radius
- box: half the average height an width
- ellipse: average axis radius
- polygon: half the average of the height and width of polygon bounding box

The values within the analysis radius are binned in 1 pixel radial bins. The bins are normalized by the sum of all pixels and the result is plotted.

The background is obtained as the median from the outer 4 pixel wide perimeter of the selected region.

The center pixel from which the encircled energy is computed is determined from the background subtracted centroid taken about the brightest 9 pixels in the data (same centroid as is displayed in the region stats plugin).

The 50 and 80 percent encircled energy points are displayed over the plot.

### 3d Surface Plot

A rectangular box of image pixels is selected and plotted as a surface.