matlab.io.fits.createImg
Create FITS image
Syntax
matlab.io.fits.createImg(fptr,bitpix,naxes)
Description
matlab.io.fits.createImg(fptr,bitpix,naxes) creates a new primary
image or image extension with specified data type bitpix and size
naxes. If the FITS file is currently empty, then the function
creates a primary array. Otherwise, the function appends a new image extension to the
file.
The first two elements of naxes correspond to the
NAXIS2 and NAXIS1 keywords, respectively,
while additional elements correspond to the NAXIS3,
NAXIS4, …, NAXISn
keywords.
Specify the data type bitpix as a string scalar or character
vector containing either a CFITSIO name or the corresponding MATLAB® data type.
| CFITSIO Name | MATLAB Data Type |
|---|---|
"byte_img" | "uint8" |
"short_img" | "int16" |
"long_img" | "int32" |
"longlong_img" | "int64" |
"float_img" | "single" |
"double_img" | "double" |
Examples
Tips
This function corresponds to the
fits_create_imgll(ffcrimll) function in the CFITSIO library C API.To use this function, you must be familiar with the CFITSIO C interface. You can access the CFITSIO documentation at the CFITSIO website.