[AIT logo]

Institut für Astronomie und Astrophysik

Abteilung Astronomie

Sand 1, D-72076 Tübingen, Germany
[Uni logo]


FITS_INFO Source code in fits_info.pro

FITS_INFO

Name
     FITS_INFO
Purpose
     Provide information about the contents of a FITS file
Explanation
     Information includes number of header records and size of data array.
     Applies to primary header and all extensions.    Information can be
     printed at the terminal and/or stored in a common block
     This routine is mostly obsolete, and better results can be usually be
     performed with FITS_HELP (for display) or FITS_OPEN (to read FITS
     information into a structure)
Calling Sequence
     FITS_INFO, Filename, [ /SILENT , TEXTOUT = , N_ext = ]
Input Parameters
     Filename - Scalar string giving the name of the FITS file(s)
               Can include wildcards such as '*.fits'.   In IDL V5.5 one can
               use the regular expressions allowed by the FILE_SEARCH()
               function.     One can also search gzip compressed
               FITS files.
Optional Input Keywords
     /SILENT - If set, then the display of the file description on the
                terminal will be suppressed
      TEXTOUT - specifies output device.
               textout=1        TERMINAL using /more option
               textout=2        TERMINAL without /more option
               textout=3        <program>.prt
               textout=4        laser.tmp
               textout=5        user must open file, see TEXTOPEN
               textout=7       append to existing <program.prt> file
               textout = filename (default extension of .prt)
               If TEXTOUT is not supplied, then !TEXTOUT is used
Optional Keyword Output
       N_ext - Returns an integer scalar giving the number of extensions in
               the FITS file
Common Blocks
       DESCRIPTOR =  File descriptor string of the form N_hdrrec Naxis IDL_type
               Naxis1 Naxis2 ... Naxisn [N_hdrrec table_type Naxis
               IDL_type Naxis1 ... Naxisn] (repeated for each extension)
               For example, the following descriptor
                    167 2 4 3839 4 55 BINTABLE 2 1 89 5
               indicates that the  primary header containing 167 lines, and
               the primary (2D) floating point image (IDL type 4)
               is of size 3839 x 4.    The first extension header contains
               55 lines, and the  byte (IDL type 1) table array is of size
               89 x 5.
               The DESCRIPTOR is *only* computed if /SILENT is set.
Example
       Display info about all FITS files of the form '*.fit' in the current
               directory
               IDL> fits_info, '*.fit'
       Any time a *.fit file is found which is *not* in FITS format, an error
       message is displayed at the terminal and the program continues
Procedures Used
       GETTOK(), MRD_SKIP, STRN(), SXPAR(), TEXTOPEN, TEXTCLOSE
System Variables
       The non-standard system variables !TEXTOUT and !TEXTUNIT will be
       created by FITS_INFO if they are not previously defined.
       DEFSYSV,'!TEXTOUT',1
       DEFSYSV,'!TEXTUNIT',0
       See TEXTOPEN.PRO for more info
Revision History
       Written, K. Venkatakrishna, Hughes STX, May 1992
       Added N_ext keyword, and table_name info, G. Reichert
       Work on *very* large FITS files   October 92
       More checks to recognize corrupted FITS files     February, 1993
       Proper check for END keyword    December 1994
       Correctly size variable length binary tables  WBL December 1994
       EXTNAME keyword can be anywhere in extension header WBL  January 1998
       Correctly skip past extensions with no data   WBL   April 1998
       Converted to IDL V5.0, W. Landsman, April 1998
       No need for !TEXTOUT if /SILENT D.Finkbeiner   February 2002
       Define !TEXTOUT if needed.  R. Sterner, 2002 Aug 27
       Work on gzip compressed files for V5.3 or later  W. Landsman 2003 Jan
       Improve speed by only reading first 36 lines of header
       Count headers with more than 32767 lines         W. Landsman Feb. 2003
       Assume since V5.3 (OPENR,/COMPRESS)   W. Landsman Feb 2004
       EXTNAME keyword can be anywhere in extension header again
                         WBL/S. Bansal Dec 2004
       Read more than 200 extensions  WBL   March 2005
       Work for FITS files with SIMPLE=F   WBL July 2005

Last modified by pro2html on 2005 July 23 at 03:11 UTC

[Home Page] [Software, Documentation] [IDL Documentation] [Quick Reference] [Feedback]

Jörn Wilms (wilms@astro.uni-tuebingen.de)
Updated automatically