next up previous 405
Next: Writing or modifying a FITS header value
Up: FITS Headers
Previous: Testing for the existence of a FITS header value

Reading a FITS header value

Once we know the named header exists, we can then assign its value to a shell variable.

     set airpres = `fitsexist image123 airmass`
     if ( $airpres == "TRUE" ) then
        set airmass = `fitsval image123 airmass`
        echo "The airmass for image123 is $airmass."
     endif



next up previous 405
Next: Writing or modifying a FITS header value
Up: FITS Headers
Previous: Testing for the existence of a FITS header value

C-shell Cookbook
Starlink Cookbook 4
Malcolm J. Currie
2006 November 26
E-mail:ussc@star.rl.ac.uk

Copyright © 2008 Science and Technology Facilities Council