Hi Tim and Tony,

   Thanks for Tony's reply, I have the same impression with him. There are
some KGML files available with the package release for the purpose of demo.
If you want to use any other file (I am sure 00010.xml does not belong to
them), you'd first download the file from ftp://ftp.genome.jp/pub/kegg/xml/,
say ftp://ftp.genome.jp/pub/kegg/xml/organisms/hsa/hsa00010.xml. Save the
file to any destination you want (say /my/KGML/dir/goes/here/hsa00010.xml),
then

  xfile <- "/my/KGML/dir/goes/here/hsa00010.xml"
  p <- parseKGML(xfile)

Best wishes,
David



2009/5/7 Tim Smith <tim_smith_666@yahoo.com>

> Hi David,
>
> I was trying the package to get at the genes for each node, and tried the
> code you suggested. However, for some nodes/pathways, they seem to give an
> error. For example:
>
> ##----------
> library(KEGGgraph)
>
>     # Glycolysis pathway
>     xfile <- system.file("/extdata/hsa00010.xml", package="KEGGgraph")
>     p <- parseKGML(xfile)
>
> ## --------------
>
> But this gives 'Error:   does not seem to be XML, nor to identify a file
> name'.
>
> Is there a way around this?
>
> thanks again!
>
>
>
> ------------------------------
> *From:* Jitao David Zhang <davidvonpku@gmail.com>
> *To:* Tim Smith <tim_smith_666@yahoo.com>
> *Sent:* Tuesday, May 5, 2009 1:21:04 PM
> *Subject:* Re: [BioC] KEGG: gene ids for nodes in a pathway
>
> Hi Tim,
>
>   Using KEGGgraph package may solve the problem. As an example:
>
>     library(KEGGgraph)
>
>     // use human MAPK pathway as an example
>     xfile <- system.file("/extdata/hsa04010.xml", package="KEGGgraph")
>     p <- parseKGML(xfile)
>     pNodes <- nodes(p)
>
>     displayNames <- sapply(pNodes, getDisplayName)
>     geneids <- sapply(pNodes, function(x) translateKEGG2GeneID(getName(x)))
>
>     The displayNames now contain the labels (the visible names of the
> nodes), while the geneids are the EntrezGeneID (in human case) of the genes
> contained in that node.
>
>     To install KEGGgraph, just type
>
>     source("http://www.bioconductor.org/biocLite.R")
>     biocLite(KEGGgraph)
>
>     Best wishes,
> David
>
> 2009/5/4 Tim Smith <tim_smith_666@yahoo.com>
>
>> Hi,
>>
>> I wanted a list of genes for a particular pathway arranged nodewise. For
>> example, if I select the Jak-stat pathway ("
>> http://www.genome.jp/kegg/pathway/hsa/hsa04630.html"), how do I get the
>> entrez ids of genes associated with the node 'STAT' ? Currently, I use the
>> following code:
>>
>> x <- toTable(org.Hs.egPATH)
>>
>> and then select genes associated with a particular pathway (e.g. for
>> Jak-stat: "04630") . But this gives the entire set of genes associated with
>> the pathway. Is there a way to get the entrez ids of the genes associated
>> with each of the nodes ('JAK', 'STAT', 'STAM','PIAS' etc.) in the pathway?
>>
>> thanks!
>>
>>
>>
>>
>>        [[alternative HTML version deleted]]
>>
>> _______________________________________________
>> Bioconductor mailing list
>> Bioconductor@stat.math.ethz.ch
>> https://stat.ethz.ch/mailman/listinfo/bioconductor
>> Search the archives:
>> http://news.gmane.org/gmane.science.biology.informatics.conductor
>>
>
>
>
> --
> Jitao David Zhang
> Computational Biology Ph.D.
> Division of Molecular Genome Analysis
> DKFZ, Heidelberg D-69120, Germany
>
> http://sites.google.com/site/jazzydevzoo/
>
>


-- 
Jitao David Zhang
Computational Biology Ph.D.
Division of Molecular Genome Analysis
DKFZ, Heidelberg D-69120, Germany

http://sites.google.com/site/jazzydevzoo/

	[[alternative HTML version deleted]]

