.help bodfluxhis May2004 ftools.gro
.ih
NAME
bodfluxhis --  Extract light curve from BATSE Earth occultation data for screen disply or file output.
.ih
USAGE
bodfluxhis bodfil #vp #vp2 binsz outfil_dir data_dir fitsf FitsFname fitsWtFlg viewlog device
.ih
DESCRIPTION
The BODFLUXHIS program constructs a light curve from BATSE occultation data FITS file (NHIS type), for user specified time intervals. The data are automatically screened on the basis of the one-bit quality/status flags contained in column 21 of the flux history table. Data are displayed in the form of Flux and flux uncertainty vs. time (in TJD). Displays are made to the screen or a printable graphics file. The data can also be saved to a simple ASCII file. This  will be useful for example, for data selection for spectral extraction using the "bod2pha" routine. In addition, a simplified FITS light curve file can be produced as output (covering either the selected viewing period range or the full contents of ths input file(s). This FITS light curve can then be analyzed in more detail using the XRONOS temporal analysis package.
.sp
A CGRO viewing Period number can be obtained by ftool bodgetvp, and ignore the decimal point, take integer. For instance, take 805.5 as 8055. Alternatively, just examine the first table extension of the file $LHEA_DATA/vp_list.fits, or view the CGRO timeline on the WWW at <http://cossc.gsfc.nasa.gov/timeline/index.html>.

.sp
The  BATSE Earth occultation database,  and related information are available through the HEASARC, or on the web at: <ftp://cossc.gsfc.nasa.gov/compton/data/batse/occultation> (also see <http://cossc.gsfc.nasa.gov/batse/index.html>). A complete description of the BATSE Earth-Occultation analysis is given in the ApJ Supplements article, Harmon, et al 2004 (astro-ph/0404453).
.ih
PARAMETERS
.ls bodfil [string]
The name of BATSE occultation data FITS file (NHIS type). Either a file name or a file list start with a prefix @.
.le
.ls vp [integer]
A CGRO viewing Period number of initial view period to be examined
.le
.ls vp2 [integer]
A CGRO viewing Period number of final view period to be examined
.le
.ls binsz [integer]
desired size of each bin in sample numbers
.le
.ls outfil_dir [string]
the directory to hold the log file and plot files
.le
.ls data_dir [string]
the directory to hold the input files, and the newly created Fits file
.le
.ls fitsf [string]
option to write a Fits file
.le
.ls FitsFname [string]
name of Fits file to be created
.le
.ls fitsWtFlg [integer]
flag to write a Fits file, 0 for selected #VP data, 1 for overall data
.le
.ls viewlog [string]
optional string to help view of log file
.le
.ls device [string]
optional string to display curve light plot. Either /xwin, or /ps, or /gif, or /jpg
.ih
EXAMPLES
.sp
Display light curve from BATSE occultation FITs file from file list "cygx-1.list" with binsz 2 and CGRO viewing periods 8090 and 8150. All the input files are put in the directory data_dir.
.sp   
This generates three output files:
.sp
1. plot file: light curve vs. TDJ for either selected VP, or the input FITs,depending the selected options on a interactive men
.sp
2. A FITs file "new.fits" with light curve binary table will be generated if fitsf is set to be "yes".
.sp
3. write the name of generated FITs file into the exist log file flux.log in the directory "outfil_dir"
.sp
.sp
The parameter file input for this case would be:
.sp
.nf
name of directory for data files:[]data
name of BATSE occultation data file (NHIS type):[]@cygx-1.list
the size of each bin:[]2 
ID of initial viewing period:[]8090 
ID of final viewing period:[]8150
Do you wish to write a Fits file?(yes/no)[]yes
name of Fits file to be created:[]new.fits
0 for selected #VP data, 1 for over all data(0/1)[]0
name of directory for logs:[]log 
Do you wish to view a list of existing log file?(yes/no)[]no 
name of device for ploting(/xwin,/ps,/gif)[]/xwin     
.fi
.sp
FILES NEEDED
.sp
BATSE Earth occultation flux history files, found at <ftp://cossc.gsfc.nasa.gov/compton/data/batse/occultation>, then placed in the directory pointed to by the "data_dir" parameter, e.g. data_dir/cygx-1_10351-10470_nhis.fits. The Viewing Period list file "vp_list.fits" which is located in the $LHEA_DATA directory is also required. Some (optional) related files can be found in <ftp://cossc.gsfc.nasa.gov/compton/data/batse/misc>, e.g. batse_obs_plan.fits, in that directory which contain additional details regarding CGRO's pointing history.
.ih
BUGS
.ih
SEE ALSO
bodgetvp, bod2rmf, bod2pha, groview
.endhelp
