Skip to content

Commit

Permalink
numpy2 pareto
Browse files Browse the repository at this point in the history
  • Loading branch information
fkiraly committed Jul 27, 2024
1 parent 1080e37 commit 83a58ed
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions skpro/distributions/pareto.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def _mean(self):
"""
alpha = self._bc_params["alpha"]
scale = self._bc_params["scale"]
mean = np.where(alpha <= 1, np.infty, scale**alpha / (alpha - 1))
mean = np.where(alpha <= 1, np.inf, scale**alpha / (alpha - 1))
return mean

def _var(self):
Expand All @@ -74,7 +74,7 @@ def _var(self):
alpha = self._bc_params["alpha"]
scale = self._bc_params["scale"]
var = np.where(
alpha <= 2, np.infty, scale**2 * alpha / ((alpha - 2) * (alpha - 1) ** 2)
alpha <= 2, np.inf, scale**2 * alpha / ((alpha - 2) * (alpha - 1) ** 2)
)
return var

Expand Down

0 comments on commit 83a58ed

Please sign in to comment.