Institut für Astronomie und AstrophysikAbteilung AstronomieSand 1, D-72076 Tübingen, Germany |
readpha
Read PHA-spectrum from a OGIP-conformant PHA-file. The file format has been defined in OGIP memo CAL-GEN 92-002 and 002a.
High energy astrophysics
readpha,count,counterr,rate,back,phafile
phafile - name of the file to read
none
see the list under optional outputs
count : counts in each bin (the PHA channel-number is the index into count); depending on the value of rate either as total photons observed in the bin or as a count-rate counterr : uncertainty of the countrate or photon-number (same units as count) rate : 0 if count is count-rate, 1 if total counts/bin back : 0 if count is total spectrum, 1 if count is background spectrum, 2 if conut is background-subtracted
response : filename of response-matrix telescope : ID of telescope instrument: ID of instrument object : name of observed object ra,dec : position of observed object (degrees!), implies: equinox : equinox os coordinate radecsys : coordinate-frame used date_obs : start-time (dd/mm/yy), UTC, implies time_obs : start-time (hh:mm:ss), UTC date_end : end-time (dd/mm/yy), UTC time_end : end-time (hh:mm:ss), UTC tstart,tstop: the above in JD mjd : ... or in MJD, if this keyword is set filter : filter used exposure : exposure time backfile : filename of background-spectrum backscale : scale-factor of background-spectrum corrfile : filename of correction-file corscale : scale-factor of corrfile effarea : Area scaling factor staterr : systematic statistical error origin : institution where file originates from arf : filename of ancillary file (i.e. effective area) poisson : if set assume Poisson-Statistics (and don't use uncertainty of spectrum); implies that counterr will NOT be used!
none
none
* the routine seems to work, but is a little bit too complex for my feeling so that a proper functioning cannot be guaranteed * Error handling is primitive/non-existent
just read it!!!!!!
not needed
written in 1995 and 1996 by Joern Wilms, [email protected] Version 1.0: 1997/02/14 "Official" release Version 1.1: 1997/06/25, JW Corrected typo in HDUCLAS2 statement Version 1.2: 1999/08/04, JW Keywords now work correctly, tstart and tstop keyword added (computed from date-obs and date-end, NOT taken from header) Version 1.3: 1999/11/10, JW Typo in reading the coordinates Version 1.4: 2000/06/15, JW cosmetic change in documentation $Log: readpha.pro,v $ Revision 1.5 2004/06/05 00:53:24 wilms make poisson a real keyword (was ignored until then). Revision 1.4 2002/07/27 13:54:29 wilms added test whether DATE-OBS defined in SPECTRUM extension (XMM evselect spectra do not have this, unfortunately...)
[Home Page] [Software, Documentation] [IDL Documentation] [Quick Reference] [Feedback]