line_shift

sofia_redux.toolkit.interpolate.interpolate.line_shift(y, offset, order=3, missing=nan)[source]

Shift an equally spaced array of data values by an offset

Required because no Python standard interpolation algorithms allow for nan values in the input data without slowing down the processing by several orders of magnitude.

Parameters:
yarray_like

equally spaced input data

offsetoffset

offset to shift_image data. Units are the input data spacing

orderint

values must be 2-5. 2-5: spline interpolation of the same order

missingint or float

numpy.nan values are treated as missing and will be ignored during the fit. In the output array, any missing values will be replaced by missing.

Returns
——-
array_like

numpy.ndarray. Will be of numpy.float32 if y was int type