NAME
burstt90t50 - Calculate the T90 and T50 intervals and write results to GTI output file.
USAGE
burstcalc lcfile gtifile outfile
DESCRIPTION
burstcalc reads a lightcurve file and the GTI file containing the start and stop of the
burst interval and calculates the T90 and T50 of the burst.
The input lightcurve is expected with columns named TIME and RATE or COUNTS, containing the time
in second and rate as count/s or counts otherwise the parameters tcol and rcol
may be used to specify the names of the columns.
The input GTI is expected to have at least one extension that is intepreted containing the start
and stop of the burst. If the GTI file is the output from cgbm_bstgti or
burstfinder, it contains
multiple extensions and the task will read the extension with the keyword GTITYPE set to TOT_GTI.
The task calculates a cumulative intensity curve using the rates or counts in the input lightcurve
that are within the GTI burst interval normalized by the total count/rate in that interval. .
The T90 is calculated using the cumulative counts between 5% and 95% limits ancd the
T50 between 25% and 75%
limits. The corresponding start and stop for the T90 and T50 intervals are
written to an output GTI file.
If the input GTI file is a burstfinder style GTI file with six extensions, the
values for start
and stop of the T90 and T50 are written in the first and second extensions respectively,
and the additional four are copied from the input GTI. Otherwise, the output
GTI file contains only T90 and T50 extensions.
PARAMETERS
- lcfile [filename]
- The input lightcurve file.
- gtifile [filename]
- The input GTI file. If no extension is specified, and gtifile is a standard
burstfinder output GTI, the total interval is read from the 4th extension
automatically; otherwise it reads the first extension.
- outfile [filename]
- The output GTI file. If set to NONE or left blank, the new GTI information will
overwrite the input GTI file (This requires clobber to be 'yes').
If the input gtifile was created by burstfinder), the outfile
contains the T90 and T50 extensions calculated from this task and will copy the additional
four GTI extensions (peak, total, pre- and post-burst) from the input gtifile.
Otherwise, the task outputs in outfile just T90 and T50 extensions calculated
by this task.
- (rcol = "RATE") [string]
- Column in the input lightcurve containing count or rate information.
Default is "RATE".
- (tcol = "TIME") [string]
- Column in the input lightcurve containing time information.
Default is "TIME".
- (cleanup = yes) [boolean]
- Remove all temporary files on completion if set to yes (default). Not used in this tool.
- (clobber = no) [boolean]
- Overwrites pre-existing output files if set to yes. Default is no.
- (chatter = 1) [integer, 0 - 3]
- Chatter level for output. Set to 0 to suppress output, or to 1 (default),
2, or 3 for increasing the chatter of the output.
- (debug = no) [boolean]
- Diagnostic output is printed out on the screen if set to yes
(yes/[no]).
- (logfile = !DEFAULT) [string]
-
Log filename. If set to DEFAULT, uses the name of the task (i.e. burstcalc.log)
and, if preceded by "!" clobber any pre-existing log file. If set to
NONE, no log file is created. Default is "!DEFAULT"
- (history = yes) [boolean]
- If set to yes, record the task parameters run in the header of the output file in the
HISTORY keywords. Not enabled in this current version.
- (mode = ql) [string ql|hl|q|h]
- Mode to query the parameter file. Acceptable values include: "ql" (query and learn/remember),
"hl" (hidden and learn/remember), "q" (query but don't remember), "h" (hidden).
EXAMPLES
-
Define the T90 and T50 intervals for a burst found by burstfinder by
reading the background subtracted rate column RATE and time column TIME from the
lightcurve "cgbm_20180411_sgm_083733_1h_user.lc", and the total burst interval
contained in the GTI file "cgbm_20180411_sgm_083733_1h_dur.gti".
Because the input GTI file is a standard burstfinder GTI (has six
extensions to hold T90, T50, peak, total, and pre- and post-burst intervals),
the code reads the total burst interval(s) from the 4th extension.
The resulting output GTI will be written to the input GTI, clobbering it, with the
new T90 and T50 in the first two extensions, and the following four extensions copied
into the revised "cgbm_20180411_sgm_083733_1h_dur.gti" file.
burstcalc lcfile=cgbm_20180411_sgm_083733_1h_user.lc gtifile=cgbm_20180411_sgm_083733_1h_dur.gti outfile=NONE rcol=RATE tcol=TIME clobber=yes
-
Define the T90 and T50 intervals using the columns TIME and RATE in "example.lc"
in its first extension, and the total burst interval as defined in the first
extension of the file "example_burst.gti". Write the T90 and T50 GTIs found to
a new file "example_t90t50.gti" which will have two extensions containing the
T90 and T50 results in respective order.
burstcalc lcfile=example.lc+1 gtifile=example_burst.gti+1 outfile=example_t90t50.gti rcol=RATE tcol=TIME clobber=no
CAVEUATS
If rcol is set to a column containing negative rate (or count) values (e.g. background
subtracted rate),
only positive values are considered when computing the
the T90 and T50 intervals.
SEE ALSO
burstfinder - Find the total burst interval
LAST MODIFIED
February 2025 (burstt90t50 v0.3b)