R script for offspring GO terms
1
0
Entering edit mode
10 weeks ago

Hi

I have multiple parent GO terms for which I want the offspring. The R script I found can only give the offspring for one term at a time. How can I the offspring for a list of parent GO terms?

Any help greatly appreciated.

library(GO.db)
offspring = GOMFOFFSPRING[["GO:0003824"]]
multiple script terms GO • 251 views
ADD COMMENT
1
Entering edit mode
10 weeks ago

Just use a loop, e.g.:

my.query.terms <- c("GO:0003824", "GO:0003825", "GO:0003826")
results <- vector(mode = "list", length = length(my.query.terms))

for (i in seq_along(my.query.terms)) {
       results[[i]] <- GOMFOFFSPRING[[my.query.terms[i]]]
}
ADD COMMENT
0
Entering edit mode

Thank you, very helpful!!

ADD REPLY

Login before adding your answer.

Traffic: 2002 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6