# xarray.core.rolling_exp.RollingExp

class `xarray.core.rolling_exp.``RollingExp`(obj, windows, window_type='span')

  Exponentially-weighted moving window object. Similar to EWM in pandas

  Parameters:

  - obj (Dataset or DataArray) – Object to window.
  - windows (A single mapping from a single dimension name to window value) –
    dim : str
      Name of the dimension to create the rolling exponential window along (e.g., time).
    window : int
      Size of the moving window. The type of this is specified in window_type
  - window_type (str, one of ['span', 'com', 'halflife', 'alpha'], default 'span') – The format of the previously supplied window. Each is a simple numerical transformation of the others. Described in detail: https://pandas.pydata.org/pandas-docs/stable/generated/pandas.DataFrame.ewm.html

  Returns: | RollingExp
  Return type: | type of input argument

  `__init__`(obj, windows, window_type='span')

    Initialize self. See help(type(self)) for accurate signature.

  Methods

  `__init__`(obj, windows[, window_type]) | Initialize self.
  `mean`() | Exponentially weighted moving average