saezlab / OmnipathR

R client for the OmniPath web service
https://r.omnipathdb.org/
Other
112 stars 20 forks source link

error in homology_translate #71

Closed gabora closed 1 year ago

gabora commented 1 year ago

Hi Denes,

I'm trying to translate mouse to human genes using the following command:

 OmnipathR::homology_translate(d = c("Agtr2","Akr1c18",  "Btla"),target = "human",source = "mouse",ensembl_orthology_types = "one2one")

This leads to the error

Error in `sym()`:
! Can't convert a character `NA` to a symbol.
Run `rlang::last_error()` to see where the error occurred.
Warning message:
One or more parsing issues, call `problems()` on your data frame for details, e.g.:
  dat <- vroom(...)
  problems(dat) 

The line that throws the error is this:

target2_id_type <- sym(id_types[3])

the issue seems to be that id_types is length of 2

deeenes commented 1 year ago

Hi Attila, That function is not supposed to work yet, I shouldn't have exported it. Currently this function should work for homology translation.