Skip to content

Commit

Permalink
fix issue #9 reported by @hpages
Browse files Browse the repository at this point in the history
  • Loading branch information
Accio committed Dec 12, 2022
1 parent af8ea64 commit 11a5723
Show file tree
Hide file tree
Showing 29 changed files with 38 additions and 37 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ Package: KEGGgraph
Type: Package
Title: KEGGgraph: A graph approach to KEGG PATHWAY in R and
Bioconductor
Version: 1.51.2
Date: 2021-02-01
Version: 1.51.3
Date: 2022-12-12
Author: Jitao David Zhang, with inputs from Paul Shannon
Maintainer: Jitao David Zhang <jitao_david.zhang@roche.com>
Description: KEGGGraph is an interface between KEGG pathway and graph
Expand Down
2 changes: 1 addition & 1 deletion R/annotation.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
##------------------------------##
translateKEGGID2GeneID <- function(x, organism="hsa") {
if(organism!="hsa") {
stop("This function so far supports human gene only.\n To translate KEGGIDs of other species please use online service at http://www.genome.jp/kegg/genes.html")
stop("This function so far supports human gene only.\n To translate KEGGIDs of other species please use online service at https://www.genome.jp/kegg/genes.html")
}
gid <- gsub("^[a-z][a-z][a-z]:","", x)
return(gid)
Expand Down
2 changes: 1 addition & 1 deletion R/kegg2graph-functions.R
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ setReplaceMethod("edges", "KEGGPathway", function(object, value) {
setMethod("getKEGGgeneLink", "character", function(object) {
if(length(object) == 1)
suffix <- gsub(":","+",object)
url <- paste("http://www.genome.jp/dbget-bin/www_bget?",suffix,sep="")
url <- paste("https://www.genome.jp/dbget-bin/www_bget?",suffix,sep="")
return(url)
})

Expand Down
2 changes: 1 addition & 1 deletion R/kgmlfile.R
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ kgmlNonmetabolicName2MetabolicName <- function(destfile) {

getKGMLurl <- function(pathwayid, organism="hsa") {
## baseurl <- "ftp://ftp.genome.jp/pub/kegg/xml/kgml/non-metabolic/organisms"
baseurl <- "http://rest.kegg.jp/get/%s%s/kgml"
baseurl <- "https://rest.kegg.jp/get/%s%s/kgml"

pathwayid <- gsub("path","",pathwayid)
pathwayid <- gsub(":","",pathwayid)
Expand Down
2 changes: 1 addition & 1 deletion man/KEGGEdge-class.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ edge objects in a KEGG graph}
\item{show}{\code{signature(object = "KEGGEdge")}: Show method }
}
}
\references{ KGML Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\seealso{
\code{\link{KEGGNode-class}}
Expand Down
2 changes: 1 addition & 1 deletion man/KEGGGraphics-class.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
color}
}
}
\references{ KGML Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\seealso{
\code{\link{parseGraphics}}
Expand Down
2 changes: 1 addition & 1 deletion man/KEGGNode-class.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ and is not intended to be directly created by users.
\item{show}{\code{signature(object = "KEGGNode")}: show method }
}
}
\references{ KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }

\seealso{\code{\link{KEGGEdge-class}}, \code{\link{parseEntry}}}
Expand Down
2 changes: 1 addition & 1 deletion man/KEGGPathway-class.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Objects can be created by calls of the form \code{new("KEGGPathway",
\item{show}{\code{signature(object = "KEGGPathway")}: display method }
}
}
\references{ KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }

\seealso{\code{\link{parseKGML}},
Expand Down
2 changes: 1 addition & 1 deletion man/KEGGPathwayInfo-class.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Objects can be created by calls of the function \code{\link{parsePathwayInfo}}.
\item{show}{\code{signature(object = "KEGGPathwayInfo")}: show method}
}
}
\references{ KGML Document Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Document Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\examples{
sfile <- system.file("extdata/hsa04010.xml",package="KEGGgraph")
Expand Down
2 changes: 1 addition & 1 deletion man/KEGGReaction-class.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Objects can be created by calls of the function \code{\link{parseReaction}}.
name of product}
}
}
\references{ KGML Document Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Document Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\examples{
## We show how to extract reactions from a 'KEGGPathway' object
Expand Down
2 changes: 1 addition & 1 deletion man/KEGGpathway2reactionGraph.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ KEGGpathway2reactionGraph(pathway)
If the pathway does not contain any chemical reactions, a warning
message will be printed and \code{NULL} is returned.
}
\references{ KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\seealso{\code{\link{KEGGPathway-class}}}
\examples{
Expand Down
2 changes: 1 addition & 1 deletion man/getDisplayName-methods.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
\item{object = "KEGGNode"}{ An object of \code{\link{KEGGNode-class}} }
\item{object = "graph"}{ A KEGG graph object}
}}
\references{ KGML Document Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Document Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\examples{
sfile <- system.file("extdata/hsa04010.xml",package="KEGGgraph")
Expand Down
2 changes: 1 addition & 1 deletion man/getEntryID-methods.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
\item{obj = "list"}{ A wrapper for list of \code{\link{KEGGNode-class}} or
\code{\link{KEGGEdge-class}} objects}
}}
\references{ KGML Document Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Document Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\examples{
sfile <- system.file("extdata/hsa04010.xml",package="KEGGgraph")
Expand Down
11 changes: 6 additions & 5 deletions man/getKGMLurl.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,15 @@ getCategoryIndepKGMLurl(pathwayid, organism="hsa", method="wget", ...)
}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\references{
Plea from KEGG (available as of Aug 2011) \url{http://www.genome.jp/kegg/docs/plea.html}
Plea from KEGG (available as of Aug 2011) \url{https://www.genome.jp/kegg/docs/plea.html}
}
\note{
So far the function does not check the correctness of the
'organism' prefix, it is the responsibility of the user to garantee
the right spelling.

For Windows users, it is necessary to download and install \code{wget} program
(\url{http://gnuwin32.sourceforge.net/packages/wget.htm}) to use the
(\url{https://gnuwin32.sourceforge.net/packages/wget.htm}) to use the
\code{wget} method to download files. Sometimes it may be necessary to
modify searching path to add GnuWin32 folder (where \code{wget}
execution file is located) and re-install R to make
Expand All @@ -90,11 +90,12 @@ getKGMLurl("path:hsa00020")
getKGMLurl("00020",organism="hsa")
getKGMLurl(c("00460", "hsa:00461", "path:hsa00453", "path:00453"))
## NOT RUN
\dontrun{
hasConnection <- RCurl::url.exists(getKGMLurl("cel00010"))
if(hasConnection) {
tmp <- tempfile()
retrieveKGML(pathwayid='00010', organism='cel', destfile=tmp, method="wget")
} else {
warnings("No connection to KEGG webservice")
}
## END
}
\keyword{ IO }
2 changes: 1 addition & 1 deletion man/getName-methods.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

}}

\references{ KGML Document Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Document Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\examples{
sfile <- system.file("extdata/hsa04010.xml",package="KEGGgraph")
Expand Down
2 changes: 1 addition & 1 deletion man/getReactions-methods.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
\describe{
\item{object = "KEGGPathway"}{ An object of \code{\link{KEGGPathway-class}}}
}}
\references{ KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\seealso{\code{\link{KEGGPathway-class}}}
\examples{
Expand Down
2 changes: 1 addition & 1 deletion man/getSubtype-methods.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
See \code{\link{KEGGEdge-class}} for examples. The method for graphs
is a wrapper to extract all subtype information from one graph.
}
\references{ KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\section{Methods}{
\describe{
Expand Down
2 changes: 1 addition & 1 deletion man/getTitle-methods.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
The methods get title attribute for given KGML element, for example
for objects of \code{\link{KEGGPathway-class}} or \code{\link{KEGGPathwayInfo-class}}
}
\references{ KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\section{Methods}{
\describe{
Expand Down
2 changes: 1 addition & 1 deletion man/getType-methods.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
The meanings and descriptions of the types can be found at KGML manual listed in
the reference.
}
\references{ KGML Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\section{Methods}{
\describe{
Expand Down
4 changes: 2 additions & 2 deletions man/parseEntry.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ parseEntry(entry)
\item{entry}{ XML node of KGML file }
}
\details{
See \url{http://www.genome.jp/kegg/docs/xml/} for more details about
See \url{https://www.genome.jp/kegg/docs/xml/} for more details about
'entry' as well as other elements in KGML files.
}
\value{
An object of \code{link{KEGGNode}} or (in case of a group node) \code{link{KEGGGroup}}
}
\references{\url{http://www.genome.jp/kegg/docs/xml/}}
\references{\url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang <jitao_david.zhang@roche.com> }
\seealso{ \code{\link{parseGraphics}}, \code{\link{parseKGML}},
\code{\link{KEGGNode-class}}, \code{\link{KEGGGroup-class}} }
Expand Down
2 changes: 1 addition & 1 deletion man/parseGraphics.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ parseGraphics(graphics)
\value{
An object of \code{\link{KEGGGraphics-class}}.
}
\references{ KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\seealso{\code{\link{KEGGGraphics-class}}}
2 changes: 1 addition & 1 deletion man/parseKGML.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ parseKGML(file)
\value{
An object of \code{\link{KEGGPathway-class}}.
}
\references{ KGML Manual \url{http://www.genome.jp/kegg/docs/xml/} }
\references{ KGML Manual \url{https://www.genome.jp/kegg/docs/xml/} }
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\seealso{
\code{\link{parseEntry}}, \code{\link{parseRelation}},
Expand Down
4 changes: 2 additions & 2 deletions man/parseKGMLexpandMaps.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ parseKGMLexpandMaps(file, downloadmethod = "wget", genesOnly = TRUE, localdir,..
\details{
In KEGG pathways there're usually pathways contained('cross-linked')
in other pathways, for example see
\url{http://www.genome.jp/kegg/pathway/hsa/hsa04115.html}, where p53
\url{https://www.genome.jp/kegg/pathway/hsa/hsa04115.html}, where p53
signalling pathway contains other two pathways 'apoptosis' and 'cell
cycle'. This function parses these pathways (refered as 'maps' in KGML
manual), download their KGML files from KEGG FTP website, parse them
Expand All @@ -42,6 +42,6 @@ parseKGMLexpandMaps(file, downloadmethod = "wget", genesOnly = TRUE, localdir,..
\value{
A directed graph object
}
\references{KGML Document manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{KGML Document manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{jitao_david.zhang@roche.com}}
\seealso{ for most users it is enough to use \code{\link{parseKGML2Graph}} }
2 changes: 1 addition & 1 deletion man/parsePathwayInfo.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ parsePathwayInfo(root)
\value{
An object of \code{\link{KEGGPathwayInfo-class}}
}
\references{ KGML Document Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Document Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com}}
\keyword{IO}
2 changes: 1 addition & 1 deletion man/parseReaction.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ parseReaction(reaction)
\value{
An object of \code{\link{KEGGReaction-class}}
}
\references{ KGML Document Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{ KGML Document Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mail:jitao_david.zhang@roche.com} }
\keyword{IO}
4 changes: 2 additions & 2 deletions man/parseRelation.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ parseRelation(relation)
\item{relation}{ XML node of KGML file }
}
\details{
See \url{http://www.genome.jp/kegg/docs/xml/} for more details about
See \url{https://www.genome.jp/kegg/docs/xml/} for more details about
'relation' as well as other elements in KGML files.
}
\value{
An object of \code{link{KEGGEdge}}.
}
\references{\url{http://www.genome.jp/kegg/docs/xml/}}
\references{\url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang <jitao_david.zhang@roche.com> }
\seealso{\code{\link{KEGGEdge-class}}, \code{\link{parseEntry}}}
\keyword{ IO }
2 changes: 1 addition & 1 deletion man/splitKEGGgroup.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ splitKEGGgroup(pathway)
\value{
An object of \code{\link{KEGGPathway-class}}
}
\references{KGML Manual \url{http://www.genome.jp/kegg/docs/xml/}}
\references{KGML Manual \url{https://www.genome.jp/kegg/docs/xml/}}
\author{ Jitao David Zhang \url{mailto:jitao_david.zhang@roche.com} }
\seealso{ \code{\link{KEGGpathway2Graph}} }
\examples{
Expand Down
2 changes: 1 addition & 1 deletion man/translateKEGGID2GeneID.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ translateGeneID2KEGGID(x, organism="hsa")
\arguments{
\item{x}{ KEGGID, e.g. 'hsa:1432', or Entrez Gene ID, e.g. '1432' }
\item{organism}{ Three alphabet code for organisms. The mapping
between the orgniams and codes can be found at \url{http://www.genome.jp/kegg/kegg3.html}}
between the orgniams and codes can be found at \url{https://www.genome.jp/kegg/kegg3.html}}
}
\details{
The KEGGID are unique identifiers used by KEGG PATHWAY to identify
Expand Down
2 changes: 1 addition & 1 deletion tests/kegg2graph.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ library(KEGGgraph)
library(RBGL)

## retrieve
URLbase <- "http://rest.kegg.jp/get/%s/kgml"
URLbase <- "https://rest.kegg.jp/get/%s/kgml"
ids <- c("00460", "hsa:00461", "path:hsa00453", "path:00453")
expURLs <- sprintf(URLbase,
c("hsa00460", "hsa00461", "hsa00453", "hsa00453"))
Expand Down

0 comments on commit 11a5723

Please sign in to comment.