          Return the number of columns in a crate.

get_number_cols(crate)

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.

>>> 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".

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

December 2013