Skip to content

spatially-conditioned permutations#261

Draft
knaaptime wants to merge 1 commit intopysal:mainfrom
knaaptime:permute
Draft

spatially-conditioned permutations#261
knaaptime wants to merge 1 commit intopysal:mainfrom
knaaptime:permute

Conversation

@knaaptime
Copy link
Copy Markdown
Member

resolves #244

following the discussion linked above, this changes the permutation logic for the random_label test in the comparative inference case. Specifically, rather than permute group membership (of all rows, including geometry), it permutes the group values, leaving geometry in place. This allows reasonable computation of all spatial indices

@knaaptime knaaptime marked this pull request as draft March 25, 2026 21:18
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 25, 2026

Codecov Report

❌ Patch coverage is 60.00000% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.48%. Comparing base (9a8cbd3) to head (19105e5).
⚠️ Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
segregation/inference/comparative.py 60.00% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #261      +/-   ##
==========================================
- Coverage   82.58%   82.48%   -0.10%     
==========================================
  Files          66       66              
  Lines        2302     2306       +4     
==========================================
+ Hits         1901     1902       +1     
- Misses        401      404       +3     

☔ 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.

Copy link
Copy Markdown
Collaborator

@renanxcortes renanxcortes left a comment

Choose a reason for hiding this comment

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

If this PR gets merged, then #245 gets deprecated (as it would be contemplated in this PR) and can be closed, right?

@knaaptime
Copy link
Copy Markdown
Member Author

yeah, this would supercede #245

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.

_prepare_random_label breaks when assessing spatial indexes

2 participants