next up previous 405
Next: Reading a FITS header value
Up: FITS Headers
Previous: FITS Headers

Testing for the existence of a FITS header value

Suppose that you wanted to determine whether an NDF called image123 contains an AIRMASS keyword in its FITS headers (stored in the FITS extension).

     set airpres = `fitsexist image123 airmass`
     if ( $airpres == "TRUE" ) then
        <access AIRMASS FITS header>
     endif
Variable airpres would be assigned "TRUE" when the AIRMASS card was present, and "FALSE" otherwise. Remember that the ` ` quotes cause the enclosed command to be executed.



next up previous 405
Next: Reading a FITS header value
Up: FITS Headers
Previous: FITS Headers

C-shell Cookbook
Starlink Cookbook 4
Malcolm J. Currie
2006 November 26
E-mail:starlink@jiscmail.ac.uk

Copyright © 2013 Science and Technology Facilities Council