Skip to content

[codex] Handle missing IC50 values#307

Merged
iskandr merged 1 commit into
mainfrom
bugfix/missing-ic50-epitope-sort
Jun 20, 2026
Merged

[codex] Handle missing IC50 values#307
iskandr merged 1 commit into
mainfrom
bugfix/missing-ic50-epitope-sort

Conversation

@iskandr

@iskandr iskandr commented Jun 20, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes #306.

This PR makes missing affinity IC50 values non-fatal in the two places that assumed every pMHC_affinity row had a numeric Prediction.value:

  • VaccinePeptide target-epitope sorting now ignores missing/NaN IC50 or percentile-rank values and sends missing-only epitopes to the end.
  • Template report rows render missing/NaN mutant IC50 as No prediction, matching the existing WT IC50 placeholder behavior.
  • Test fixtures no longer derive fake percentile ranks from IC50 values.
  • Bumps vaxrank.version to 3.1.8 for the PR.

Root Cause

The IC50 sort path used min(p.value for p in affinity_leaves) directly, unlike the percentile-rank path which already filtered missing values. The report path then formatted mutant IC50 with %.2f nM unconditionally.

Validation

  • ./lint.sh
  • ./test.sh (858 passed, 8 warnings)

@iskandr iskandr force-pushed the bugfix/missing-ic50-epitope-sort branch from e890f3a to d4a73ad Compare June 20, 2026 13:34
@iskandr iskandr marked this pull request as ready for review June 20, 2026 16:49
@iskandr iskandr merged commit d2c7515 into main Jun 20, 2026
10 checks passed
@iskandr iskandr deleted the bugfix/missing-ic50-epitope-sort branch June 20, 2026 16:49
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.

Missing IC50 values can crash vaccine peptide sorting and report rendering

1 participant