Note that behind the scenes, NDData creates references to
(not copies of) your data when possible, so modifying the data in ccd will
modify the underlying data.

You are required to provide a unit for your data. The most frequently used
units for these objects are likely to be adu, photon and electron, which
can be set either by providing the string name of the unit (as in the example
above) or from unit objects:

Methods are provided to perform arithmetic operations with a
CCDData image and a number, an astropy
Quantity (a number with units) or another
CCDData image.

Using these methods propagates errors correctly (if the errors are
uncorrelated), take care of any necessary unit conversions, and apply masks
appropriately. Note that the metadata of the result is not set if the operation
is between two CCDData objects.

In most cases you should use the functions described in
Reduction toolbox to perform common operations like scaling by gain or
doing dark or sky subtraction. Those functions try to construct a sensible
header for the result and provide a mechanism for logging the action of the
function in the header.

The arithmetic operators *, /, + and - are not overridden.

Note

If two images have different WCS values, the wcs on the first
CCDData object will be used for the resultant object.