Utility functions (i/o)#
- pygrating.pygrating.plot_spectrum(spec, ax=None, color='k', label=None)#
Plot specutils spec1D.
- Parameters
spec (Spectrum1D) – Spectum1D object with errors and UVIT metadata.
- pygrating.pygrating.save_spectrum(spec, file_name, overwrite=False)#
Save Spectrum1D object
- Parameters
spec (Spectrum1D) – Spectrum1D object
file_name (str) – File name
- Returns
qt_spec – Astropy QTable .fits file including units and metadata
- Return type
QTable
- pygrating.pygrating.load_spectrum(file_name)#
Load Spectrum1D object from a QTable .fits file
- Parameters
file_name (str) – File name with path