I have a list of GO ids and I want to find unique term description such that if I provide say 200 GO IDs I will get 200 specific GO terms. The code snippet I am using is given below. Although it kind of works ,but for one GO ids I get several terms like for my 200 GO ids I get 2577 GO terms where as I am interested in a specific unique GO term. The output that I want is like this GO:0007254 = JNK cascade
library(biomaRT)
mart <- useMart(biomart = "ENSEMBL_MART_ENSEMBL", dataset = "drerio_gene_ensembl", host = "asia.ensembl.org")
v1 <-c(target) # The list of GO ids that I want to pass as a list.
go_list <- getBM(attributes=c("go_id", "name_1006", "namespace_1003"),
filters = "go",
values = c(v1),
mart=mart, uniqueRows = TRUE)
Are you actually passing in
c("v1")
in your real code or are you using justv1
? The former is wrong.I have used whole data with c(v1) removing the quotes and I get 2557 GO ids given 234 GO terms, without finding out unique GO terms.
Since OP won't add a link even when explicitly asked to, here's a link to their cross-post: https://bioinformatics.stackexchange.com/questions/17619/mapping-unique-go-term-description-given-a-specific-go-ids