Last modified: December 2013

URL: https://cxc.cfa.harvard.edu/ciao/ahelp/get_number_cols.html
Jump to: Description · Example · Bugs · See Also


AHELP for CIAO 4.15

get_number_cols

Context: crates

Synopsis

Return the number of columns in a crate.

Syntax

get_number_cols(crate)

Description

Argument Description
crate A Crate object such as a TABLECrate or IMAGECrate

The get_number_cols command returns the number of columns in the input crate. If the crate contains an image, the return value is 1.


Example

>>> cr = read_file("evt2.fits")
>>> ncols = get_number_cols(cr)
>>> ncols
17

The number of rows in the file is stored in the variable "ncols".


Bugs

See the bug pages on the CIAO website for an up-to-date listing of known bugs.

Refer to the CIAO bug pages for an up-to-date listing of known issues.

See Also

contrib
add_colvals
crates
add_col, col_exists, copy_colvals, copy_piximgvals, delete_col, get_axis_transform, get_col, get_col_names, get_colvals, get_crate_item_type, get_crate_type, get_key, get_key_names, get_keyval, get_number_rows, get_piximg, get_piximg_shape, get_piximgvals, get_transform, get_transform_matrix, is_virtual, set_colvals