NAME · USAGE · DESCRIPTION · PARAMETERS · EXAMPLES · BUGS · REFERENCES
HELP · SEE_ALSO
phay - Pulse height analysis for FOS observations at different thresholds.
phay input intphd difphd fitphd table
This routine does a pulse height analysis (PHA) on a set of
Faint Object Spectrograph (FOS) observations taken at different
The input observations give the integral pulse height distribution (PHD)
for each of the 512 channels. The integral PHD is differentiated using
the negative of the
slope of a least squares line through a user-specified number of
threshold levels, centered at each threshold level. A least squares
(i.e., a Guassian distribution with a polynomial baseline) is
performed for each of the
512 channels. From the coefficients of the fits, appropriate threshold
levels for each of the channels can be computed using the tcalc task
in the tools package.
- input [file name template]
- Input files containing FOS observations at different discriminator
thresholds. These observations must be in ascending threshold order with
a constant delta threshold between observations. The data must be vectors
of length 512---overscanning is not permitted for threshold data.
If any input observation uses a different exposure time than was used
for the other files, it
must be normalized (by dividing by exposure time) before running the
- intphd = "intphd" [file name]
- Name of the output file that will contain the integral pulse
height distributions for each of
the 512 diodes. These distributions are organized as a two-dimensional image
of size j,i where j is the threshold position and runs from 1 to the
number of files in the input data, and i is the diode number running
from 1 for diode 0 to 512 for diode 511.
- difphd = "difphd" [file name]
- Name of the output file that will contain the differential pulse
height distribution for each
of the 512 diodes. It is a two-dimensional image file having the
same format as intphd.
- fitphd = "fitphd" [file name]
- Name of the output file that will contain the least squares fit
to the differential pulse height
distribution. It is a two-dimensional image file having the same format
- table = "phay" [file name]
- Name of the output table containing results of the least squares fit for each
of the diodes. This table has 512 rows (one per diode), and the following
'CENTER' - Center of the fitted Gaussian distribution (double).
'PEAK' - Peak value of the fitted Gaussian (double).
'SIGMA' - Sigma (width) of the fitted Gaussian (double).
'A0' - Constant term of the polynomial baseline (double).
'A1' - Linear term of the polynomial baseline (double).
'A2' - Quadratic term of the polynomial baseline (double).
'RMS' - RMS of the fit (i.e., root mean square of the difference
of the differential PHD and its fit) (double).
- t= 50.0 [real, min=1.0, max=255.0]
- Threshold level of the first observation in input.
- delt = 1.[real, min=1.0, max=200.0]
- Increment in threshold levels between the files in input.
- center = 175. [real, min=0.0, max=256.0]
- Initial guess for the center of the Gaussian fits used by the non-linear
least squares fitting process.
- sigma = 15.[real, min=1.0, max=50.0]
- Initial guess for the sigma of the Gaussian fits.
- niter = [integer, min=1, max=100]
- Number of non-linear least squares iterations.
- tmin = 125.[real, min=0.0, max=255.0]
- Minimum threshold level to fit. Only threshold levels between tmin
and tmax are included in the fit process.
- tmax = 255.[real, min=0.0, max=255.0]
- Maximum threshold level to use in the fit.
- order = [integer, min=0, max=2]
- Order of the polynomial baseline of the least squares fit.
- fwidth = [integer, min=3, max=29]
- Width of the differential smoothing function. The negative
of the slope of the line
of fwidth thresholds, centered at each threshold, is used as the
differential pulse height distribution value.
- hmin = 50.[real, min=0.0]
- Minimum pulse height distribution value for the peak.
The peak is sought in a 25 point region around
the guess for center. If no value higher than hmin is found, then no fit is
attempted. The hmin parameter should be used to avoid fitting dead channels.
1. Perform a PHA on the data observations ybw001 through ybw100
using the default parameters, except for the minimum
fit threshold, which is set to 140.0.
fo> phay ybw* intphd difphd fitphd outtab tmin=140.0
Howard Bushouse, STSDAS
For assistance using this or any other tasks, please contact firstname.lastname@example.org
or call the help desk at 410-338-1082.
Source Code · Search Form · STSDAS
Maintained by the Science Software Group at STScI
This file last updated on 15 Sep 2011