diff --git a/xarray/core/common.py b/xarray/core/common.py index ade701457c6..06a291932a7 100644 --- a/xarray/core/common.py +++ b/xarray/core/common.py @@ -46,6 +46,7 @@ DTypeLikeSave, ScalarOrArray, SideOptions, + Self, T_Chunks, T_DataWithCoords, T_Variable, @@ -810,11 +811,11 @@ def pipe( return func(self, *args, **kwargs) def rolling_exp( - self: T_DataWithCoords, + self, window: Mapping[Any, int] | None = None, window_type: str = "span", **window_kwargs, - ) -> RollingExp[T_DataWithCoords]: + ) -> RollingExp[Self]: """ Exponentially-weighted moving window. Similar to EWM in pandas