webbpsf_ext.robust.std

webbpsf_ext.robust.std(inputData, Zero=False, axis=None, dtype=None, keepdims=False, return_mask=False)[source]

Robust Sigma

Based on the robust_sigma function from the AstroIDL User’s Library.

Calculate a resistant estimate of the dispersion of a distribution.

Use the median absolute deviation as the initial estimate, then weight points using Tukey’s Biweight. See, for example, “Understanding Robust and Exploratory Data Analysis,” by Hoaglin, Mosteller and Tukey, John Wiley & Sons, 1983, or equation 9 in Beers et al. (1990, AJ, 100, 32).

Parameters

inputData (ndarray) – The input data.

Keyword Arguments
  • axis (None or int or tuple of ints, optional) –

    Axis or axes along which the deviation is computed. The default is to compute the deviation of the flattened array.

    If this is a tuple of ints, a standard deviation is performed over multiple axes, instead of a single axis or all the axes as before. This is the equivalent of reshaping the input data and then taking the standard devation.

  • keepdims (bool, optional) – If this is set to True, the axes which are reduced are left in the result as dimensions with size one. With this option, the result will broadcast correctly against the original arr.

  • return_mask (bool) – If set to True, then only return boolean array of good (1) and rejected (0) values.