keyword units

William Pence pence at tetra.gsfc.nasa.gov
Mon Jul 14 11:19:16 EDT 1997


    The following convention for encoding the physical units of FITS
keyword values was recently developed during discussions about the data
products for some future missions.  We would appreciate any comments
about this proposal or on any other conventions that may already exist
for encoding keyword units.

     Two routines for reading or writing keyword units using this
convention have already been implemented in the latest version of the
CFITSIO library (V1.25) on a trial basis.  Assuming that the response
is favorable, a corresponding pair of subroutines will be added in the
next release of the Fortran FITSIO library.

-----------------------------------------------------------------------

             Proposed Convention for FITS Keyword Units

                      William Pence (HEASARC)
                      Jonathan McDowell (ASC)
                      Clive Page  (Leicester)

                          14 July 1997

One deficiency of the current FITS Standard is that it does not define
a specific convention for recording the physical units of a keyword
value.  The TUNITn keyword can be used to specify the physical units of
the values in a table column, but there is no comparable convention for
keyword values.  The comment field of the keyword is often used for
this purpose, but the units are usually not specified in a well defined
format that FITS readers can easily recognize and extract.

To solve this deficiency, we propose a convention in which the keyword
units are enclosed in square brackets as the first token in the keyword
comment field; more specifically, the opening square bracket should
immediately follow the slash '/' comment field delimiter and a single
space character.  The following examples illustrate keywords that use
this convention:

1234567890123456789012345678901234567890123456789012345678901234567890123456789
EXPOSURE=               1800.0 / [s] elapsed exposure time
V_HELIO =                16.23 / [km s**(-1)] heliocentric velocity
LAMBDA  =                5400. / [angstrom] central wavelength
FLUX    = 4.9033487787637465E-30 / [J/cm**2/s] average flux

In general, the units named in the IAU(1988) Style Guide are
recommended, with the main exception that the preferred unit for angle
is 'deg' for degrees.

This convention is optional and does not preclude other conventions.

-----------------------------------------------------------------------




More information about the fitsbits mailing list