Question: Gene Ontology: Shortest Path From Root To Node
0
gravatar for Woa
6.2 years ago by
Woa2.7k
United States
Woa2.7k wrote:

Given some GO BP terms for a gene I wish to find out, which of the terms has more specific meaning. I wish to find out the length of the shortest path between the BP Root term(GO:0008150) and the given term. Is there any suitable way to do that using any R package? Like something equivalent to my $length = $node->lengthOfShortestPathToRoot; in Perl's "GO-TermFinder" package.

Thanks in advance

gene-ontology • 2.1k views
ADD COMMENTlink modified 6.2 years ago by Pierre Lindenbaum118k • written 6.2 years ago by Woa2.7k
1
gravatar for Pierre Lindenbaum
6.2 years ago by
France/Nantes/Institut du Thorax - INSERM UMR1087
Pierre Lindenbaum118k wrote:

my xsd-sandbox contains a parser for GO as well as some simple bindings to query GO using java (see http://plindenbaum.blogspot.fr/2013/01/a-xml-schema-xsd-for-geneontology.html ).

download GO:

curl "http://archive.geneontology.org/latest-termdb/go_daily-termdb.rdf-xml.gz" |\
    gunzip -c | grep -v " go.xml

generate the classes (requires xjc with java 7)

jdk1.7.0_01/bin/xjc -extension -Xinject-code -b schemas/bio/go/go.jxb -d tmp schemas/bio/go/go.xsd

compile:

jdk1.7.0_01/bin/javac -d tmp -sourcepath tmp  `find tmp -name "ObjectFactory.java"`

find the shortest path for GO:1900848

java  -cp tmp generated.org.genontology.go.Go shortestpath go.xml GO:1900848

GO:1900848    GO:0031328    GO:0009891    GO:0009889    GO:0019222    GO:0050789    GO:0065007    GO:0008150    all
ADD COMMENTlink written 6.2 years ago by Pierre Lindenbaum118k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1021 users visited in the last hour