| Title: | Genetic Target Validity Scores Beside Clinical Success Benchmarks |
|---|---|
| Description: | Returns, for user-supplied gene and disease pairs, two separate assessments: genetic target validity, from the published gene-phecode predictions of ML-GPS (Chen et al. 2024 <doi:10.1038/s41467-024-53333-y>) and RareGPS (Chen et al. 2026 <doi:10.1186/s13073-026-01671-5>), and the historical clinical launch proportion of the matching genetic support group from 'geneticPoS'. The predictions are downloaded once from their Zenodo records, checked against the published MD5 checksums and cached. |
| Authors: | Daiki Kumakura [aut, cre] |
| Maintainer: | Daiki Kumakura <[email protected]> |
| License: | GPL-3 |
| Version: | 0.1.1 |
| Built: | 2026-12-04 08:22:33 UTC |
| Source: | https://github.com/DaikiKumakura/geneticValidity |
The two axes are reported side by side and are never combined into one number.
Genetic target validity: the published ML-GPS and RareGPS scores of the gene-phecode pair, with their percentile among all pairs of the same source. These scores were trained to recognise pairs that have a drug indication at any clinical phase; they are not probabilities of approval.
Clinical success: the historical phase I to launch proportion of the genetic
support group that the pair falls into in geneticPoS::karim_pos(). It is
a past group outcome, not a probability for the pair.
validity_axes(pairs, karim = NULL, sources = c("mlgps", "raregps"), dir = tools::R_user_dir("geneticValidity", "cache"))validity_axes(pairs, karim = NULL, sources = c("mlgps", "raregps"), dir = tools::R_user_dir("geneticValidity", "cache"))
pairs |
Data frame, or a local CSV/TSV file, with columns gene (HGNC symbol) and phecode (phecodeX code, e.g. "EM_239.1"). Add indication_id (MeSH ID) to attach a geneticPoS result. |
karim |
Optional result of |
sources |
Prediction sets for the validity axis: "mlgps" (112 common chronic disease phecodes) and/or "raregps" (161 uncommon and rare phecodes). |
dir |
Cache directory for the downloaded predictions. |
phecodeX and MeSH are not mapped to each other; supply both IDs.
A pair absent from a source has NA scores. <source>_covered tells
whether the phecode is part of that source at all, so that "not scored" and
"phecode outside the source" can be told apart.
<source>_label_indicated is TRUE when the pair was already an
indication in the training labels of that source; its score is then not an
independent prediction.
The predictions are downloaded at first use, checked against the MD5
checksums of their Zenodo records and cached; see validity_fetch.
The input pairs with, for each source, score, percentile, label_indicated and covered columns, and pos_status, pos_reference_id and pos_historical_launch_rate from geneticPoS.
## Not run: pairs <- data.frame(gene = c("PCSK9", "IL23R"), phecode = c("EM_239.1", "GI_522.11"), indication_id = c("D006937", "D003424")) validity_axes(pairs, sources = "mlgps") ## End(Not run)## Not run: pairs <- data.frame(gene = c("PCSK9", "IL23R"), phecode = c("EM_239.1", "GI_522.11"), indication_id = c("D006937", "D003424")) validity_axes(pairs, sources = "mlgps") ## End(Not run)
Downloads the prediction archive from its Zenodo record (about 350 MB for ML-GPS and 150 MB for RareGPS), stops if its MD5 checksum differs from the published one, and keeps gene, phecode, score, the training label (indication and maximum phase) and the percentile of the score in a cached RDS file. Later calls reuse the cache.
validity_fetch(source = c("mlgps", "raregps"), dir = tools::R_user_dir("geneticValidity", "cache"), quiet = FALSE)validity_fetch(source = c("mlgps", "raregps"), dir = tools::R_user_dir("geneticValidity", "cache"), quiet = FALSE)
source |
"mlgps" or "raregps". |
dir |
Cache directory. |
quiet |
Suppress download messages. |
The path of the cached RDS file.
## Not run: validity_fetch("raregps") ## End(Not run)## Not run: validity_fetch("raregps") ## End(Not run)
Lists each prediction set with its publication, Zenodo record, file, size, MD5 checksum and licence.
validity_sources()validity_sources()
A data frame with one row per source.
validity_sources()[, c("source", "score", "record_doi", "license")]validity_sources()[, c("source", "score", "record_doi", "license")]