'Calculate the resulting uncertainty given an operation on the data.
.. versionadded:: 1.2
Parameters
operation : callable
The operation that is performed on the `NDData`. Supported are
`numpy.add`, `numpy.subtract`, `numpy.multiply` and
`numpy.true_divide` (or `numpy.divide`).
other_nddata : `NDData` instance
The second operand in the arithmetic operation.
result_data : `~astropy.units.Quantity` or `numpy.ndarray`
The result of the arithmetic operations on the data.
correlation : `numpy.ndarray` or number
The correlation (rho) is defined between the uncertainties in
sigma_AB = sigma_A * sigma_B * rho. A value of ``0`` means
uncorrelated operands.
Returns
resulting_uncertainty : `NDUncertainty` instance
Another instance of the same `NDUncertainty` subclass containing
the uncertainty of the result.
Raises
ValueError
If the ``operation`` is not supported or if correlation is not zero
but the subclass does not support correlated uncertainties.
Notes
First this method checks if a correlation is given and the subclass
implements propagation with correlated uncertainties.
Then the second uncertainty is converted (or an Exception is raised)
to the same class in order to do the propagation.
Then the appropriate propagation method is invoked and the result is
returned.'

def propagate(self, operation, other_nddata, result_data, correlation):

    if (not self.supports_correlated):
        if (isinstance(correlation, np.ndarray) or (correlation != 0)):
            raise ValueError(u'{0}    does    not    support    uncertainty    propagation    with    correlation.'.format(self.__class__.__name__))
    other_uncert = self._convert_uncertainty(other_nddata.uncertainty)
    if (operation.__name__ == u'add'):
        result = self._propagate_add(other_uncert, result_data, correlation)
    elif (operation.__name__ == u'subtract'):
        result = self._propagate_subtract(other_uncert, result_data, correlation)
    elif (operation.__name__ == u'multiply'):
        result = self._propagate_multiply(other_uncert, result_data, correlation)
    elif (operation.__name__ in [u'true_divide', u'divide']):
        result = self._propagate_divide(other_uncert, result_data, correlation)
    else:
        raise ValueError(u'unsupported    operation')
    return self.__class__(result, copy=False)
