QuantityTableCoordinate#
- class ndcube.extra_coords.QuantityTableCoordinate(*tables, names=None, physical_types=None)[source]#
- Bases: - BaseTableCoordinate- A lookup table up built on - Quantity.- Quantities must be 1-D but more than one can be provided to represent different dimensions of an N-D coordinate. - Parameters:
- tables (one or more - Quantity) – The coordinates. Must be 1 dimensionsal. If coordinate system is >1D, multiple 1-D Quantities can be provided representing the different dimensions
- names ( - stror- listof- str) – Custom names for the components of the QuantityTableCoord. If provided, a name must be given for each input Quantity.
- physical_types (str` or - listof- str) – Physical types for the components of the QuantityTableCoord. If provided, a physical type must be given for each input Quantity. Physical types of the components of the SkyCoord. If provided, a physical type must be given for each component.
 
 - Attributes Summary - Generate the Frame for this LookupTable. - Generate the Astropy Model for this LookupTable. - Number of pixel dimensions in this table. - Number of array dimensions to which this TableCoordinate corresponds. - Shape of the array grid to which this TableCoordinate corresponds. - Methods Summary - interpolate(*new_array_grids, **kwargs)- Interpolate QuantityTableCoordinate to new array index grids. - Return a boolean if this coordinate is a scalar. - Attributes Documentation - frame#
- Generate the Frame for this LookupTable. 
 - model#
- Generate the Astropy Model for this LookupTable. 
 - n_inputs#
 - ndim#
- Number of array dimensions to which this TableCoordinate corresponds. - Note this may be different from the number of the dimensions in the underlying table(s) if different tables represent different dimensions. 
 - shape#
- Shape of the array grid to which this TableCoordinate corresponds. - Note this may be different from the shape of the underlying table(s) if different tables represent a different dimensions. 
 - Methods Documentation - interpolate(*new_array_grids, **kwargs)[source]#
- Interpolate QuantityTableCoordinate to new array index grids. - Parameters:
- new_array_grids (array-like) – The array index values at which the the new values of the coords are desired. An array grid must be provided as a separate arg for each array dimension and corresponding elements in all arrays represent a single location in the pixel grid. Therefore, array grids must all have the same shape. 
- kwargs – All remaining kwargs are passed to underlying interpolation function. 
 
- Returns:
- new_coord ( - QuantityTableCoordinate) – New TableCoordinate object holding the interpolated coords.
 
 - is_scalar()[source]#
- Return a boolean if this coordinate is a scalar. - This is used by - MultipleTableCoordinateand- ndcube.ExtraCoordsto know if the dimension has been “dropped”.
 
