[BioC] Finding GO leaf nodes for an ontology - which package?
    Herve Pages 
    hpages at fhcrc.org
       
    Fri Jul 27 20:08:21 CEST 2007
    
    
  
Hi Tim,
Have you tried this?
> library(GO)
> isleaf <- unlist(eapply(GOBPCHILDREN, function(goid) isTRUE(is.na(goid))))
Now isleaf is a logical vector whose names are all the BP goids: for each BP goid
it tells whether it is a leaf or not.
To put the BP leaves in a character vector:
> BPleaves <- names(isleaf)[isleaf]
Cheers,
H.
Tim Smith wrote:
> Hi,
> 
> I was trying to list all the leaf nodes for a particular ontology. For this, I was using the GOstats:
> 
> g1 <- oneGOGraph("GO:0003674", GOMFCHILDREN)
> g2 <- GOleaves(g1)
> 
> Hopefully, this would give me a list of all the leaf nodes for the molecular function ontology. But this is taking too long to execute.
> 
> Is there a similar function in some other package that would be quicker?
> 
> thanks!
> 
>        
> ---------------------------------
> Pinpoint customers who are looking for what you sell. 
> 	[[alternative HTML version deleted]]
> 
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor
    
    
More information about the Bioconductor
mailing list