def test_movingsum_forward_4(self): "farray.movingsum_forward #4" desired = np.array([[ 6.0, 6.0, 8.0, nan, nan], [12.0, 8.0,-1.0, nan, nan]]) skip = 1 actual = movingsum_forward(self.x, self.window, skip, norm=False) assert_almost_equal(actual, desired)
def test_movingsum_forward_1(self): "farray.movingsum_forward #1" desired = np.array([[2.0, 12.0, 6.0, 8.0, nan], [6.0, 12.0, 8.0,-1.0, nan]]) skip = 0 actual = movingsum_forward(self.x, self.window, skip, norm=True) assert_almost_equal(actual, desired)
def test_movingsum_forward_4(self): "farray.movingsum_forward #4" desired = np.array([[6.0, 6.0, 8.0, nan, nan], [12.0, 8.0, -1.0, nan, nan]]) skip = 1 actual = movingsum_forward(self.x, self.window, skip, norm=False) assert_almost_equal(actual, desired)
def test_movingsum_forward_1(self): "farray.movingsum_forward #1" desired = np.array([[2.0, 12.0, 6.0, 8.0, nan], [6.0, 12.0, 8.0, -1.0, nan]]) skip = 0 actual = movingsum_forward(self.x, self.window, skip, norm=True) assert_almost_equal(actual, desired)
def test_movingsum_forward_5(self): "farray.movingsum_forward #5" desired = np.array([[2.0, 4.0, 8.0, 0.0,-1.0], [nan, nan, nan, nan, nan]]) skip = 1 window = 1 actual = movingsum_forward(self.x, window, skip, axis=0) assert_almost_equal(actual, desired)
def test_movingsum_forward_5(self): "farray.movingsum_forward #5" desired = np.array([[2.0, 4.0, 8.0, 0.0, -1.0], [nan, nan, nan, nan, nan]]) skip = 1 window = 1 actual = movingsum_forward(self.x, window, skip, axis=0) assert_almost_equal(actual, desired)