NAME

niphaquality - apply QUALITY markers to NICER spectrum

USAGE

niphaquality infile noticerange

DESCRIPTION

niphaquality adds QUALITY flags to a NICER spectrum based on a user-defined set of ranges.

The user specifies a set of ranges that should be "noticed", similar to XSPEC's notice command. These ranges are translated into a column called QUALITY in the spectrum file. A value of QUALITY=0 indicates good quality.

Thie parameter noticerange is a comma-separated list of ranges of the form a:b,c:d,e:f and so on. The channels that are considered good are a through b (inclusive), c through d, e through f, and so on. Please note that NICER channels start with 0 and each PI bin is equal to 10 eV. So for example noticerange="22:200,250:800" indicates to notice channel ranges 22-200 (inclusive) and 250-800, which is equivalent to 0.22-2.0 keV and 2.5-8.0 keV.

The QUALITY column is set by default to a value of 1. The quality flag, following the OGIP standard, can have the following values.

PARAMETERS

infile [filename]
Input/output spectral file. The file should be an OGIP-standard type I spectral file. The file is modified in place. If necessary, the QUALITY column is created, and the QUALITY keyword is deleted.

noticerange = "22:1501" [string]
Comma-separated list of channel ranges, as described above.
(badquality = 1) [integer]
The QUALITY value to use. See above for defined values
(chatter = 2) [integer, 0 - 5]
Controls the amount of informative text written to standard output.

EXAMPLES

1. Create the QUALITY column in a spectral file named myspectrum.pha. The channel range of good channels is 22-1000 (inclusive), or about 0.22-10.0 keV.

        niphaquality myspectrum.pha 22:1000

SEE ALSO

nicerl3-spect

niextspect

niphasyserr

LAST MODIFIED

Oct 2022
0good
1defined bad by software
2defined dubious by software
5defined bad by user
-1reason for bad flag unknown