ftsdata.fits_ftsdata_writer
- ftsdata.fits_ftsdata_writer(fts_data, filename, hdu_mask='MASK', hdu_uncertainty='UNCERT', hdu_hits='HITS', hdu_flags=None, key_uncertainty_type='UTYPE', compress=False, **kwd)[source]
Write FTSData object to FITS file.
- Parameters:
- filenamestr
Name of file.
- hdu_mask, hdu_uncertainty, hdu_hits, hdu_flagsstr or None, optional
If it is a string append this attribute to the HDUList as
ImageHDUwith the string as extension name. Flags are not supported at this time. IfNonethis attribute is not appended. Default is'MASK'for mask,'UNCERT'for uncertainty'HITS'for hits andNonefor flags.- key_uncertainty_typestr, optional
The header key name for the class name of the uncertainty (if any) that is used to store the uncertainty type in the uncertainty hdu. Default is
UTYPE.- compressbool, optional
Use tiled compression ImageHDU for the data. Default is
False.- kwd
All additional keywords are passed to
astropy.io.fits
- Raises:
- ValueError
If
self.maskis set but not anumpy.ndarray.If
self.uncertaintyis set but not aStdDevUncertainty.If
self.uncertaintyis set but has another unit thenself.data.
- NotImplementedError
Saving flags is not supported.