Projection¶
-
class
spectral_cube.lower_dimensional_structures.
Projection
[source]¶ Bases:
spectral_cube.lower_dimensional_structures.LowerDimensionalObject
,spectral_cube.base_class.SpatialCoordMixinClass
Attributes Summary
beam
Methods Summary
convolve_to
(beam[, convolve])Convolve the image to a specified beam. from_hdu
(hdu)Return a projection from a FITS HDU. quicklook
([filename, use_aplpy, aplpy_kwargs])Use APLpy to make a quick-look image of the projection. reproject
(header[, order])Reproject the image into a new header. subimage
([xlo, xhi, ylo, yhi])Extract a region spatially. Attributes Documentation
-
beam
¶
Methods Documentation
-
convolve_to
(beam, convolve=<function convolve_fft>)[source]¶ Convolve the image to a specified beam.
Parameters: beam :
radio_beam.Beam
The beam to convolve to
convolve : function
The astropy convolution function to use, either
astropy.convolution.convolve
orastropy.convolution.convolve_fft
Returns: proj :
Projection
A Projection convolved to the given
beam
object.
-
quicklook
(filename=None, use_aplpy=True, aplpy_kwargs={})[source]¶ Use APLpy to make a quick-look image of the projection. This will make the
FITSFigure
attribute available.If there are unmatched celestial axes, this will instead show an image without axis labels.
Parameters: filename : str or Non
Optional - the filename to save the quicklook to.
-
reproject
(header, order='bilinear')[source]¶ Reproject the image into a new header.
Parameters: header :
astropy.io.fits.Header
A header specifying a cube in valid WCS
order : int or str, optional
The order of the interpolation (if
mode
is set to'interpolation'
). This can be either one of the following strings:- ‘nearest-neighbor’
- ‘bilinear’
- ‘biquadratic’
- ‘bicubic’
or an integer. A value of
0
indicates nearest neighbor interpolation.
-
subimage
(xlo='min', xhi='max', ylo='min', yhi='max')[source]¶ Extract a region spatially.
Parameters: [xy]lo/[xy]hi : int or
astropy.units.Quantity
ormin
/max
The endpoints to extract. If given as a quantity, will be interpreted as World coordinates. If given as a string or int, will be interpreted as pixel coordinates.
-