Skip to content

Fix support for numpy<2.0 and pearson_r with numpy>2.0 #431

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

Zeitsperre
Copy link
Collaborator

@Zeitsperre Zeitsperre commented Jul 17, 2025

Description

This fix deals with an oversight in the last release that accidentally dropped support for numpy v1. It also fixes a very small bug that can occur in numpy v2.0+, where a single value Pearson R (non-np.ndarray) can cause a ValueError.

Closes #430

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Tested locally with numpy v1.26 (should work fine with numpy v1.24) and numpy v2.0.

Pre-Merge Checklist (final steps)

  • I have rebased onto main or develop (wherever I am merging) and dealt with any conflicts.
  • I have squashed commits to a reasonable amount, and force-pushed the squashed commits.

References

@Zeitsperre Zeitsperre self-assigned this Jul 17, 2025
Copy link

codecov bot commented Jul 17, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.56%. Comparing base (ca329e0) to head (6bfd47c).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #431   +/-   ##
=======================================
  Coverage   94.55%   94.56%           
=======================================
  Files          27       27           
  Lines        2829     2833    +4     
=======================================
+ Hits         2675     2679    +4     
  Misses        154      154           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Zeitsperre Zeitsperre requested a review from aaronspring July 18, 2025 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

_pearson_r_eff_p_value fails for single point pearson values
2 participants