NAME
ftabkey -- Copy a FITS table element to a FITS header keyword.
USAGE
ftabkey tblfile[ext#] column row fitsfile[ext#] keyword
DESCRIPTION
This task copies the value of an element in a FITS table extension
(either an ASCII or a binary table) to the value of a keyword in the
header of the same or a different FITS file. An error message is
printed if the table element is undefined. By default, only values of
existing keywords may be modified, but if the hidden parameter 'add' is
set to "yes", then this task will add a new keyword to the header if it
doesn't already exist.
PARAMETERS
- tblfile [file name]
-
The name, including extension and extension number in square brackets (e.g.,
myfile.fits[3]) of the input FITS table to be read. By default the first
extension will be read.
- column [string]
-
Column name in table to be read. (Name is not case sensitive).
- row [integer]
-
Row number in table to be read.
- fitsfile [file name]
-
The name, including extension and extension number in square brackets,
of the FITS header to be modified.
If this name is blank then the keyword will be written to the header
of the table that was read.
- keyword [string]
-
Name of header keyword to be modified (or added if it does not exist and
if the 'add' parameter = 'yes'). The name is not case sensitive.
- (element = 1) [string]
-
If the column contains an array of values (i.e., a vector column in a binary table)
then this is the number of the element within the vector to be read. If the
column contains an array, specify all dimensions: 23,2.
- (add = no) [boolean]
-
Is it OK to create a new keyword if it does not currently exist?
EXAMPLES
1. Copy the value in the 10th row of the 'WAVELENGTH' column in the
FITS file myfile.fits[4] to a keyword called WAVEVAL in the primary
header in the file datfile.fits:
ft> ftabkey myfile.fits[4] wavelength 10 datfile.fits[0] waveval
BUGS
SEE ALSO
ftlist, fthedit, ftedit, ftkeypar, heatools. fv, the interactive FITS file
editor, can also be used to copy a table element to a header keyword.
CATEGORY
Jun92 ftools.futils