NAME

pcaprepfile1 - Prepare deadtime quantities for Standard1 file


USAGE

         pcaprepfile1 infile hkfiles dtfile ...

DESCRIPTION

pcaprepfile1 does standard preparation activities for one PCA Standard1 data file. It represents the best practices recommended by the RXTE PCA team for preparing Standard1 for scientific analysis.

The prerequisites for this tool are:

       * one Standard1 file ('infile')
       * list of RXTE housekeeping files ('hkfiles')

When complete, pcaprepfile1 will produce:

       * Standard1 file with dead-time quantities ('dtfile')

This file parallels the operation of pcaprepfile2. However, unlike that task, pcaprepfile1 does not estimate background from a Standard1 file since that is not possible. It simply computes dead-time realted quantities.

There are several settings that the user can alter, but the user is recommended to use the defaults except with good reason. The defaults will compute dead-time related quantities for each PCU and filter out known times of bad data (see pcadeadcalc1).

After running this tool, the 'dtfile' file is suitable for use with pcaextlc1 (recommended).

Calculating dead-time quantities is optional. If dtfile='NONE' then they are not computed. However, the PCA team recommends to produce the dead-time calculations, and to use the dead-time quantity files for all subsequent analysis. (i.e. ignore the original Standard1 file, and use the dtfile instead).


PARAMETERS

infile [filename]
Name of single input Standard1 file.

hkfiles [string]
Specify a list of PCA housekeeping files, i.e. the FH5* files in the pca subdirectory. This can either be a comma-separated list, or a @filename.txt where filename.txt contains a list of files. There must be exactly five files specified because there are five PCUs.

dtfile [string]
Upon sucessful completion, the name of the output file containing Standard1 data with dead-time quantities. The PCA team recommends to use this file for subsequent analysis. A value of 'NONE' indicates to not create this file.

(breakfile = 'CALDB') [string]
Set to a file name which contains PCU breakdown GTI information. If set to 'CALDB', then the task will query CALDB for the appropriate file. If set to 'NONE', then no PCU breakdown processing will be done (not recommended).

(zero_bad = YES) [boolean]
If set, then the task will set the Xenon counts to zero any PCU which is considered to be in a "bad" science state at the given time, as described above. If not set, then Xenon counts are not changed.

(transition_bad = YES) [boolean]
If set, then PCU high voltage transitions are considered "bad" science times (+/- 16 sec). If not set, then only PCU high voltage "off" is considered bad.

(propane_bad = YES) [boolean]
If set, then PCUs are considered "bad" if their propane layers are gone. If not set, then the propane layer status is not considered.

(cleanup = yes) [boolean]
Clean up scratch files?

(chatter = 1) [int] range 0-5
Verbosity level of output

(clobber = no) [boolean]
Overwrite output file?

(history = yes) [boolean]
Write standard HEADAS parameter history into output file?


EXAMPLES

         # Create list of PCA housekeeping files    
         ls FH5* > hkfiles_files.lis
     
         # Run on FS4a_file.gz
         pcaprepfile1 infile=FS46_file3.gz \
           hkfiles=@hkfiles_files.lis \
           dtfile=FS46_file3_DT
     
         # Outputs are FS46_file3_DT


CAVEATS

PCA Standard1 mode does not contain all the quantities to compute exact dead time or background estimates. Instead, some heuristic estimates are required. This may lead to some small errors in background subtraction or dead-time correction.

The user is strongly recommended to use an updated RXTE Calibration database (CALDB), and to set breakfile=CALDB, modelfile=CALDB, saahfile=CALDB.

The user is strongly recommended to compute the files with dead-time quantities and use those for downstream processing.


BUGS

Please report problems to xtehelp@athena.gsfc.nasa.gov.


SEE ALSO

pcadeadcalc1, pcaprepobs1

CATEGORY

Jan95 ftools.xte