stack_c3d

sofia_redux.instruments.forcast.stack.stack_c3d(data, header, variance=None, extra=None)[source]

Run the stacking algorithm on C3D data (3 position chop with dither)

result = frame1 - frame2 - frame3

Parameters:
datanumpy.ndarray

(3, nrow, ncol)

headerastropy.io.fits.header.Header

FITS header to update with HISTORY messages

variancenumpy.ndarray, optional

variance array to propagate (3, nrow, ncol)

extradict, optional
If set will be updated with:
chopsub -> numpy.ndarray (nrow, ncol)

chop-subtracted data (same as output data in this case)

Returns:
2-tuple

numpy.ndarray : The stacked data array (nrow, ncol) numpy.ndarray : The propagated variance array (nrow, ncol)