diff --git a/bootstrap_sampling_distribution/sampling.py b/bootstrap_sampling_distribution/sampling.py index 4fc4cb3..b3bf53f 100644 --- a/bootstrap_sampling_distribution/sampling.py +++ b/bootstrap_sampling_distribution/sampling.py @@ -169,7 +169,7 @@ def _test_statistic_validity(self, multid: bool) -> None: # Quick and dirty validity test try: self.statistic(test_array) - except (np.AxisError, IndexError): + except (np.exceptions.AxisError, IndexError): # Test resulted in one of accepted errors # 1 dim: axis 1 is out of bounds for array of dimension 1 # multid: too many indices for array: array is 2-dimensional, but 3 were indexed