Skip to content

Commit

Permalink
Merge pull request #11 from taylor-lab/legacyoncokb
Browse files Browse the repository at this point in the history
Legacy oncokb URL replacement
  • Loading branch information
johnoooh authored Nov 11, 2024
2 parents 2e82ee5 + 52355be commit e8af3e0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions R/hotspot-annotate-maf.R
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@
#' @name hotspot_annotate_maf
NULL

load_gene_annotation = function(oncokbbaseurl = 'https://legacy.oncokb.org/api/v1/genes') {
load_gene_annotation = function(oncokbbaseurl = 'https://data-legacy.oncokb.aws.mskcc.org/api/v1/genes') {
read_lines(oncokbbaseurl) %>%
fromJSON()
}

#' @export
#' @rdname hotspot_annotate_maf
hotspot_annotate_maf = function(maf, oncokbbaseurl = 'https://legacy.oncokb.org/api/v1/genes', hotspot_tbl = NULL) {
hotspot_annotate_maf = function(maf, oncokbbaseurl = 'https://data-legacy.oncokb.aws.mskcc.org/api/v1/genes', hotspot_tbl = NULL) {

if (!inherits(maf, 'data.frame')) stop('Input MAF must be a data frame, preferrable VEP annotated')
if (!is.null(hotspot_tbl)) {
Expand Down
2 changes: 1 addition & 1 deletion R/oncokb-annotate-maf.R
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ query_oncokb = function(gene, protein_change, variant_type, start, end, cancer_t

if (variant_type != '') {

base_url = 'http://oncokb.org/legacy-api/indicator.json?source=cbioportal'
base_url = 'https://data-legacy.oncokb.aws.mskcc.org/legacy-api/indicator.json?source=cbioportal'
oncokb_version = httr::content(httr::GET(base_url))[['dataVersion']]
tag = paste(gene, protein_change, cancer_type, sep = '-')

Expand Down

0 comments on commit e8af3e0

Please sign in to comment.