Пример #1
0
 def test_nanstd_with_ddof(self):
     x = np.random.uniform(0, 10, (20, 100))
     for axis in [None, 0, 1]:
         np.testing.assert_almost_equal(
             np.nanstd(x, axis=axis, ddof=10),
             nanstd(csr_matrix(x), axis=axis, ddof=10),
         )
Пример #2
0
 def test_nanstd_with_ddof(self):
     x = np.random.uniform(0, 10, (20, 100))
     for axis in [None, 0, 1]:
         np.testing.assert_almost_equal(
             np.nanstd(x, axis=axis, ddof=10),
             nanstd(csr_matrix(x), axis=axis, ddof=10),
         )
Пример #3
0
 def _get_error_bar(self):
     std = nanstd(self.y_data, axis=0)
     return pg.ErrorBarItem(x=self.x_data,
                            y=self.__mean,
                            bottom=std,
                            top=std,
                            beam=0.01)
Пример #4
0
 def test_nanstd(self, array):
     for X in self.data:
         X_sparse = array(X)
         np.testing.assert_array_equal(nanstd(X_sparse), np.nanstd(X))
Пример #5
0
 def test_nanstd(self, array):
     for X in self.data:
         X_sparse = array(X)
         np.testing.assert_array_equal(
             nanstd(X_sparse),
             np.nanstd(X))
Пример #6
0
 def _get_error_bar(self):
     std = nanstd(self.y_data, axis=0)
     return pg.ErrorBarItem(x=self.x_data, y=self.__mean,
                            bottom=std, top=std, beam=0.01)