Name
readmhdufits.pro
Purpose
Given a multi-HDU FITS file, this routine will assemble the
various components into a single array based on the header
keywords describing the layout.
Calling Sequence
array = readmhdufits(filename)
Inputs
filename = name of the multi-HDU FITS file to read
Optional Input Keyword Parameters
- NOTRIM
- if set, do not trim pre- and post-scan columns
- NOBIAS
- if set, do not perform overscan subtraction
- LINEBIAS
- if set, remove overscan line by line [default = use scalar value]
- GAINDATA
- if set to a structure with gain for each amp, make
gain correction
- VERBOSE
- if set, give feedback
Optional Output Keyword Parameters
- HEADER
- retrieve the header from the primary HDU and return
it as a string array
Outputs
This function will return a 2-D floating-point array
representing the assembled image.
Requirements
Examples
- Read in a FITS file, with trimming and bias removal,
returning the data as "array" and the header as "header":
array = readmhdufits( 'lred0001.fits', header=header)
- Read in a FITS file, without trimming or bias removal,
returning the data as "array" and the header as "header":
array = readmhdufits( 'lred0001.fits', /notrim, /nobias, header=header)
- Perform gain correction and use line-by-line bias
determination:
gain = [1.,2.,3.,4] for vidInp1,2,3,4
gaindata = build_gaindata(gain)
array = readmhdufits( 'lred0001.fits', /linebias, gaindata=gaindata)
Procedure
Author
Marc Kassis, W. M. Keck Obseravtory