listasn


This task lists the members of a 3-column association table to a simple ASCII file. It is designed to make it easier to inspect the members of an association without having to use IRAF to read the association table.

The command takes one required argument (a filespec matching one or more FITS files) and one optional argument (the name of an output directory OR a qualifier and the name of an output file OR the qualifier for stdout). If the second argument is not provided, the name of each output file will be the same as each input file with the extension changed to .tlis, and the output directory set to the current working directory.

Usage:

> listasn input_filespec [output_directory | -f output_filespec | -s]

Context

Inputs

The input is a filespec for one or more association FITS files. Any path can be provided. Wildcards are supported.

Outputs

The output consists of ASCII text for each input file containing three columns: the name of the associated member, the type of that member, and whether that member is present in the association (T/F).

Examples

> listasn

            This example will display the command syntax.

> listasn /directory/rawdata/o3s40705m_asn.fits

This example will produce a file called o3s40705m_asn.tlis in the current working directory.

> listasn /directory/rawdata/*_asn.fits

This example will produce output files called *_asn.tlis in the current working directory for each FITS association table matching the filespec provided.

> listasn *_asn.fits $asn_dump_dir

This example will produce output files called *_asn.tlis, one for each FITS association table in the current directory. The output files will be written to the directory defined by the variable asn_dump_dir.

> listasn o3s40705m_asn.fits -f $mydir/raw.lis

This example will produce a file called raw.lis in the directory specified by the variable mydir.

> listasn o3s40705m_asn.fits -s

This example will send the table to stdout where it can be observed interactively or piped to another process.

Here is some sample output from an ASN table:

 
N44L02KMM EXP-TARG T
N44L02KNM EXP-TARG T
N44L02020 PROD-TARG T

 

See Also

The command procedure opus_definitions_dir:HT_PDQ_NIC_STI.com uses this utility to dump ASN tables. Take a look at that procedure to see how to parse the ASCII output file from within a command procedure.