\Header{getKEGGIDNName}{Functions to get/process pathway and enzyme data from KEGG}
\alias{getKEGGOrgName}{getKEGGIDNName}
\alias{getLLPathMap}{getKEGGIDNName}
\alias{mapll2EC}{getKEGGIDNName}
\alias{parseEC}{getKEGGIDNName}
\keyword{manip}{getKEGGIDNName}
\begin{Description}\relax
These functions extract pathway and enzyme data from KEGG
\url{ftp://ftp.genome.ad.jp/pub/kegg/pathways}. The functions are used
by \code{\Link{KEGG-class}}.\end{Description}
\begin{Usage}
\begin{verbatim}
getKEGGIDNName(srcUrl, exten = "/map\_title.tab")
getKEGGOrgName(name)
getLLPathMap(srcUrl, idNName, organism)
mapll2EC(id, srcUrl, organism, sep = "\t")
parseEC(llNEC)
\end{verbatim}
\end{Usage}
\begin{Arguments}
\begin{ldescription}
\item[\code{srcUrl}] \code{srcUrl} a character string for the url where
source data are available
\item[\code{exten}] \code{exten} a character string for data file name as an
extension
\item[\code{name}] \code{name} a character string for the name of the
organism of concern. "human", "mouse", and "rat" are the valid
values for now
\item[\code{organism}] \code{organism} same as name
\item[\code{idNName}] \code{idNName} a named vector normally obtained obtained
by using function \code{\Link{getKEGGIDNName}}
\item[\code{sep}] \code{sep} a character string for the separaters used to
separater entries in a file
\item[\code{llNEC}] \code{llNEC} a line of tab separated character strings
with the first character string being a LocusLink id and second
being the mapping enzyme (EC) names
\item[\code{id}] \code{id} a character string for the KEGG id used for
different pathway files
\end{ldescription}
\end{Arguments}
\begin{Details}\relax
\code{\Link{getKEGGIDNName}} read the data file "map\_title.tab" from
KEGG to obtain the mappings between between KEGG ids and pathway
names.

\code{\Link{getKEGGOrgName}} takes the name for an organism and
returns a short verion of the name used by KEGG for that organism.

\code{\Link{getLLPathMap}} maps LocusLink ids to pathway and enzyme
names for an organism using various data files from KEGG.

\code{\Link{mapll2EC}} maps LocusLink ids to enzyme (EC) names for a
given pathway.

\code{\Link{parseEC}} extracts enzyme data from a line of tab
separated character strings to map a LocusLink id to enzyme (EC) names.\end{Details}
\begin{Value}
\code{\Link{getKEGGIDNName}} returns a named vector with KEGG ids
being the names and pathway names being values.

\code{\Link{getKEGGOrgName}} returns a character string.

\code{\Link{getLLPathMap}} returns a list of two elements named "llec"
and "llpathname". Each element is a matrix with mappings between
LocusLink ids to enzyme or pathway names.

\code{\Link{mapll2EC}} returns a matrix with the first column being
LocusLink ids and second enzyme (EC) names.

\code{\Link{parseEC}} returns two elements vector with the first
element being a LocusLink id and second being the mapping enzyme (EC)
names.\end{Value}
\begin{Note}\relax
The functions are part of the Bioconductor project at Dana-Farber
Cancer Institute to provide Bioinformatics functionalities through R\end{Note}
\begin{Author}\relax
Jianhua Zhang\end{Author}
\begin{References}\relax
\url{www.genome.ad.jp/kegg/}\end{References}
\begin{SeeAlso}\relax
\code{\Link{KEGG-class}}\end{SeeAlso}
\begin{Examples}
\begin{ExampleCode}
getKEGGOrgName("human")
# This group of code needs a while to finish
if(interactive()){
# Url may change but was correct at the time of coding
idNPath <- getKEGGIDNName("ftp://ftp.genome.ad.jp/pub/kegg/pathways")
temp <- getLLPathMap("ftp://ftp.genome.ad.jp/pub/kegg/pathways",
idNPath, "human")
temp <- mapll2EC("00010", "ftp://ftp.genome.ad.jp/pub/kegg/pathways",
"human", sep = "\t")
}
\end{ExampleCode}
\end{Examples}

