specutils
specutils copied to clipboard
Dividing fluxes of a redshifted spectrum
I load a spectrum and then I shift the spectral_axis to a given redshift value
spec = Spectrum.read('myspectrum.fits') spec.shift_spectrum_to(redshift=2.0)
then I want to divide the fluxes by a given value (i.e 1+z)
spec /= 3.0
Now the fluxes are divided by 3, but the spectral_axis is back to the rest frame values (and the redshift is back to 0.0).
Is this a bug? Or an intended behaviour?
Thank you for any advice
I missed this when you first posted, sorry about that. Seems like a bug to me, I'll look into fixing it - thanks for the report!