Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

transId function sometimes give error #30

Open
wt12318 opened this issue Apr 5, 2024 · 2 comments
Open

transId function sometimes give error #30

wt12318 opened this issue Apr 5, 2024 · 2 comments

Comments

@wt12318
Copy link

wt12318 commented Apr 5, 2024

Hi,
Thanks for your tools. When I used transId to transform gene ids, I found that this tool sometimes works fine, but sometimes it gives an error:

ec <- 0
for (i in 1:10){
  esm_id <- try(genekitr::transId(unique(dt$NCBIid), transTo = "ensembl"))
  if(inherits(esm_id, "try-error")){
    ec <- ec + 1
  }
}
ec
##[1] 3

In this example, this gives error in 3 out 10 times. Why this happened? How could I handle this? (The dt file is provided)
Thanks.
dt.zip

@reedliu
Copy link
Contributor

reedliu commented Apr 5, 2024

Hi,
I have tested your data 20 times and have not found any problems.
Do you have any error information when transId fails?
image

@wt12318
Copy link
Author

wt12318 commented Apr 5, 2024

The Error message is:

Maybe your "trans_to" argument is wrong, please check again...
Error in tbl_vars_dispatch(x) : object 'res' not found

I just try it again, and it remains 1/10 error:

dt <- readRDS("~/dt.rds")
ec <- 0
for (i in 1:10){
  esm_id <- try(genekitr::transId(unique(dt$NCBIid), transTo = "ensembl"))
  if(inherits(esm_id, "try-error")){
    ec <- ec + 1
  }
}
##
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Maybe your "trans_to" argument is wrong, please check again...
Error in tbl_vars_dispatch(x) : object 'res' not found
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl
Some ID occurs one-to-many match, like "401427, 124056, 3323"...

99.02% genes are mapped to ensembl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants