Conversation
metrics.known_relationships is the EFAAR benchmark: the share of annotated perturbation pairs whose similarity falls in either tail of the distribution over all pairs. Two-sided, because opposite effects on one process are as related as identical ones, and a map carrying no information recovers twice the tail size. Until now nothing in the package could say whether a pipeline recovers known biology, so the choice between representations and corrections was a guess. pathway_coherence answers a different question, about one set at a time. The annotation is taken either as tl.gene_sets-style sets or as the entity1/entity2 pair rows the curated sources are distributed as. Ranks come from searchsorted over the sorted comparison distribution, as in EFAAR_benchmarking at 2935f21, not from interpolated percentiles: the tie convention changes the answer on real data.
|
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #99 +/- ##
==========================================
+ Coverage 89.15% 89.25% +0.09%
==========================================
Files 80 81 +1
Lines 5865 5928 +63
==========================================
+ Hits 5229 5291 +62
- Misses 636 637 +1
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
metrics.known_relationshipsreports the share of annotated perturbation pairs whose similarity falls in either tail of the similarity distribution over all pairs — the EFAAR benchmark, and the field's usual way to ask whether a map recovers known biology. Two-sided, so opposing effects on one process count as related. A map carrying no information recovers twice the tail size, 10% by default.Nothing in the package could answer this before, so the choice between representations and corrections could not be measured.
tl.pathway_coherencescores one set at a time against random sets, which is a different question.The annotation is taken either as
source/targetsets, astl.gene_setsreturns and as a mechanism annotation is shaped, or as theentity1/entity2pair rows CORUM, hu.MAP, Reactome, SIGNOR and StringDB are distributed as. Pairs are counted once in either direction; nothing is paired with itself. No loader for those sources is included.Ranks come from
searchsortedover the sorted comparison distribution, matchingEFAAR_benchmarkingat 2935f21, rather than from interpolated percentiles. The tie convention is not cosmetic: on a rohban pipeline that keeps the degenerate-scale features, where 97% of the cosines are tied, percentile cutoffs report 0.688 against a 0.10 baseline where the reference definition reports 0.101.Verified: 801 tests pass, mypy, ruff and the formatters clean. The new tests pin the reference's tie vector, the agreement with the definition computed pair by pair, that both tails count, and that the two annotation shapes give the same answer. On real data, BBBC021 against its mechanism annotation recalls 0.478 against 0.109 with the mechanisms shuffled; rohban against hallmark sits at chance, which is the verdict
pathway_coherencealready reaches there in tutorial 08.