主要内容

matlab.io.fits.getColType

获取经缩放的列的数据类型、重复值和宽度

语法

[dtype,repeat,width] = matlab.io.fits.getColType(fptr,colnum)

说明

[dtype,repeat,width] = matlab.io.fits.getColType(fptr,colnum) 返回 ASCII 或二进制表中列的数据类型、向量重复值和宽度(以字节为单位)。

示例

全部折叠

打开在第二个 HDU 中有一个表的示例 FITS 文件。获取有关表第五列的信息。然后关闭示例文件。

import matlab.io.*
fptr = fits.openFile("tst0012.fits");
fits.movAbsHDU(fptr,2);
[dtype,repeat,width] = fits.getColType(fptr,5)
dtype = 
'TFLOAT'
repeat = 
3
width = 
4
fits.closeFile(fptr)

提示

  • 此函数对应于 CFITSIO 库 C API 中的 fits_get_coltype (ffgtcl) 函数。

  • 要使用此函数,您必须熟悉 CFITSIO C 接口。您可以在 CFITSIO 网站上访问 CFITSIO 文档。

扩展功能

全部展开

版本历史记录

全部展开