diff --git a/skypy/halos/mass.py b/skypy/halos/mass.py index fa632953..5f5f9791 100644 --- a/skypy/halos/mass.py +++ b/skypy/halos/mass.py @@ -325,7 +325,7 @@ def _sigma_squared(M, k, Pk, growth_function, cosmology): top_hat = 3. * (np.sin(k * R) - k * R * np.cos(k * R)) / ((k * R)**3.) integrand = Pk * np.power(top_hat * k, 2) - return Dz2 * integrate.simps(integrand, k) / (2. * np.pi**2.) + return Dz2 * integrate.simpson(integrand, k) / (2. * np.pi**2.) def _dlns_dlnM(sigma, M): diff --git a/skypy/halos/tests/test_quenching.py b/skypy/halos/tests/test_quenching.py index efa0c674..d836441c 100644 --- a/skypy/halos/tests/test_quenching.py +++ b/skypy/halos/tests/test_quenching.py @@ -13,7 +13,7 @@ def test_environment_quenched(): quenched = environment_quenched(n, p) number_quenched = Counter(quenched)[True] - p_value = stats.binom_test(number_quenched, n=n, p=p, + p_value = stats.binomtest(number_quenched, n=n, p=p, alternative='two-sided') assert p_value > 0.01 @@ -28,6 +28,6 @@ def test_mass_quenched(): quenched = mass_quenched(halo_mass, offset, width) number_quenched = Counter(quenched)[True] - p_value = stats.binom_test(number_quenched, n=n, p=0.5, + p_value = stats.binomtest(number_quenched, n=n, p=0.5, alternative='two-sided') assert p_value > 0.01