specutils
specutils copied to clipboard
Spectrum1D.wavelength vs Spectrum1D.spectral_axis
Spectrum1D.spectral_axis returns the x axis in the provided units. Spectrum1D.wavelength returns the x axis in Angstrom by default. Although this is written in the docs here (https://specutils.readthedocs.io/en/stable/api/specutils.Spectrum1D.html) it is pretty confusing. Do we want to do something about this?
Get rid of wavelength
?
wavelength
, frequency
, and velocity
are supposed to be convenience properties that take the data as input through spectral_axis
and auto-converts, but it sounds like they may be misleading? @camipacifici is this the case just for wavelength
, or do you also find the other two confusing as well?
Too many ways to access basically the same info. I don't see why user cannot do one extra call themselves to use astropy.units.Quantity.to()
method if they want different units. I think we should just keep spectral_axis
and remove the rest.
Sorry, I completely forgot to reply. I do not really use frequency
and velocity
so I cannot comment on those. I think wavelength
is misleading because it is something a user might intuitively call, but they would not know their units could change.