(self)
| 764 | |
| 765 | @pytest.mark.xfail(reason="No implementation of np.pad") |
| 766 | def test_rolling(self): |
| 767 | a1 = self.ds_xr |
| 768 | a2 = self.sp_xr |
| 769 | m1 = a1.rolling(x=2, center=True).mean() |
| 770 | m2 = a2.rolling(x=2, center=True).mean() |
| 771 | |
| 772 | assert isinstance(m2.data, sparse.SparseArray) |
| 773 | assert np.allclose(m1.data, m2.data.todense()) |
| 774 | |
| 775 | @pytest.mark.xfail(reason="Coercion to dense") |
| 776 | def test_rolling_exp(self): |