def scan(
        self,
        func: Callable[..., Any],
        binop: Callable[..., Any],
        ident: float,
        arr: T_ChunkedArray,
        axis: int | None = None,
        dtype: _DType_co | None = None,
        **kwargs: Any,
    ) -> T_ChunkedArray:
        """
        General version of a 1D scan, also known as a cumulative array reduction.

        Used in ``ffill`` and ``bfill`` in xarray.

        Parameters
        ----------
        func: callable
            Cumulative function like np.cumsum or np.cumprod
        binop: callable
            Associated binary operator like ``np.cumsum->add`` or ``np.cumprod->mul``
        ident: Number
            Associated identity like ``np.cumsum->0`` or ``np.cumprod->1``
        arr: dask Array
        axis: int, optional
        dtype: dtype

        Returns
        -------
        Chunked array

        See also
        --------
        dask.array.cumreduction
        """
        raise NotImplementedError()

        General version of a 1D scan, also known as a cumulative array reduction.

        Used in ``ffill`` and ``bfill`` in xarray.

        Parameters
        ----------
        func: callable
            Cumulative function like np.cumsum or np.cumprod
        binop: callable
            Associated binary operator like ``np.cumsum->add`` or ``np.cumprod->mul``
        ident: Number
            Associated identity like ``np.cumsum->0`` or ``np.cumprod->1``
        arr: dask Array
        axis: int, optional
        dtype: dtype

        Returns
        -------
        Chunked array

        See also
        --------
        dask.array.cumreduction
        
xarray/namedarray/parallelcompat.py