fit_continuum

specutils.fitting.fit_continuum(spectrum, model=<Chebyshev1D(3, c0=0., c1=0., c2=0., c3=0.)>, fitter=<astropy.modeling.fitting.TRFLSQFitter object>, exclude_regions=None, exclude_region_upper_bounds=False, window=None, weights=None)[source]

Entry point for fitting using the fitting machinery.

Parameters:
spectrumSpectrum1D

The spectrum object overwhich the equivalent width will be calculated.

model: list of `~astropy.modeling.Model`

The list of models that contain the initial guess.

fitter_FitterMeta

The astropy fitter to use for fitting the model. Default: TRFLSQFitter

exclude_regionslist of 2-tuples

List of regions to exclude in the fitting. Passed through to the fitmodels routine.

exclude_region_upper_boundsbool, optional

Set to True to override the default pythonic slicing on the excluded regions (inclusive lower bound, exclusive upper bound) and remove spectral values less than or equal to the upper bound of the region rather than strictly less than the upper bound. Passed through to the fitmodels routine.

windowtuple of wavelengths

Start and end wavelengths used for fitting.

weightslist (NOT IMPLEMENTED YET)

List of weights to define importance of fitting regions.

Returns:
modelslist of Model

The list of models that contain the fitted model parameters.