FXTSoft v2.0 documentation
fxtrmfmerge help
Command help for fxtrmfmerge in the FXTSoft v2.0 release.
NAME
fxtrmfmerge -- Merge multiple EP/FXT RMF response filesUSAGE
fxtrmfmerge specfiles=@pha.lst outfile=merged.rmf fxtrmfmerge inputmode=spec specfiles=@pha.lst outfile=merged.rmf weightmode=equal fxtrmfmerge inputmode=spec specfiles=@pha.lst outfile=merged.rmf weightmode=coverage fxtrmfmerge inputmode=rmf rmffiles=@rmf.lst outfile=merged.rmf weightmode=weights weights=@wgt.lst fxtrmfmerge inputmode=rmf rmffiles=@rmf.lst arffiles=@arf.lst exposures=@exp.lst outfile=merged.rmf weightmode=arf_exposure
DESCRIPTION
fxtrmfmerge combines compatible EP/FXT RMF files using scalar weights,
or energy-dependent ARF-times-exposure weights in weightmode=arf_exposure.
In inputmode=spec, the task
uses each PHA spectrum observation time and detector information to resolve the
corresponding CALDB RMF with the same rules used by fxtrmfgen. In
inputmode=rmf, the task merges explicitly supplied RMF files. MATRIX and
EBOUNDS energy columns are normalized to keV (missing units default to keV). The
input channel grid, finite non-negative MATRIX values, sparse group spans, and
DETCHANS consistency are validated before an OGIP-classified, checksummed
RMF is published atomically. CALDB-selected MATRIX extension numbers are retained.
Scalar modes (exposure, coverage, equal, and
weights) accept only numerically identical RMFs with positive contribution
by default (allow_scalar=no). Different RMFs with positive contribution
are rejected; numerically identical responses are preserved exactly, including when
zero-weight noncontributors are present. Set allow_scalar=yes only for a
diagnostic scalar average: the task warns and stamps the output MATRIX with
SCALDIAG=T, and the result is not for science fitting.
PHA lookup prefers absolute SRCGTI/GTI, including a
single GTI, over inherited date headers. It checks CALDB validity boundaries,
exact GRADE selections and the selected CAL_XNO. Each input PHA must
resolve to one numerical RMF; a PHA spanning different RMFs must first be split
into the corresponding observation/calibration intervals.
For science stacking with different RMFs and ARFs, use
weightmode=arf_exposure. At energy E its weights are
t_i*A_i(E)/sum_j(t_j*A_j(E)); pair the result with the matching
exposure-weighted ARF, using the same inputs and exposures. This per-observation ARF
path is unchanged by allow_scalar. Scalar weighting alone is not generally
equivalent. Alternatively, fxtsrcproducts combines the full
ARF*RMF responses and records the resulting RSP in the PHA. Its science
PHA continues to reference that full RSP; any scalar merged RMF is only a diagnostic
sidecar and does not replace the full response.
PARAMETER SUMMARY
| Parameter | Default / values | Summary |
|---|---|---|
inputmode | spec | Input mode: spec or rmf |
specfiles | required for inputmode=spec | Input spectrum files, comma-separated or @listfile |
rmffiles | required for inputmode=rmf | Input RMF files, comma-separated or @listfile |
outfile | required | Output merged RMF file |
weightmode | exposure | Weight mode: exposure, coverage, equal, weights, or arf_exposure |
weights | required for weightmode=weights unless rmffiles list has two columns | Weights, comma-separated or @listfile |
arffiles | required for weightmode=arf_exposure | ARF files used by weightmode=arf_exposure |
exposures | required for weightmode=arf_exposure in inputmode=rmf unless inline weights are supplied | Exposure weights used by weightmode=arf_exposure |
allow_scalar | no | Allow scalar averaging of distinct positive-contribution RMFs for diagnostics only (not for science fitting; yes/no); warns and stamps SCALDIAG=T |
caldb_root | NONE | Optional CALDB root override |
caldb_config | NONE | Optional CALDB config override |
clobber | yes | Overwrite existing output file (yes/no) |
verbose | 1 | Logging verbosity: 0=warning/error, 1=normal info, 2=debug |
mode | ql | Query/learn mode |
PARAMETERS
- (inputmode=spec) [string]
- Input mode:
specto resolve RMFs from PHA files, orrmfto merge explicit RMF files. - specfiles [string]
- Input PHA spectra, comma-separated or provided through an
@listfile. Required wheninputmode=spec. - rmffiles [string]
- Input RMF files, comma-separated or provided through an
@listfile. Required wheninputmode=rmf. Forweightmode=weights, an@listfilemay contain two columns: file name and weight. - outfile [file name]
- Name of the merged RMF output file.
- (weightmode=exposure) [string]
- Weighting method:
exposure,coverage,equal,weights, orarf_exposure. Exposure and coverage weighting are available ininputmode=spec. Coverage weighting first uses source-validSRCGTIintervals, then ordinaryGTIintervals, thenCOVERAGE.DT, and finally the PHAEXPOSUREkeyword. GTI andCOVERAGE.DTunits are converted to seconds and overlapping GTI intervals are counted once. Malformed, empty or reversed GTIs are errors, not fallback triggers.arf_exposureweights each RMF by the matching ARF response and exposure list. - (weights=NONE) [string]
- Explicit weights, comma-separated or provided through an
@listfile. This parameter is required whenweightmode=weightsunless thermffiles@listfilecontains two columns: file name and weight. - (arffiles=NONE) [string]
- ARF files, comma-separated or provided through an
@listfile. Required whenweightmode=arf_exposure. - (exposures=NONE) [string]
- Exposure values, comma-separated or provided through an
@listfile. Required whenweightmode=arf_exposureininputmode=rmfunless the RMF list provides inline weights. Ininputmode=spec, omitted exposures are read from the input spectra. - (allow_scalar=no) [boolean]
- Scalar merge guard. The default
norejects numerically different RMFs with positive contribution in scalar modes (exposure,coverage,equal, andweights). Numerically identical RMFs are preserved exactly, including when zero-weight inputs are noncontributors. Setyesonly for a diagnostic scalar average: the task warns and stampsSCALDIAG=T; the output is not for science fitting. This option does not alterweightmode=arf_exposure, which uses per-observation ARFs and exposures. The opt-in must be specified on each invocation; a saved PFILE value ofallow_scalar=yesis ignored when the command omits the option. - (caldb_root=NONE) [string]
- Optional CALDB root override used when resolving RMFs from spectra.
- (caldb_config=NONE) [string]
- Optional CALDB configuration override used when resolving RMFs from spectra.
- (clobber=yes) [boolean]
- Overwrite an existing output file. The output cannot alias any input PHA,
RMF or ARF, even with
clobber=yes.
CALDB RESPONSE NODES
In inputmode=spec, a matching RMFNODE1 family is
materialized for each PHA in a task-owned temporary directory, using the same
GTI mean, exact grade scope, validity checks and endpoint HOLD policy as
fxtrmfgen. The task neither writes a cache into CALDB nor modifies
the input PHA. Missing RMFNODE records retain ordinary MATRIX lookup; malformed
or unsupported families fail explicitly.
Response-node materialization does not change the merge weighting rules.
For distinct responses used in science fitting, provide each observation's ARF
and exposure with weightmode=arf_exposure. A PHA spanning a physical
calibration boundary must first be split into valid per-epoch spectra.
EXAMPLES
fxtrmfmerge specfiles=@pha.lst outfile=merged.rmf fxtrmfmerge inputmode=spec specfiles=@pha.lst outfile=merged.rmf weightmode=equal fxtrmfmerge inputmode=spec specfiles=@pha.lst outfile=merged.rmf weightmode=coverage fxtrmfmerge inputmode=rmf rmffiles=@rmf_weights.lst outfile=merged.rmf weightmode=weights fxtrmfmerge inputmode=rmf rmffiles=@rmf.lst arffiles=@arf.lst exposures=@exp.lst outfile=merged.rmf weightmode=arf_exposure
Manual page updated
2026-11-04