Put different GO samples into same GO level
1
0
Entering edit mode
5.7 years ago
aboutmb • 0

Hi, everyone.

I have different samples from different species. I'd like to investigate which enriched GO terms are shared between species and which are exclusive. But they're at different GO levels. Is there some way to put all sample into same GO level?

If it got confused, please tell me. Thank you so much!

Data frame example below:

GO:0000305  P   response to oxygen radical  3   T. aurea
GO:0000303  P   response to superoxide  3   T. aurea
GO:0006801  P   superoxide metabolic process    3   T. aurea
GO:0019310  P   inositol catabolic process  3   H. impetiginosus
GO:0006189  P   'de novo' IMP biosynthetic process  7   H. serratifolius
GO:0009256  P   10-formyltetrahydrofolate metabolic process 4   H. serratifolius
GO:0046164  P   alcohol catabolic process   48  H. serratifolius
go gene ontology level • 1.5k views
ADD COMMENT
0
Entering edit mode
5.7 years ago

Boa tarde cara,

Look up whether it belongs to BP (Biological Process), MF (Molecular Function), or CC (Celular Component):

library(GO.db)
Ontology("GO:0000305")
GO:0000305 
      "BP"

Get description:

Term("GO:0000305")
                  GO:0000305 
"response to oxygen radical"

Get the parent(s) of the term:

BP <- as.list(GOBPPARENTS)
CC <- as.list(GOCCPARENTS)
MF <- as.list(GOMFPARENTS)

any(grepl("GO:0006801", BP))
[1] TRUE
any(grepl("GO:0006801", CC))
[1] FALSE
any(grepl("GO:0006801", MF))
[1] FALSE

lapply(BP[grepl("GO:0006801", BP)], function(x) Term(x))
$`GO:0019430`
GO:0006801
"superoxide metabolic process"
GO:0098869
"cellular oxidant detoxification" 
GO:0071451 
"cellular response to superoxide" 

$`GO:0042554`
GO:0006801 
"superoxide metabolic process" 

$`GO:0090322`
GO:2000377 
"regulation of reactive oxygen species metabolic process" 
GO:0006801 
"superoxide metabolic process"

Now get the names of the parents:

Term(names(BP[grepl("GO:0006801", BP)]))
                                  GO:0019430 
            "removal of superoxide radicals" 
                                  GO:0042554 
               "superoxide anion generation" 
                                  GO:0090322 
"regulation of superoxide metabolic process"

You have to realise that the GO hierarchy of terms can be quite long. You will have to develop the above scripts further if you wanted the full hierarchies of each term.

Kevin

ADD COMMENT

Login before adding your answer.

Traffic: 2532 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