Skip to content

count_extreme is no longer zero#11

Merged
sarthakpati merged 6 commits intoIUCompPath:mainfrom
Geeks-Sid:Geeks-Sid-patch-1
Aug 1, 2025
Merged

count_extreme is no longer zero#11
sarthakpati merged 6 commits intoIUCompPath:mainfrom
Geeks-Sid:Geeks-Sid-patch-1

Conversation

@Geeks-Sid
Copy link
Copy Markdown
Collaborator

@Geeks-Sid Geeks-Sid commented Jul 31, 2025

fixed the bug creating a zero p-value occurence. count_extreme variable is now set to 1 if its value is zero. Dependent on #8 .

@Geeks-Sid Geeks-Sid requested a review from sarthakpati as a code owner July 31, 2025 19:57
@sarthakpati sarthakpati requested a review from Copilot July 31, 2025 23:07

This comment was marked as outdated.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@sarthakpati sarthakpati requested a review from Copilot August 1, 2025 00:20

This comment was marked as outdated.

@sarthakpati sarthakpati requested a review from Copilot August 1, 2025 00:41

This comment was marked as outdated.

@sarthakpati sarthakpati requested a review from Copilot August 1, 2025 17:40
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR fixes a statistical bug where permutation tests could produce p-values of exactly zero, which implies absolute certainty despite finite sampling. The fix implements a conservative adjustment by setting count_extreme to 1 when it would otherwise be zero.

  • Adds a check to prevent zero p-values in permutation testing
  • Implements conservative p-value estimation following statistical best practices
  • Adjusts both count_extreme and n_iterations to maintain proper calculation

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@sarthakpati sarthakpati merged commit efd281a into IUCompPath:main Aug 1, 2025
1 check failed
@sarthakpati sarthakpati deleted the Geeks-Sid-patch-1 branch August 1, 2025 17:42
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.

3 participants