>  Docs Center  >  Libraries  >  ASTROLIB  >  TBINFO

TBINFO

TBINFO

Name


      TBINFO

Purpose


      Return an informational IDL structure from a FITS binary table header.

Calling Sequence


      tbinfo, h, tb_str, [ERRMSG = ]

Inputs


      h - FITS binary table header, e.g. as returned by READFITS()

Outputs


      tb_str - IDL structure with extracted info from the FITS binary table
              header. Tags include
      .tbcol - starting column position in bytes, integer vector
      .width - width of the field in bytes, integer vector
      .idltype - idltype of field, byte vector
              7 - string, 4- real*4, 3-integer*4, 5-real*8
      .numval - repeat count, 64 bit longword vector
      .tunit - string unit numbers, string vector
      .tnull - integer null value for the field, stored as a string vector
                so that an empty string indicates that TNULL is not present
      .tform - format for the field, string vector
      .ttype - field name, string vector
      .maxval- maximum number of elements in a variable length array, long
              vector
      .tscal - pointer array giving the scale factor for converting to
                physical values, default 1.0
      .tzero - pointer array giving the additive offset for converting to
                physical values, default 0.0
      .tdisp - recommended output display format
      All of the output vectors will have same number of elements, equal
      to the number of columns in the binary table.
      The .tscal and .tzero values are stored as pointers so as to preserve
      the individual data types (e.g. float or double) which may differ
      in different columns. For example, to obtain the value of TSCAL for
      the third column use *tab_str.tscal[2]

Optional Input Keyword


      /NOSCALE - if set, then the TSCAL* and TZERO* keywords are not extracted
            from the FITS header, and the .tscal and .tzero pointers do not
            appear in the output structure.

Optional Output Keyword


        ERRMSG = if present, then error messages are returned in this keyword
            rather than displayed using the MESSAGE facility

Procedures Used


      SXPAR()

Notes


      For variable length ('P' format) column, TBINFO returns values for
      reading the 2 element longward array of pointers (numval=2,
      idltype = 3, width=4)

History


      Major rewrite to return a structure W. Landsman August 1997
      Added "unofficial" 64 bit integer "K" format W. Landsamn Feb. 2003
      Store .tscal and .tzero tags as pointers, so as to preserve
      type information W. Landsman April 2003
      Treat repeat count for string as specifying string length, not number
          of elements, added ERRMSG W. Landsman July 2006
      Treat logical as character string 'T' or 'F' W. Landsman October 2006
      Added NOSCALE keyword W. Landsman March 2007
      Make .numval 64 bit for very large tables W. Landsman April 2014



© 2019 Harris Geospatial Solutions, Inc. |  Legal
My Account    |    Store    |    Contact Us