"spectral cube" Code Answer's

You're definitely familiar with the best coding language Whatever that developers use to develop their projects and they get all their queries like "spectral cube" answered properly. Developers are finding an appropriate answer about spectral cube related to the Whatever coding language. By visiting this online portal developers get answers concerning Whatever codes question like spectral cube. Enter your desired code related query in the search bar and get every piece of information about Whatever code related question on spectral cube. 

spectral cube

By Alive AlligatorAlive Alligator on Jul 06, 2020
>>> import astropy.units as u
>>> from astropy.utils import data
>>> from spectral_cube import SpectralCube
>>> fn = data.get_pkg_data_filename('tests/data/example_cube.fits', 'spectral_cube')
>>> cube = SpectralCube.read(fn)
>>> print(cube)
SpectralCube with shape=(7, 4, 3) and unit=Jy / beam:
 n_x:      3  type_x: RA---ARC  unit_x: deg    range:    52.231466 deg:   52.231544 deg
 n_y:      4  type_y: DEC--ARC  unit_y: deg    range:    31.243639 deg:   31.243739 deg
 n_s:      7  type_s: VRAD      unit_s: m / s  range:    14322.821 m / s:   14944.909 m / s

# extract the subcube between 98 and 100 GHz
>>> slab = cube.spectral_slab(98 * u.GHz, 100 * u.GHz)  

# Ignore elements fainter than 1 Jy/beam
>>> masked_slab = slab.with_mask(slab > 1 Jy/beam)  

# Compute the first moment and write to file
>>> m1 = masked_slab.moment(order=1)  
>>> m1.write('moment_1.fits')  

Source: spectral-cube.readthedocs.io

Add Comment

0

All those coders who are working on the Whatever based application and are stuck on spectral cube can get a collection of related answers to their query. Programmers need to enter their query on spectral cube related to Whatever code and they'll get their ambiguities clear immediately. On our webpage, there are tutorials about spectral cube for the programmers working on Whatever code while coding their module. Coders are also allowed to rectify already present answers of spectral cube while working on the Whatever language code. Developers can add up suggestions if they deem fit any other answer relating to "spectral cube". Visit this developer's friendly online web community, CodeProZone, and get your queries like spectral cube resolved professionally and stay updated to the latest Whatever updates. 

Whatever answers related to "spectral cube"

View All Whatever queries

Whatever queries related to "spectral cube"

Browse Other Code Languages

CodeProZone