Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MAINT: stats.dgamma.entropy: avoid deprecated NumPy usage and simplify #18349

Merged
merged 1 commit into from
Apr 24, 2023

Conversation

mdhaber
Copy link
Contributor

@mdhaber mdhaber commented Apr 23, 2023

Reference issue

Toward gh-18331

What does this implement/fix?

gh-18331 notes that tests of stats.dgamma.entropy are failing due to a NumPy deprecation. This attempts to avoid the deprecated NumPy usage. Incidentally, it also simplifies the override by relying on stats.gamma._entropy to perform the calculation.

Additional information

See #18162 (comment) for related derivation. The same approach can be used for any similar "double" distributions.

gh-18352 will fix the pesky lint failure.

Copy link
Member

@tupui tupui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Matt, LGTM and thanks @dschmitz89 for the review.

@tupui tupui merged commit 8e13bb2 into scipy:main Apr 24, 2023
@tupui tupui added this to the 1.11.0 milestone Apr 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Items related to regular maintenance tasks scipy.stats
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants