marvin.tools.quantities.datacube.
DataCube
[source]¶Bases: astropy.units.quantity.Quantity
, marvin.tools.quantities.base_quantity.QuantityMixIn
A Quantity
-powered representation of a 3D data cube.
A DataCube
represents a 3D array in which two of the dimensions
correspond to the spatial direction, with the third one being the
spectral direction.
Parameters: |
|
---|
deredden
(redcorr=None)[source]¶Returns the dereddened datacube.
Parameters: | redcorr (float or None) – The reddening correction to apply. If None , defaults to the
DataCube.redcorr . |
---|---|
Returns: | deredden (DataCube) – A DataCube with the flux and ivar corrected from reddening. |
Raises: | ValueError – If redcorr=None and DataCube.redcorr=None . |
std
¶The standard deviation of the measurement.
marvin.tools.quantities.spectrum.
Spectrum
[source]¶Bases: astropy.units.quantity.Quantity
, marvin.tools.quantities.base_quantity.QuantityMixIn
A class representing an spectrum with extra functionality.
Parameters: |
|
---|---|
Returns: | spectrum – An astropy Quantity-like object that contains the spectrum, as well as inverse variance, mask, and wavelength (itself a Quantity array). |
plot
(xlim=None, ylim=None, show_std=True, use_mask=True, n_sigma=1, xlabel='Wavelength', ylabel='Flux', show_units=True, plt_style='seaborn-darkgrid', figure=None, return_figure=False, **kwargs)[source]¶Plots the spectrum.
Displays the spectrum showing, optionally, the \(n\sigma\) region, and applying the mask.
Parameters: |
|
---|---|
Returns: | axes – The |
Example
>>> ax = spectrum.plot(n_sigma=3)
>>> ax.show()
We can change the range of the axes after the object has been created.
>>> ax.set_xlim(6500, 6600)
>>> ax.show()
error
¶The standard deviation of the measurement.
std
¶The standard deviation of the measurement.
marvin.tools.quantities.map.
EnhancedMap
(*args, **kwargs)[source]¶Bases: marvin.tools.quantities.map.Map
Creates a Map that has been modified.
datamodel
¶Returns the associated Property
.
pixmask
¶Maskbit instance for the MANGA_DAPPIXMASK flag.
See Maskbit (marvin.utils.general.maskbit.Maskbit) for documentation and
marvin.utils.general.maskbit.Maskbit()
for API reference.
marvin.tools.quantities.map.
Map
[source]¶Bases: astropy.units.quantity.Quantity
, marvin.tools.quantities.base_quantity.QuantityMixIn
Describes 2D array object with addtional features.
A general-use Quantity
-powered 2D array with features
such as units, inverse variance, mask, quick acces to statistics
methods, and plotting. While Map
can be used for any 2D array, it is
mostly intended to represent an extension in a DAP MAPS file (normally
known in MaNGA as a map). Unlike a Maps
object,
which contains all the information from a DAP MAPS file, this class
represents only one of the multiple 2D maps contained
within. For instance, Maps
may contain emission line
maps for multiple channels. A Map
would be, for example, the map for
emline_gflux
and channel ha_6564
.
A Map
is normally initialised from a Maps
by
calling the getMap
method. It can be
initialialised directly using the Map.from_maps
classmethod.
Parameters: |
|
---|
inst_sigma_correction
()[source]¶Correct for instrumental broadening.
Correct observed stellar or emission line velocity dispersion for instrumental broadening.
plot
(*args, **kwargs)[source]¶Make single panel map or one panel of multi-panel map plot.
Please see the Plotting Tutorial for examples.
Parameters: |
|
---|---|
Returns: | fig, ax (tuple) – matplotlib.figure, matplotlib.axes |
Example
>>> import marvin.utils.plot.map as mapplot
>>> maps = Maps(plateifu='8485-1901')
>>> ha = maps['emline_gflux_ha_6564']
>>> fig, ax = mapplot.plot(dapmap=ha)
restore
(path, delete=False)[source]¶Restore a Map object from a pickled file.
If delete=True
, the pickled file will be removed after it has been
unplickled. Note that, for map objects instantiated from a Maps object
with data_origin='file'
, the original file must exists and be
in the same path as when the object was first created.
save
(path, overwrite=False)[source]¶Pickle the map to a file.
This method will fail if the map is associated to a Maps loaded from the db.
Parameters: |
|
---|---|
Returns: | path (str) – The realpath to which the file has been saved. |
datamodel
¶Returns the associated Property
.
error
¶Computes the standard deviation of the measurement.
masked
¶Return a masked array using the recommended masks.
pixmask
¶Maskbit instance for the MANGA_DAPPIXMASK flag.
See Maskbit (marvin.utils.general.maskbit.Maskbit) for documentation and
marvin.utils.general.maskbit.Maskbit()
for API reference.
snr
¶Return the signal-to-noise ratio for each spaxel in the map.
marvin.tools.quantities.analysis_props.
AnalysisProperty
[source]¶Bases: astropy.units.quantity.Quantity
, marvin.tools.quantities.base_quantity.QuantityMixIn
A class describing a measurement with additional information.
Represents a quantity with an associated unit and possibly an associated error and mask.
Parameters: |
|
---|