moment¶
- specutils.analysis.moment(spectrum, regions=None, order=0, axis='spectral')[source]¶
Estimate the moment of the spectrum.
- Parameters:
- spectrum
Spectrum
The spectrum object over which the width will be calculated.
- regions: `~specutils.SpectralRegion` or list of `~specutils.SpectralRegion`
Region within the spectrum to calculate the gaussian sigma width. If regions is
None
, computation is performed over entire spectrum.- orderint
The order of the moment to be calculated. Default=0
- axisint, str
Axis along which a moment is calculated. Default=’spectral’, which computes along the spectral axis.
- spectrum
- Returns:
- moment:
float
or list (based on region input) Moment of the spectrum. Returns None if (order < 0 or None)
- moment: