shift_by_offset

jwst.extract_1d.extract.shift_by_offset(offset, extract_params, update_trace=True)[source]

Shift the nominal extraction parameters by a pixel offset.

Start, stop, and polynomial coefficient values for source and background are updated in place in the extract_params dictionary. The source trace value, if present, is also updated if desired.

Parameters:
offsetfloat

Cross-dispersion offset to apply, in pixels.

extract_paramsdict

Extraction parameters to update, as created by get_extraction_parameters.

update_tracebool

If True, the trace in extract_params['trace'] is also updated if present.