noise_region_uncertainty¶
-
specutils.manipulation.
noise_region_uncertainty
(spectrum, spectral_region, noise_func=<function std>)[source]¶ Generates a new spectrum with an uncertainty from the noise in a particular region of the spectrum.
Parameters: spectrum: `~specutils.spectra.Spectrum1D
The spectrum to which we want to set the uncertainty.
spectral_region: `~specutils.spectra.SpectralRegion`
The region to use to calculate the standard deviation.
noise_func: callable
A function which takes the flux in the
spectral_region
and yields a single value for the noise to use in the result spectrum.