Skip to contents

symbol_to_identifier() remaps old marker symbols to, in-use, most up to date marker identifiers.

Usage

symbol_to_identifier(x, report_file = NULL, n_max = Inf)

Arguments

x

A character vector of marker symbols to be remapped.

report_file

The path to a MRK_List1.rpt file. Leave this as NULL and the function will automatically download the report from https://www.informatics.jax.org/downloads/reports/MRK_List1.rpt.

n_max

Maximum number of lines to read from the report_file.

Examples

rpt_ex01 <- report_example("MRK_List1-EX01.rpt")
read_report(report_file = rpt_ex01, report_type = "MRK_List1") |>
  dplyr::select("marker_status", "marker_symbol", "marker_id_now")
#> # A tibble: 7 × 3
#>   marker_status marker_symbol      marker_id_now
#>   <fct>         <chr>              <chr>        
#> 1 W             1700024N20Rik      MGI:3704307  
#> 2 W             1700024N20Rik      MGI:1891207  
#> 3 W             2200002F22Rik      MGI:1891207  
#> 4 W             ENSMUSG00000045549 MGI:3704307  
#> 5 O             Plpbp              MGI:1891207  
#> 6 W             Prosc              MGI:1891207  
#> 7 O             Proscos            MGI:3704307  

# NB:
#   - "1700024N20Rik" has two conflicting mappings, so maps to `NA`.
#   - "Hes1" is not present in MRK_List1-EX01.rpt, so maps to `NA`.
#   - "Plpbp" (official) and "Prosc" (withdrawn) both map to "MGI:1891207"

marker_symbols <- c("2200002F22Rik", "Plpbp", "Prosc", "1700024N20Rik", "Hes1")
symbol_to_identifier(x = marker_symbols, report_file = rpt_ex01)
#> [1] "MGI:1891207" "MGI:1891207" "MGI:1891207" NA            NA