... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/dbExtract.R |
|
2 | 3 |
\name{KGML2igraph} |
3 | 4 |
\alias{KGML2igraph} |
4 | 5 |
\title{Processes KGML files into igraph objects} |
... | ... |
@@ -7,12 +8,12 @@ KGML2igraph(filename, parse.as = c("metabolic", "signaling"), |
7 | 8 |
expand.complexes = FALSE, verbose = TRUE) |
8 | 9 |
} |
9 | 10 |
\arguments{ |
10 |
-\item{filename}{A character vector containing the KGML files to be processed. |
|
11 |
+\item{filename}{A character vector containing the KGML files to be processed. |
|
11 | 12 |
If a directory path is provided, all *.xml files in it and its subdirectories are included.} |
12 | 13 |
|
13 | 14 |
\item{parse.as}{Whether to process file into a metabolic or a signaling network.} |
14 | 15 |
|
15 |
-\item{expand.complexes}{Split protein complexes into individual gene nodes. This argument is |
|
16 |
+\item{expand.complexes}{Split protein complexes into individual gene nodes. This argument is |
|
16 | 17 |
ignored if \code{parse.as="metabolic"}} |
17 | 18 |
|
18 | 19 |
\item{verbose}{Whether to display the progress of the function.} |
... | ... |
@@ -33,8 +34,8 @@ to their corresponding substrates and products. Each reaction vertex has \code{g |
33 | 34 |
listing all genes associated with the reaction. As a general rule, reactions inherit all annotation |
34 | 35 |
attributes of its catalyzig genes. |
35 | 36 |
|
36 |
-Signaling network have genes as vertices and edges represent interactions, such as activiation / inhibition. |
|
37 |
-Genes participating in successive reactions are also connected. Signaling parsing method processes <ECrel>, <PPrel> |
|
37 |
+Signaling network have genes as vertices and edges represent interactions, such as activiation / inhibition. |
|
38 |
+Genes participating in successive reactions are also connected. Signaling parsing method processes <ECrel>, <PPrel> |
|
38 | 39 |
and <PCrel> interactions from KGML files. |
39 | 40 |
|
40 | 41 |
To generate a genome scale network, simply provide a list of files to be parsed, or put all |
... | ... |
@@ -42,9 +43,9 @@ file in a directory, as pass the directory path as \code{filename} |
42 | 43 |
} |
43 | 44 |
\examples{ |
44 | 45 |
if(is.loaded("readkgmlfile")){ # This is false if libxml2 wasn't available at installation. |
45 |
- filename <- system.file("extdata", "hsa00860.xml", package="NetPathMiner") |
|
46 |
+ filename <- system.file("extdata", "hsa00860.xml", package="NetPathMiner") |
|
46 | 47 |
|
47 |
- # Process KGML file as a metabolic network |
|
48 |
+ # Process KGML file as a metabolic network |
|
48 | 49 |
g <- KGML2igraph(filename) |
49 | 50 |
plotNetwork(g) |
50 | 51 |
|
... | ... |
@@ -52,12 +53,13 @@ if(is.loaded("readkgmlfile")){ # This is false if libxml2 wasn't available at in |
52 | 53 |
g <- KGML2igraph(filename, parse.as="signaling", expand.complexes=TRUE) |
53 | 54 |
plotNetwork(g) |
54 | 55 |
} |
56 |
+ |
|
55 | 57 |
} |
56 | 58 |
\author{ |
57 | 59 |
Ahmed Mohamed |
58 | 60 |
} |
59 | 61 |
\seealso{ |
60 |
-Other Database extraction methods: \code{\link{SBML2igraph}}; |
|
62 |
+Other Database extraction methods: \code{\link{SBML2igraph}}, |
|
61 | 63 |
\code{\link{biopax2igraph}} |
62 | 64 |
} |
63 | 65 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netWeight.R |
|
2 | 3 |
\name{stdAttrNames} |
3 | 4 |
\alias{fetchAttribute} |
4 | 5 |
\alias{stdAttrNames} |
... | ... |
@@ -12,7 +13,7 @@ fetchAttribute(graph, organism = "Homo sapiens", target.attr, source.attr, |
12 | 13 |
\arguments{ |
13 | 14 |
\item{graph}{An annotated igraph object.} |
14 | 15 |
|
15 |
-\item{return.value}{Specify whether to return the names of matched standard annotations, or modify the |
|
16 |
+\item{return.value}{Specify whether to return the names of matched standard annotations, or modify the |
|
16 | 17 |
graph attribute names to match the standards.} |
17 | 18 |
|
18 | 19 |
\item{organism}{The latin name of the organism (Case-sensitive).} |
... | ... |
@@ -25,7 +26,7 @@ graph attribute names to match the standards.} |
25 | 26 |
} |
26 | 27 |
\value{ |
27 | 28 |
For \code{stdAttrNames}, \code{matches} gives the original attribute names and their MIRIAM version. |
28 |
-Since this is done by simple text matching, mismatches may occur for ambiguous annotations (such as GO, EC number). |
|
29 |
+Since this is done by simple text matching, mismatches may occur for ambiguous annotations (such as GO, EC number). |
|
29 | 30 |
\code{graph} returns the input graph with attribute names standardized. |
30 | 31 |
|
31 | 32 |
For \code{fetchAttribute}, the input \code{graph} with the fetched attribute mapped to vertices. |
... | ... |
@@ -34,21 +35,21 @@ For \code{fetchAttribute}, the input \code{graph} with the fetched attribute map |
34 | 35 |
These functions deals with conforming with MIRIAM annotation guidelines, conversion and mapping between MIRIAM identifiers. |
35 | 36 |
} |
36 | 37 |
\examples{ |
37 |
-data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
38 |
+ data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
38 | 39 |
## Modify attribute names to match MIRIAM standard annotations. |
39 | 40 |
graph <- stdAttrNames(ex_kgml_sig, "graph") |
40 |
-# Use Attribute fetcher to get affymetrix probeset IDs for network vertices. |
|
41 |
+ |
|
42 |
+ # Use Attribute fetcher to get affymetrix probeset IDs for network vertices. |
|
41 | 43 |
\dontrun{ |
42 |
- graph <- fetchAttribute(graph, organism="Homo sapiens", |
|
44 |
+ graph <- fetchAttribute(graph, organism="Homo sapiens", |
|
43 | 45 |
target.attr="miriam.affy.probeset") |
44 | 46 |
} |
47 |
+ |
|
45 | 48 |
} |
46 | 49 |
\author{ |
47 | 50 |
Ahmed Mohamed |
48 | 51 |
} |
49 | 52 |
\seealso{ |
50 |
-Other Attribute handling methods: \code{\link{getAttrNames}}, |
|
51 |
- \code{\link{getAttrStatus}}, \code{\link{getAttribute}}, |
|
52 |
- \code{\link{rmAttribute}}, \code{\link{setAttribute}} |
|
53 |
+Other Attribute handling methods: \code{\link{getAttrStatus}} |
|
53 | 54 |
} |
54 | 55 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netWeight.R |
|
2 | 3 |
\name{NPMdefaults} |
3 | 4 |
\alias{NPMdefaults} |
4 | 5 |
\title{Default values for NetPathMiner} |
... | ... |
@@ -17,15 +18,16 @@ This function gets a NetPathMiner default value for a variable. |
17 | 18 |
\details{ |
18 | 19 |
NetPathMiner defines the following defaults: |
19 | 20 |
\itemize{ |
20 |
- \item small.comp.ls Dataframe of ubiquitous metabolites. Used by \code{\link{rmSmallCompounds}}. |
|
21 |
+ \item small.comp.ls Dataframe of ubiquitous metabolites. Used by \code{\link{rmSmallCompounds}}. |
|
21 | 22 |
\item bridge Dataframe of attributes supported by Brigde Database. Used by \code{\link{fetchAttribute}}. |
22 | 23 |
\item bridge.organisms A list of bridge supported organisms. Used by \code{\link{fetchAttribute}}. |
23 | 24 |
\item bridge.web The base URL for Brigde Database webservices. Used by \code{\link{fetchAttribute}}. |
24 | 25 |
} |
25 | 26 |
} |
26 | 27 |
\examples{ |
27 |
-# Get the default list of small compounds (uniquitous metabolites). |
|
28 |
+ # Get the default list of small compounds (uniquitous metabolites). |
|
28 | 29 |
NPMdefaults("small.comp.ls") |
30 |
+ |
|
29 | 31 |
} |
30 | 32 |
\author{ |
31 | 33 |
Ahmed Mohamed |
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/NPM-package.R |
|
2 | 3 |
\docType{package} |
3 | 4 |
\name{NetPathMiner-package} |
4 | 5 |
\alias{NPM} |
... | ... |
@@ -7,10 +8,10 @@ |
7 | 8 |
\title{General framework for network extraction, path mining.} |
8 | 9 |
\description{ |
9 | 10 |
NetPathMiner implements a flexible module-based process flow for network path mining and visualization, |
10 |
-which can be fully inte-grated with user-customized functions. |
|
11 |
+which can be fully inte-grated with user-customized functions. |
|
11 | 12 |
NetPathMiner supports construction of various types of genome scale networks from KGML, SBML and BioPAX |
12 |
-formats, enabling its utility to most common pathway databases. |
|
13 |
-NetPathMiner also provides different visualization techniques to facilitate the analysis of even |
|
13 |
+formats, enabling its utility to most common pathway databases. |
|
14 |
+NetPathMiner also provides different visualization techniques to facilitate the analysis of even |
|
14 | 15 |
thousands of output paths. |
15 | 16 |
} |
16 | 17 |
\author{ |
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/dbExtract.R |
|
2 | 3 |
\name{SBML2igraph} |
3 | 4 |
\alias{SBML2igraph} |
4 | 5 |
\title{Processes SBML files into igraph objects} |
... | ... |
@@ -7,7 +8,7 @@ SBML2igraph(filename, parse.as = c("metabolic", "signaling"), |
7 | 8 |
miriam.attr = "all", gene.attr, expand.complexes, verbose = TRUE) |
8 | 9 |
} |
9 | 10 |
\arguments{ |
10 |
-\item{filename}{A character vector containing the SBML files to be processed. If a directory path |
|
11 |
+\item{filename}{A character vector containing the SBML files to be processed. If a directory path |
|
11 | 12 |
is provided, all *.xml and *.sbml files in it and its subdirectories are included.} |
12 | 13 |
|
13 | 14 |
\item{parse.as}{Whether to process file into a metabolic or a signaling network.} |
... | ... |
@@ -16,10 +17,10 @@ is provided, all *.xml and *.sbml files in it and its subdirectories are include |
16 | 17 |
written in MIRIAM guidelines (see Details) are extracted (Default). If \code{"none"}, then no attributes |
17 | 18 |
are extracted. Otherwise, only attributes matching those specified are extracted.} |
18 | 19 |
|
19 |
-\item{gene.attr}{An attribute to distinguish \code{species} representing genes from those |
|
20 |
+\item{gene.attr}{An attribute to distinguish \code{species} representing genes from those |
|
20 | 21 |
representing small molecules (see Details). Ignored if \code{parse.as="metabolic"}.} |
21 | 22 |
|
22 |
-\item{expand.complexes}{Split protein complexes into individual gene nodes. Ignored if |
|
23 |
+\item{expand.complexes}{Split protein complexes into individual gene nodes. Ignored if |
|
23 | 24 |
\code{parse.as="metabolic"}, or when \code{gene.attr} is not provided.} |
24 | 25 |
|
25 | 26 |
\item{verbose}{Whether to display the progress of the function.} |
... | ... |
@@ -40,7 +41,7 @@ to their corresponding substrates and products (\code{ListOfSpecies}). Each reac |
40 | 41 |
listing all \code{modifiers} of this reaction. As a general rule, reactions inherit all annotation |
41 | 42 |
attributes of its catalyzig genes. |
42 | 43 |
|
43 |
-Signaling network have genes as vertices and edges represent interactions. Since SBML format may |
|
44 |
+Signaling network have genes as vertices and edges represent interactions. Since SBML format may |
|
44 | 45 |
represent singling events as \code{reaction}, all species are assumed to be genes (rather than small |
45 | 46 |
molecules). For a simple path \code{S0 -> R1 -> S1}, in signaling network, the path will be |
46 | 47 |
\code{S0 -> M(R1) -> S1} where \code{M(R1)} is R1 modifier(s). To ditiguish gene species from small |
... | ... |
@@ -54,21 +55,21 @@ by specifying \code{miriam.attr}. |
54 | 55 |
To generate a genome scale network, simply provide a list of files to be parsed, or put all |
55 | 56 |
file in a directory, as pass the directory path as \code{filename} |
56 | 57 |
|
57 |
-Note: This function requires libSBML installed (Please see the installation instructions in the Vignette). |
|
58 |
-Some SBML level-3 files may requires additional libraries also (An infomative error will be displayed when |
|
59 |
-parsing such files). Please visit \url{http://sbml.org/Documents/Specifications/SBML_Level_3/Packages} for |
|
58 |
+Note: This function requires libSBML installed (Please see the installation instructions in the Vignette). |
|
59 |
+Some SBML level-3 files may requires additional libraries also (An infomative error will be displayed when |
|
60 |
+parsing such files). Please visit \url{http://sbml.org/Documents/Specifications/SBML_Level_3/Packages} for |
|
60 | 61 |
more information. |
61 | 62 |
} |
62 | 63 |
\examples{ |
63 | 64 |
if(is.loaded("readsbmlfile")){ # This is false if libSBML wasn't available at installation. |
64 |
- filename <- system.file("extdata", "porphyrin.sbml", package="NetPathMiner") |
|
65 |
+ filename <- system.file("extdata", "porphyrin.sbml", package="NetPathMiner") |
|
65 | 66 |
|
66 |
- # Process SBML file as a metabolic network |
|
67 |
+ # Process SBML file as a metabolic network |
|
67 | 68 |
g <- SBML2igraph(filename) |
68 | 69 |
plotNetwork(g) |
69 | 70 |
|
70 | 71 |
# Process SBML file as a signaling network |
71 |
- g <- SBML2igraph(filename, parse.as="signaling", |
|
72 |
+ g <- SBML2igraph(filename, parse.as="signaling", |
|
72 | 73 |
gene.attr="miriam.uniprot",expand.complexes=TRUE) |
73 | 74 |
dev.new() |
74 | 75 |
plotNetwork(g) |
... | ... |
@@ -78,7 +79,7 @@ if(is.loaded("readsbmlfile")){ # This is false if libSBML wasn't available at in |
78 | 79 |
Ahmed Mohamed |
79 | 80 |
} |
80 | 81 |
\seealso{ |
81 |
-Other Database extraction methods: \code{\link{KGML2igraph}}; |
|
82 |
+Other Database extraction methods: \code{\link{KGML2igraph}}, |
|
82 | 83 |
\code{\link{biopax2igraph}} |
83 | 84 |
} |
84 | 85 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netWeight.R |
|
2 | 3 |
\name{assignEdgeWeights} |
3 | 4 |
\alias{assignEdgeWeights} |
4 | 5 |
\title{Assigning weights to network edges} |
... | ... |
@@ -12,25 +13,25 @@ assignEdgeWeights(microarray, graph, use.attr, y, weight.method = "cor", |
12 | 13 |
|
13 | 14 |
\item{graph}{An annotated igraph object.} |
14 | 15 |
|
15 |
-\item{use.attr}{An attribute name to map \code{microarray} rows (genes) to graph vertices. The attribute must |
|
16 |
-be annotated in \code{graph}, and the values correspond to \code{rownames} of \code{microarray}. You can check the coverage and |
|
16 |
+\item{use.attr}{An attribute name to map \code{microarray} rows (genes) to graph vertices. The attribute must |
|
17 |
+be annotated in \code{graph}, and the values correspond to \code{rownames} of \code{microarray}. You can check the coverage and |
|
17 | 18 |
if there are complex vertices using \code{\link{getAttrStatus}}. You can eliminate complexes using \code{\link{expandComplexes}}.} |
18 | 19 |
|
19 | 20 |
\item{y}{Sample labels, given as a factor or a character vector. This must be the same size as the columns of \code{microarray}} |
20 | 21 |
|
21 |
-\item{weight.method}{A function, or a string indicating the name of the function to be used to compute the edge weights. |
|
22 |
-The function is provided with 2 numerical verctors (2 rows from \code{microarray}), and it should return a single numerical |
|
22 |
+\item{weight.method}{A function, or a string indicating the name of the function to be used to compute the edge weights. |
|
23 |
+The function is provided with 2 numerical verctors (2 rows from \code{microarray}), and it should return a single numerical |
|
23 | 24 |
value (or \code{NA}). The default computes Pearson's correlation.} |
24 | 25 |
|
25 | 26 |
\item{complex.method}{A function, or a string indicating the name of the function to be used in weighting edges connecting complexes. |
26 |
-If a vertex has >1 attribute value, all possible pairwise weights are first computed, and given to \code{complex.method}. The default |
|
27 |
+If a vertex has >1 attribute value, all possible pairwise weights are first computed, and given to \code{complex.method}. The default |
|
27 | 28 |
function is \code{\link[base]{max}}.} |
28 | 29 |
|
29 | 30 |
\item{missing.method}{A function, or a string indicating the name of the function to be used in weighting edges when one of the vertices |
30 | 31 |
lack expression data. The function is passed all edge weights on the graph. Default is \code{\link[stats]{median}}.} |
31 | 32 |
|
32 |
-\item{same.gene.penalty}{A numerical value to be assigned when 2 adjacent vertices have the same attribute value, since correlation and |
|
33 |
-similarity measure will give perfect scores. Alternatively, \code{same.gene.penalty} can be a function, computing the penalty from all |
|
33 |
+\item{same.gene.penalty}{A numerical value to be assigned when 2 adjacent vertices have the same attribute value, since correlation and |
|
34 |
+similarity measure will give perfect scores. Alternatively, \code{same.gene.penalty} can be a function, computing the penalty from all |
|
34 | 35 |
edge weights on the graph (excluding same-gene and missing values). The default is to take the \code{\link[stats]{median}}} |
35 | 36 |
|
36 | 37 |
\item{bootstrap}{An integer \code{n}, where the \code{weight.method} is perfomed on \code{n} permutations of the gene profiles, and taking |
... | ... |
@@ -39,14 +40,14 @@ the median value. Set it to \code{NA} to disable bootstrapping.} |
39 | 40 |
\item{verbose}{Print the progress of the function.} |
40 | 41 |
} |
41 | 42 |
\value{ |
42 |
-The input graph with \code{edge.weight} as an edge attribute. The attribute can be a list of weights if \code{y} labels |
|
43 |
+The input graph with \code{edge.weight} as an edge attribute. The attribute can be a list of weights if \code{y} labels |
|
43 | 44 |
were provided. |
44 | 45 |
} |
45 | 46 |
\description{ |
46 | 47 |
This function computes edge weights based on a gene expression profile. |
47 | 48 |
} |
48 | 49 |
\examples{ |
49 |
-## Conver a metabolic network to a reaction network. |
|
50 |
+ ## Convert a metabolic network to a reaction network. |
|
50 | 51 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
51 | 52 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
52 | 53 |
|
... | ... |
@@ -54,16 +55,17 @@ This function computes edge weights based on a gene expression profile. |
54 | 55 |
# Calculate Pearson's correlation. |
55 | 56 |
data(ex_microarray) # Part of ALL dataset. |
56 | 57 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
57 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
58 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
58 | 59 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
59 |
- |
|
60 |
- # Using Spearman correlation, assigning missing edges to -1 |
|
60 |
+ |
|
61 |
+ # Using Spearman correlation, assigning missing edges to -1 |
|
61 | 62 |
\dontrun{ |
62 |
- assignEdgeWeights(microarray, graph, use.attr="miriam.affy.probeset", |
|
63 |
- y=factor(colnames(microarray)), |
|
64 |
- weight.method = function(x1,x2) cor(x1,x2, method="spearman), |
|
65 |
- missing.method = -1) |
|
63 |
+ assignEdgeWeights(microarray, graph, use.attr="miriam.affy.probeset", |
|
64 |
+ y=factor(colnames(microarray)), |
|
65 |
+ weight.method = function(x1,x2) cor(x1,x2, method="spearman"), |
|
66 |
+ missing.method = -1) |
|
66 | 67 |
} |
68 |
+ |
|
67 | 69 |
} |
68 | 70 |
\author{ |
69 | 71 |
Ahmed Mohamed |
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/dbExtract.R |
|
2 | 3 |
\name{biopax2igraph} |
3 | 4 |
\alias{biopax2igraph} |
4 | 5 |
\title{Processes BioPAX objects into igraph objects} |
... | ... |
@@ -11,10 +12,10 @@ biopax2igraph(biopax, parse.as = c("metabolic", "signaling"), |
11 | 12 |
|
12 | 13 |
\item{parse.as}{Whether to process file into a metabolic or a signaling network.} |
13 | 14 |
|
14 |
-\item{expand.complexes}{Split protein complexes into individual gene nodes. Ignored if |
|
15 |
+\item{expand.complexes}{Split protein complexes into individual gene nodes. Ignored if |
|
15 | 16 |
\code{parse.as="metabolic"}.} |
16 | 17 |
|
17 |
-\item{inc.sm.molecules}{Include small molecules that are participating in signaling events. Ignored if |
|
18 |
+\item{inc.sm.molecules}{Include small molecules that are participating in signaling events. Ignored if |
|
18 | 19 |
\code{parse.as="metabolic"}.} |
19 | 20 |
|
20 | 21 |
\item{verbose}{Whether to display the progress of the function.} |
... | ... |
@@ -37,7 +38,7 @@ to their corresponding \code{Left}s and \code{Right}s. Each reaction vertex has |
37 | 38 |
listing all \code{Catalysis} relationships of this reaction. As a general rule, reactions inherit all annotation |
38 | 39 |
attributes of its catalyzig genes. |
39 | 40 |
|
40 |
-Signaling network have genes as vertices and edges represent interactions, such as activiation / inhibition. |
|
41 |
+Signaling network have genes as vertices and edges represent interactions, such as activiation / inhibition. |
|
41 | 42 |
Genes participating in successive reactions are also connected. Signaling interactions are constructed from |
42 | 43 |
\code{Control} classes, where edges are drawn from \code{controller} to \code{controlled}. |
43 | 44 |
|
... | ... |
@@ -47,7 +48,7 @@ MIRIAM guidelines (\code{miraim.db}, where db is the database name). |
47 | 48 |
\examples{ |
48 | 49 |
if(require(rBiopaxParser)){ |
49 | 50 |
data(ex_biopax) |
50 |
- # Process biopax as a metabolic network |
|
51 |
+ # Process biopax as a metabolic network |
|
51 | 52 |
g <- biopax2igraph(ex_biopax) |
52 | 53 |
plotNetwork(g) |
53 | 54 |
|
... | ... |
@@ -59,7 +60,7 @@ if(require(rBiopaxParser)){ |
59 | 60 |
Ahmed Mohamed |
60 | 61 |
} |
61 | 62 |
\seealso{ |
62 |
-Other Database extraction methods: \code{\link{KGML2igraph}}; |
|
63 |
+Other Database extraction methods: \code{\link{KGML2igraph}}, |
|
63 | 64 |
\code{\link{SBML2igraph}} |
64 | 65 |
} |
65 | 66 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/plotPath.R |
|
2 | 3 |
\name{colorVertexByAttr} |
3 | 4 |
\alias{colorVertexByAttr} |
4 | 5 |
\title{Computes colors for vertices according to their attributes.} |
... | ... |
@@ -8,7 +9,7 @@ colorVertexByAttr(graph, attr.name, col.palette = palette()) |
8 | 9 |
\arguments{ |
9 | 10 |
\item{graph}{An annotated igraph object.} |
10 | 11 |
|
11 |
-\item{attr.name}{The attribute name (ex: "pathway") by which vertices will be colored. |
|
12 |
+\item{attr.name}{The attribute name (ex: "pathway") by which vertices will be colored. |
|
12 | 13 |
Complex attributes, where a vertex belongs to more than one group, are supported.} |
13 | 14 |
|
14 | 15 |
\item{col.palette}{A color palette, or a palette generating function (ex: \preformatted{col.palette=rainbow}).} |
... | ... |
@@ -21,22 +22,21 @@ This function returns a list of colors for vertices, assigned similar colors if |
21 | 22 |
(ex: in the same pathway, etc). |
22 | 23 |
} |
23 | 24 |
\examples{ |
24 |
-data("ex_kgml_sig") |
|
25 |
- v.colors <- colorVertexByAttr(ex_kgml_sig, "pathway") |
|
25 |
+ data("ex_kgml_sig") |
|
26 |
+ v.colors <- colorVertexByAttr(ex_kgml_sig, "pathway") |
|
26 | 27 |
plotNetwork(ex_kgml_sig, vertex.color=v.colors) |
28 |
+ |
|
27 | 29 |
} |
28 | 30 |
\author{ |
29 | 31 |
Ahmed Mohamed |
30 | 32 |
} |
31 | 33 |
\seealso{ |
32 |
-Other Plotting methods: \code{\link{layoutVertexByAttr}}; |
|
33 |
- \code{\link{plotAllNetworks}}; |
|
34 |
- \code{\link{plotClassifierROC}}; |
|
34 |
+Other Plotting methods: \code{\link{layoutVertexByAttr}}, |
|
35 |
+ \code{\link{plotAllNetworks}}, |
|
36 |
+ \code{\link{plotClassifierROC}}, |
|
35 | 37 |
\code{\link{plotClusterMatrix}}, |
36 |
- \code{\link{plotClusterProbs}}, |
|
37 |
- \code{\link{plotClusters}}; \code{\link{plotCytoscape}}, |
|
38 |
- \code{\link{plotCytoscapeGML}}; |
|
39 |
- \code{\link{plotNetwork}}; |
|
40 |
- \code{\link{plotPathClassifier}}; \code{\link{plotPaths}} |
|
38 |
+ \code{\link{plotCytoscapeGML}}, |
|
39 |
+ \code{\link{plotNetwork}}, |
|
40 |
+ \code{\link{plotPathClassifier}}, \code{\link{plotPaths}} |
|
41 | 41 |
} |
42 | 42 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/NPM-package.R |
|
2 | 3 |
\docType{data} |
3 | 4 |
\name{ex_biopax} |
4 | 5 |
\alias{ex_biopax} |
... | ... |
@@ -10,5 +11,6 @@ A dataset containing Porphyrin metabolism pathway in Biopax Level 3 and parsed w |
10 | 11 |
\examples{ |
11 | 12 |
data(ex_biopax) |
12 | 13 |
ex_biopax |
14 |
+ |
|
13 | 15 |
} |
14 | 16 |
|
... | ... |
@@ -1,14 +1,16 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/NPM-package.R |
|
2 | 3 |
\docType{data} |
3 | 4 |
\name{ex_kgml_sig} |
4 | 5 |
\alias{ex_kgml_sig} |
5 | 6 |
\title{Singaling network from KGML example} |
6 | 7 |
\description{ |
7 |
-An example igraph object representing Ras and chemokine signaling pathways in human |
|
8 |
+An example igraph object representing Ras and chemokine signaling pathways in human |
|
8 | 9 |
extracted from KGML files. |
9 | 10 |
} |
10 | 11 |
\examples{ |
11 | 12 |
data(ex_kgml_sig) |
12 | 13 |
plotNetwork(ex_kgml_sig, vertex.color="pathway") |
14 |
+ |
|
13 | 15 |
} |
14 | 16 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/NPM-package.R |
|
2 | 3 |
\docType{data} |
3 | 4 |
\name{ex_microarray} |
4 | 5 |
\alias{ex_microarray} |
... | ... |
@@ -8,5 +9,6 @@ An microarray data example. This is part of the ALL dataset, for demonstration p |
8 | 9 |
} |
9 | 10 |
\examples{ |
10 | 11 |
data(ex_microarray) |
12 |
+ |
|
11 | 13 |
} |
12 | 14 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/NPM-package.R |
|
2 | 3 |
\docType{data} |
3 | 4 |
\name{ex_sbml} |
4 | 5 |
\alias{ex_sbml} |
... | ... |
@@ -10,5 +11,6 @@ metabolism extracted from SBML file from Reactome database. |
10 | 11 |
\examples{ |
11 | 12 |
data(ex_sbml) |
12 | 13 |
plotNetwork(ex_sbml, vertex.color="compartment.name") |
14 |
+ |
|
13 | 15 |
} |
14 | 16 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathRank.R |
|
2 | 3 |
\name{extractPathNetwork} |
3 | 4 |
\alias{extractPathNetwork} |
4 | 5 |
\title{Creates a subnetwork from a ranked path list} |
... | ... |
@@ -18,7 +19,7 @@ labels (sample categories), a subnetwork is returned for each label. |
18 | 19 |
Creates a subnetwork from a ranked path list generated by \code{\link{pathRanker}}. |
19 | 20 |
} |
20 | 21 |
\examples{ |
21 |
-## Prepare a weighted reaction network. |
|
22 |
+ ## Prepare a weighted reaction network. |
|
22 | 23 |
## Conver a metabolic network to a reaction network. |
23 | 24 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
24 | 25 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -27,11 +28,11 @@ Creates a subnetwork from a ranked path list generated by \code{\link{pathRanker |
27 | 28 |
# Calculate Pearson's correlation. |
28 | 29 |
data(ex_microarray) # Part of ALL dataset. |
29 | 30 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
30 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
31 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
31 | 32 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
32 | 33 |
|
33 | 34 |
## Get ranked paths using probabilistic shortest paths. |
34 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
35 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
35 | 36 |
K=20, minPathSize=6) |
36 | 37 |
|
37 | 38 |
## Get the subnetwork of paths in reaction graph. |
... | ... |
@@ -39,12 +40,13 @@ Creates a subnetwork from a ranked path list generated by \code{\link{pathRanker |
39 | 40 |
|
40 | 41 |
## Get the subnetwork of paths in the original metabolic graph. |
41 | 42 |
metabolic.sub <- getPathsAsEIDs(ranked.p, ex_sbml) |
43 |
+ |
|
42 | 44 |
} |
43 | 45 |
\author{ |
44 | 46 |
Ahmed Mohamed |
45 | 47 |
} |
46 | 48 |
\seealso{ |
47 |
-Other Path ranking methods: \code{\link{getPathsAsEIDs}}; |
|
48 |
- \code{\link{pathRanker}}; \code{\link{samplePaths}} |
|
49 |
+Other Path ranking methods: \code{\link{getPathsAsEIDs}}, |
|
50 |
+ \code{\link{pathRanker}}, \code{\link{samplePaths}} |
|
49 | 51 |
} |
50 | 52 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netWeight.R |
|
2 | 3 |
\name{getAttrStatus} |
3 | 4 |
\alias{getAttrNames} |
4 | 5 |
\alias{getAttrStatus} |
... | ... |
@@ -27,7 +28,7 @@ rmAttribute(graph, attr.name) |
27 | 28 |
\item{attr.value}{A list of attribute values. This must be the same size as the number of vertices.} |
28 | 29 |
} |
29 | 30 |
\value{ |
30 |
-For \code{getAttrStatus}, a dataframe summarizing the number of vertices with no (\code{missing}), one (\code{single}) |
|
31 |
+For \code{getAttrStatus}, a dataframe summarizing the number of vertices with no (\code{missing}), one (\code{single}) |
|
31 | 32 |
or more than one (\code{complex}) attribute value. The coverage% is also reported to each attribute. |
32 | 33 |
|
33 | 34 |
For \code{getAttrNames}, a character vector of attribute names matching the pattern. |
... | ... |
@@ -48,25 +49,26 @@ a single \code{attr}. This is not to interfer with \code{\link[igraph]{attribute |
48 | 49 |
All functions here target NetPathMiner annotations only. |
49 | 50 |
} |
50 | 51 |
\examples{ |
51 |
-data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
52 |
+ data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
52 | 53 |
|
53 | 54 |
# Get status of attribute "pathway" only |
54 | 55 |
getAttrStatus(ex_kgml_sig, "^pathway$") |
55 |
- |
|
56 |
+ |
|
56 | 57 |
# Get status of all attributes starting with "pathway" and "miriam" keywords |
57 | 58 |
getAttrStatus(ex_kgml_sig, "(^miriam)|(^pathway)") |
58 |
-# Get all attribute names containing "miriam" |
|
59 |
+ |
|
60 |
+ # Get all attribute names containing "miriam" |
|
59 | 61 |
getAttrNames(ex_kgml_sig, "miriam") |
60 |
-# Get all attribute names containing "miriam" |
|
62 |
+ # Get all attribute names containing "miriam" |
|
61 | 63 |
getAttribute(ex_kgml_sig, "miriam.ncbigene") |
62 |
-# Remove an attribute from graph |
|
64 |
+ |
|
65 |
+ # Remove an attribute from graph |
|
63 | 66 |
graph <- rmAttribute(ex_kgml_sig, "miriam.ncbigene") |
64 | 67 |
} |
65 | 68 |
\author{ |
66 | 69 |
Ahmed Mohamed |
67 | 70 |
} |
68 | 71 |
\seealso{ |
69 |
-Other Attribute handling methods: \code{\link{fetchAttribute}}, |
|
70 |
- \code{\link{stdAttrNames}} |
|
72 |
+Other Attribute handling methods: \code{\link{stdAttrNames}} |
|
71 | 73 |
} |
72 | 74 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netWeight.R |
|
2 | 3 |
\name{getGeneSetNetworks} |
3 | 4 |
\alias{getGeneSetNetworks} |
4 | 5 |
\title{Generate geneset networks from an annotated network.} |
... | ... |
@@ -11,7 +12,7 @@ getGeneSetNetworks(graph, use.attr = "pathway", format = c("list", |
11 | 12 |
|
12 | 13 |
\item{use.attr}{The attribute by which vertices are grouped (tepically pathway, or GO)} |
13 | 14 |
|
14 |
-\item{format}{The output format. If "list" is specified, a list of subgraphs are returned (default). |
|
15 |
+\item{format}{The output format. If "list" is specified, a list of subgraphs are returned (default). |
|
15 | 16 |
If "pathway-class" is specified, a list of pathway-class objects are returned. Pathway-class |
16 | 17 |
is used by graphite package to run several methods of topology-based enrichment analyses.} |
17 | 18 |
} |
... | ... |
@@ -23,25 +24,26 @@ This function generates geneset networks based on a given netowrk, by grouping v |
23 | 24 |
common attributes (in the same pathway or compartment). |
24 | 25 |
} |
25 | 26 |
\examples{ |
26 |
-data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
27 |
+ data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
27 | 28 |
genesetnets <- getGeneSetNetworks(ex_kgml_sig, use.attr="pathway") |
28 | 29 |
|
29 | 30 |
# Integration with graphite package |
30 | 31 |
\dontrun{ |
31 | 32 |
if(require(graphite) & require(clipper) & require(ALL)){ |
32 |
- genesetnets <- getGeneSetNetworks(ex_kgml_sig, |
|
33 |
+ genesetnets <- getGeneSetNetworks(ex_kgml_sig, |
|
33 | 34 |
use.attr="pathway", format="pathway-class") |
34 |
- path <- convertIdentifiers(genesetnets$`Chemokine signaling pathway`, |
|
35 |
+ path <- convertIdentifiers(genesetnets$`Chemokine signaling pathway`, |
|
35 | 36 |
"entrez") |
36 |
- genes <- nodes(path) |
|
37 |
- data(ALL) |
|
38 |
- all <- as.matrix(exprs(ALL[1:length(genes),1:20])) |
|
39 |
- classes <- c(rep(1,10), rep(2,10)) |
|
40 |
- rownames(all) <- genes |
|
41 |
- |
|
42 |
- runClipper(path, all, classes, "mean", pathThr=0.1) |
|
37 |
+ genes <- nodes(path) |
|
38 |
+ data(ALL) |
|
39 |
+ all <- as.matrix(exprs(ALL[1:length(genes),1:20])) |
|
40 |
+ classes <- c(rep(1,10), rep(2,10)) |
|
41 |
+ rownames(all) <- genes |
|
42 |
+ |
|
43 |
+ runClipper(path, all, classes, "mean", pathThr=0.1) |
|
43 | 44 |
} |
44 | 45 |
} |
46 |
+ |
|
45 | 47 |
} |
46 | 48 |
\author{ |
47 | 49 |
Ahmed Mohamed |
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netWeight.R |
|
2 | 3 |
\name{getGeneSets} |
3 | 4 |
\alias{getGeneSets} |
4 | 5 |
\title{Generate genesets from an annotated network.} |
... | ... |
@@ -24,7 +25,7 @@ common attributes (in the same pathway or compartment). Genes associated with ea |
24 | 25 |
can be specified through \code{gene.attr} argument. |
25 | 26 |
} |
26 | 27 |
\examples{ |
27 |
-data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
28 |
+ data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
|
28 | 29 |
genesets <- getGeneSets(ex_kgml_sig, use.attr="pathway", gene.attr="miriam.ncbigene") |
29 | 30 |
|
30 | 31 |
|
... | ... |
@@ -38,6 +39,7 @@ data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
38 | 39 |
# Create genesets using compartment information |
39 | 40 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
40 | 41 |
genesets <- getGeneSets(ex_sbml, use.attr="compartment.name", gene.attr="miriam.uniprot") |
42 |
+ |
|
41 | 43 |
} |
42 | 44 |
\author{ |
43 | 45 |
Ahmed Mohamed |
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathRank.R |
|
2 | 3 |
\name{getPathsAsEIDs} |
3 | 4 |
\alias{getPathsAsEIDs} |
4 | 5 |
\title{Convert a ranked path list to edge ids of a graph} |
... | ... |
@@ -19,7 +20,7 @@ a different representation (for example matching path from a reaction network to |
19 | 20 |
edges on a metabolic network). |
20 | 21 |
} |
21 | 22 |
\examples{ |
22 |
-## Prepare a weighted reaction network. |
|
23 |
+ ## Prepare a weighted reaction network. |
|
23 | 24 |
## Conver a metabolic network to a reaction network. |
24 | 25 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
25 | 26 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -28,24 +29,25 @@ edges on a metabolic network). |
28 | 29 |
# Calculate Pearson's correlation. |
29 | 30 |
data(ex_microarray) # Part of ALL dataset. |
30 | 31 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
31 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
32 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
32 | 33 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
33 | 34 |
|
34 | 35 |
## Get ranked paths using probabilistic shortest paths. |
35 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
36 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
36 | 37 |
K=20, minPathSize=6) |
37 |
- |
|
38 |
+ |
|
38 | 39 |
## Get the edge ids along paths in the reaction graph. |
39 | 40 |
path.eids <- getPathsAsEIDs(ranked.p, rgraph) |
40 | 41 |
|
41 | 42 |
## Get the edge ids along paths in the original metabolic graph. |
42 | 43 |
path.eids <- getPathsAsEIDs(ranked.p, ex_sbml) |
44 |
+ |
|
43 | 45 |
} |
44 | 46 |
\author{ |
45 | 47 |
Ahmed Mohamed |
46 | 48 |
} |
47 | 49 |
\seealso{ |
48 |
-Other Path ranking methods: \code{\link{extractPathNetwork}}; |
|
49 |
- \code{\link{pathRanker}}; \code{\link{samplePaths}} |
|
50 |
+Other Path ranking methods: \code{\link{extractPathNetwork}}, |
|
51 |
+ \code{\link{pathRanker}}, \code{\link{samplePaths}} |
|
50 | 52 |
} |
51 | 53 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/plotPath.R |
|
2 | 3 |
\name{layoutVertexByAttr} |
3 | 4 |
\alias{layoutVertexByAttr} |
4 | 5 |
\title{A graph layout function, which groups vertices by attribute.} |
... | ... |
@@ -11,10 +12,10 @@ layoutVertexByAttr(graph, attr.name, cluster.strength = 1, |
11 | 12 |
|
12 | 13 |
\item{attr.name}{The attribute name by which vertices are laid out.} |
13 | 14 |
|
14 |
-\item{cluster.strength}{A number indicating tie strengths between vertices with the same attribute. |
|
15 |
+\item{cluster.strength}{A number indicating tie strengths between vertices with the same attribute. |
|
15 | 16 |
The larger it is, the closer the vertices will be.} |
16 | 17 |
|
17 |
-\item{layout}{A layout function, ideally a force-directed layout fuction, such as |
|
18 |
+\item{layout}{A layout function, ideally a force-directed layout fuction, such as |
|
18 | 19 |
\code{\link[igraph]{layout.fruchterman.reingold}} and \code{\link[igraph]{layout.kamada.kawai}}.} |
19 | 20 |
} |
20 | 21 |
\value{ |
... | ... |
@@ -25,25 +26,24 @@ This function generates a layout for igraph objects, keeping vertices with the s |
25 | 26 |
(ex: in the same pathway, etc) close to each other. |
26 | 27 |
} |
27 | 28 |
\examples{ |
28 |
-data("ex_kgml_sig") |
|
29 |
- v.layout <- layoutVertexByAttr(ex_kgml_sig, "pathway") |
|
29 |
+ data("ex_kgml_sig") |
|
30 |
+ v.layout <- layoutVertexByAttr(ex_kgml_sig, "pathway") |
|
30 | 31 |
plotNetwork(ex_kgml_sig, vertex.color="pathway", layout=v.layout) |
31 | 32 |
|
32 | 33 |
v.layout <- layoutVertexByAttr(ex_kgml_sig, "pathway", cluster.strength=5) |
33 | 34 |
plotNetwork(ex_kgml_sig, vertex.color="pathway", layout=v.layout) |
35 |
+ |
|
34 | 36 |
} |
35 | 37 |
\author{ |
36 | 38 |
Ahmed Mohamed |
37 | 39 |
} |
38 | 40 |
\seealso{ |
39 |
-Other Plotting methods: \code{\link{colorVertexByAttr}}; |
|
40 |
- \code{\link{plotAllNetworks}}; |
|
41 |
- \code{\link{plotClassifierROC}}; |
|
41 |
+Other Plotting methods: \code{\link{colorVertexByAttr}}, |
|
42 |
+ \code{\link{plotAllNetworks}}, |
|
43 |
+ \code{\link{plotClassifierROC}}, |
|
42 | 44 |
\code{\link{plotClusterMatrix}}, |
43 |
- \code{\link{plotClusterProbs}}, |
|
44 |
- \code{\link{plotClusters}}; \code{\link{plotCytoscape}}, |
|
45 |
- \code{\link{plotCytoscapeGML}}; |
|
46 |
- \code{\link{plotNetwork}}; |
|
47 |
- \code{\link{plotPathClassifier}}; \code{\link{plotPaths}} |
|
45 |
+ \code{\link{plotCytoscapeGML}}, |
|
46 |
+ \code{\link{plotNetwork}}, |
|
47 |
+ \code{\link{plotPathClassifier}}, \code{\link{plotPaths}} |
|
48 | 48 |
} |
49 | 49 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netProcess.R |
|
2 | 3 |
\name{expandComplexes} |
3 | 4 |
\alias{expandComplexes} |
4 | 5 |
\alias{makeGeneNetwork} |
... | ... |
@@ -19,7 +20,7 @@ makeGeneNetwork(graph, v.attr = "genes", keep.parent.attr = "^pathway", |
19 | 20 |
\item{keep.parent.attr}{A (List of) \code{\link{regex}} experssions representing attributes to be |
20 | 21 |
inherited by daughter vertices. If \code{"all"} is passed, all parent attributes are inherited.} |
21 | 22 |
|
22 |
-\item{expansion.method}{If \code{"duplicate"}, attribute values sharing more than one parent vertex |
|
23 |
+\item{expansion.method}{If \code{"duplicate"}, attribute values sharing more than one parent vertex |
|
23 | 24 |
are duplicated for each vertex they participate in. For exmaple, if one gene G1 catalyzes reactions |
24 | 25 |
R1, R2; then G1##R1, and G1##R2 vertices are created. If \code{"normal"} only one vertex (G1) is created, |
25 | 26 |
and inherit all R1 and R2 connections and attributes.} |
... | ... |
@@ -44,32 +45,33 @@ For example, to match a network created from Reactome to a KEGG network, you can |
44 | 45 |
vertices by "miriam.kegg.compound" attribute. |
45 | 46 |
} |
46 | 47 |
\examples{ |
47 |
-## Make a gene network from a reaction network. |
|
48 |
+ ## Make a gene network from a reaction network. |
|
48 | 49 |
data(ex_sbml) # A bipartite metbaolic network. |
49 | 50 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
50 | 51 |
ggraph <- makeGeneNetwork(rgraph) |
51 | 52 |
|
52 | 53 |
## Expand vertices into their contituent genes. |
53 | 54 |
data(ex_kgml_sig) # Ras and chemokine signaling pathways in human |
54 |
- ggraph <- expandComplexes(ex_kgml_sig, v.attr = "miriam.ncbigene", |
|
55 |
+ ggraph <- expandComplexes(ex_kgml_sig, v.attr = "miriam.ncbigene", |
|
55 | 56 |
keep.parent.attr= c("^pathway", "^compartment")) |
56 | 57 |
|
57 | 58 |
## Create a separate vertex for each compartment. This is useful in duplicating |
58 | 59 |
## metabolite vertices in a network. |
59 | 60 |
\dontrun{ |
60 |
- graph <- expandComplexes(graph, v.attr = "compartment", |
|
61 |
+ graph <- expandComplexes(graph, v.attr = "compartment", |
|
61 | 62 |
keep.parent.attr = "all", |
62 | 63 |
expansion.method = "duplicate", |
63 | 64 |
missing.method = "keep") |
64 | 65 |
} |
66 |
+ |
|
65 | 67 |
} |
66 | 68 |
\author{ |
67 | 69 |
Ahmed Mohamed |
68 | 70 |
} |
69 | 71 |
\seealso{ |
70 |
-Other Network processing methods: \code{\link{makeReactionNetwork}}; |
|
71 |
- \code{\link{rmSmallCompounds}}; |
|
72 |
- \code{\link{simplifyReactionNetwork}}; |
|
72 |
+Other Network processing methods: \code{\link{makeReactionNetwork}}, |
|
73 |
+ \code{\link{rmSmallCompounds}}, |
|
74 |
+ \code{\link{simplifyReactionNetwork}}, |
|
73 | 75 |
\code{\link{vertexDeleteReconnect}} |
74 | 76 |
} |
75 | 77 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/netProcess.R |
|
2 | 3 |
\name{makeReactionNetwork} |
3 | 4 |
\alias{makeReactionNetwork} |
4 | 5 |
\title{Convert metabolic network to reaction network.} |
... | ... |
@@ -21,18 +22,18 @@ network contains reaction nodes only, where edges indicate that a metabolite pro |
21 | 22 |
by one reaction is consumed by the other. |
22 | 23 |
} |
23 | 24 |
\examples{ |
24 |
-## Conver a metabolic network to a reaction network. |
|
25 |
+ ## Conver a metabolic network to a reaction network. |
|
25 | 26 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
26 | 27 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
28 |
+ |
|
27 | 29 |
} |
28 | 30 |
\author{ |
29 | 31 |
Ahmed Mohamed |
30 | 32 |
} |
31 | 33 |
\seealso{ |
32 | 34 |
Other Network processing methods: \code{\link{expandComplexes}}, |
33 |
- \code{\link{makeGeneNetwork}}; |
|
34 |
- \code{\link{rmSmallCompounds}}; |
|
35 |
- \code{\link{simplifyReactionNetwork}}; |
|
35 |
+ \code{\link{rmSmallCompounds}}, |
|
36 |
+ \code{\link{simplifyReactionNetwork}}, |
|
36 | 37 |
\code{\link{vertexDeleteReconnect}} |
37 | 38 |
} |
38 | 39 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathClassifier.R |
|
2 | 3 |
\name{pathClassifier} |
3 | 4 |
\alias{pathClassifier} |
4 | 5 |
\title{HME3M Markov pathway classifier.} |
... | ... |
@@ -9,7 +10,7 @@ pathClassifier(paths, target.class, M, alpha = 1, lambda = 2, |
9 | 10 |
\arguments{ |
10 | 11 |
\item{paths}{The training paths computed by \code{\link{pathsToBinary}}} |
11 | 12 |
|
12 |
-\item{target.class}{he label of the targe class to be classified. This label must be present |
|
13 |
+\item{target.class}{he label of the targe class to be classified. This label must be present |
|
13 | 14 |
as a label within the \code{paths\$y} object} |
14 | 15 |
|
15 | 16 |
\item{M}{Number of components within the paths to be extracted.} |
... | ... |
@@ -45,11 +46,11 @@ A list with the following values |
45 | 46 |
HME3M Markov pathway classifier. |
46 | 47 |
} |
47 | 48 |
\details{ |
48 |
-Take care with selection of lambda and alpha - make sure you check that the likelihood |
|
49 |
+Take care with selection of lambda and alpha - make sure you check that the likelihood |
|
49 | 50 |
is always increasing. |
50 | 51 |
} |
51 | 52 |
\examples{ |
52 |
-## Prepare a weighted reaction network. |
|
53 |
+ ## Prepare a weighted reaction network. |
|
53 | 54 |
## Conver a metabolic network to a reaction network. |
54 | 55 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
55 | 56 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -58,14 +59,14 @@ is always increasing. |
58 | 59 |
# Calculate Pearson's correlation. |
59 | 60 |
data(ex_microarray) # Part of ALL dataset. |
60 | 61 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
61 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
62 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
62 | 63 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
63 | 64 |
|
64 | 65 |
## Get ranked paths using probabilistic shortest paths. |
65 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
66 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
66 | 67 |
K=20, minPathSize=6) |
67 |
- |
|
68 |
- ## Convert paths to binary matrix. |
|
68 |
+ |
|
69 |
+ ## Convert paths to binary matrix. |
|
69 | 70 |
ybinpaths <- pathsToBinary(ranked.p) |
70 | 71 |
p.class <- pathClassifier(ybinpaths, target.class = "BCR/ABL", M = 3) |
71 | 72 |
|
... | ... |
@@ -75,6 +76,7 @@ is always increasing. |
75 | 76 |
## Plotting the classifier results. |
76 | 77 |
plotClassifierROC(p.class) |
77 | 78 |
plotClusters(ybinpaths, p.class) |
79 |
+ |
|
78 | 80 |
} |
79 | 81 |
\author{ |
80 | 82 |
Timothy Hancock and Ichigaku Takigawa |
... | ... |
@@ -85,15 +87,13 @@ Hancock, Timothy, and Mamitsuka, Hiroshi: A Markov Classification Model for Meta |
85 | 87 |
Hancock, Timothy, and Mamitsuka, Hiroshi: A Markov Classification Model for Metabolic Pathways, Algorithms for Molecular Biology 2010 |
86 | 88 |
} |
87 | 89 |
\seealso{ |
88 |
-Other Path clustering & classification methods: \code{\link{pathCluster}}; |
|
89 |
- \code{\link{pathsToBinary}}; |
|
90 |
- \code{\link{plotClassifierROC}}; |
|
90 |
+Other Path clustering & classification methods: \code{\link{pathCluster}}, |
|
91 |
+ \code{\link{pathsToBinary}}, |
|
92 |
+ \code{\link{plotClassifierROC}}, |
|
91 | 93 |
\code{\link{plotClusterMatrix}}, |
92 |
- \code{\link{plotClusterProbs}}, |
|
93 |
- \code{\link{plotClusters}}; |
|
94 |
- \code{\link{plotPathClassifier}}; |
|
95 |
- \code{\link{plotPathCluster}}; |
|
96 |
- \code{\link{predictPathClassifier}}; |
|
94 |
+ \code{\link{plotPathClassifier}}, |
|
95 |
+ \code{\link{plotPathCluster}}, |
|
96 |
+ \code{\link{predictPathClassifier}}, |
|
97 | 97 |
\code{\link{predictPathCluster}} |
98 | 98 |
} |
99 | 99 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathCluster.R |
|
2 | 3 |
\name{pathCluster} |
3 | 4 |
\alias{pathCluster} |
4 | 5 |
\title{3M Markov mixture model for clustering pathways} |
... | ... |
@@ -25,7 +26,7 @@ A list with the following items: |
25 | 26 |
3M Markov mixture model for clustering pathways |
26 | 27 |
} |
27 | 28 |
\examples{ |
28 |
-## Prepare a weighted reaction network. |
|
29 |
+ ## Prepare a weighted reaction network. |
|
29 | 30 |
## Conver a metabolic network to a reaction network. |
30 | 31 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
31 | 32 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -37,13 +38,14 @@ A list with the following items: |
37 | 38 |
weight.method = "cor", use.attr="miriam.uniprot", bootstrap = FALSE) |
38 | 39 |
|
39 | 40 |
## Get ranked paths using probabilistic shortest paths. |
40 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
41 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
41 | 42 |
K=20, minPathSize=8) |
42 |
- |
|
43 |
- ## Convert paths to binary matrix. |
|
43 |
+ |
|
44 |
+ ## Convert paths to binary matrix. |
|
44 | 45 |
ybinpaths <- pathsToBinary(ranked.p) |
45 | 46 |
p.cluster <- pathCluster(ybinpaths, M=2) |
46 | 47 |
plotClusters(ybinpaths, p.cluster) |
48 |
+ |
|
47 | 49 |
} |
48 | 50 |
\author{ |
49 | 51 |
Ichigaku Takigawa |
... | ... |
@@ -51,19 +53,17 @@ Ichigaku Takigawa |
51 | 53 |
Timothy Hancock |
52 | 54 |
} |
53 | 55 |
\references{ |
54 |
-Mamitsuka, H., Okuno, Y., and Yamaguchi, A. 2003. Mining biologically active patterns in |
|
56 |
+Mamitsuka, H., Okuno, Y., and Yamaguchi, A. 2003. Mining biologically active patterns in |
|
55 | 57 |
metabolic pathways using microarray expression profiles. SIGKDD Explor. News l. 5, 2 (Dec. 2003), 113-121. |
56 | 58 |
} |
57 | 59 |
\seealso{ |
58 |
-Other Path clustering & classification methods: \code{\link{pathClassifier}}; |
|
59 |
- \code{\link{pathsToBinary}}; |
|
60 |
- \code{\link{plotClassifierROC}}; |
|
60 |
+Other Path clustering & classification methods: \code{\link{pathClassifier}}, |
|
61 |
+ \code{\link{pathsToBinary}}, |
|
62 |
+ \code{\link{plotClassifierROC}}, |
|
61 | 63 |
\code{\link{plotClusterMatrix}}, |
62 |
- \code{\link{plotClusterProbs}}, |
|
63 |
- \code{\link{plotClusters}}; |
|
64 |
- \code{\link{plotPathClassifier}}; |
|
65 |
- \code{\link{plotPathCluster}}; |
|
66 |
- \code{\link{predictPathClassifier}}; |
|
64 |
+ \code{\link{plotPathClassifier}}, |
|
65 |
+ \code{\link{plotPathCluster}}, |
|
66 |
+ \code{\link{predictPathClassifier}}, |
|
67 | 67 |
\code{\link{predictPathCluster}} |
68 | 68 |
} |
69 | 69 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathRank.R |
|
2 | 3 |
\name{pathRanker} |
3 | 4 |
\alias{pathRanker} |
4 | 5 |
\title{Extracting and ranking paths from a network} |
... | ... |
@@ -28,25 +29,25 @@ A list of paths where each path has the following items: |
28 | 29 |
\item{distance}{The sum of the log(ECDF edge weights) along each path. (a sum of logs is a product)} |
29 | 30 |
} |
30 | 31 |
\description{ |
31 |
-Given a weighted igraph object, path ranking finds a set of node/edge sequences (paths) to |
|
32 |
+Given a weighted igraph object, path ranking finds a set of node/edge sequences (paths) to |
|
32 | 33 |
maximize the sum of edge weights. |
33 |
-\code{pathRanker(method="prob.shortest.path")} extracts the K most probable paths within |
|
34 |
+\code{pathRanker(method="prob.shortest.path")} extracts the K most probable paths within |
|
34 | 35 |
a weighted network. |
35 |
-\code{pathRanker(method="pvalue")} extracts a list of paths whose sum of edge weights are |
|
36 |
+\code{pathRanker(method="pvalue")} extracts a list of paths whose sum of edge weights are |
|
36 | 37 |
significantly higher than random paths of the same length. |
37 | 38 |
} |
38 | 39 |
\details{ |
39 |
-The input here is \code{graph}. A weight must be assigned to each edge. Bootstrapped Pearson correlation edge weights |
|
40 |
-can be assigned to each edge by \code{\link{assignEdgeWeights}}. However the specification of the edge weight is flexible |
|
40 |
+The input here is \code{graph}. A weight must be assigned to each edge. Bootstrapped Pearson correlation edge weights |
|
41 |
+can be assigned to each edge by \code{\link{assignEdgeWeights}}. However the specification of the edge weight is flexible |
|
41 | 42 |
with the condition that increasing values indicate stronger relationships between vertices. |
42 | 43 |
|
43 | 44 |
\subsection{Probabilistic Shortest Paths}{ |
44 |
-\code{pathRanker(method="prob.shortest.path")} finds the K most probable loopless paths given a weighted network. |
|
45 |
-Before the paths are ranked the edge weights are converted into probabilistic edge weights using the Empirical |
|
46 |
-Cumulative Distribution (ECDF) over all edge weights. This is called ECDF edge weight. The ECDF edge weight |
|
45 |
+\code{pathRanker(method="prob.shortest.path")} finds the K most probable loopless paths given a weighted network. |
|
46 |
+Before the paths are ranked the edge weights are converted into probabilistic edge weights using the Empirical |
|
47 |
+Cumulative Distribution (ECDF) over all edge weights. This is called ECDF edge weight. The ECDF edge weight |
|
47 | 48 |
serves as a probabilistic rank of the most important gene-gene interactions. The probabilistic nature of the ECDF |
48 |
-edge weights allow for a significance test to determine if a path contains any functional structure or is |
|
49 |
-simply a random walk. The probability of a path is simily the product of all ECDF weights along the path. |
|
49 |
+edge weights allow for a significance test to determine if a path contains any functional structure or is |
|
50 |
+simply a random walk. The probability of a path is simily the product of all ECDF weights along the path. |
|
50 | 51 |
This is computed as a sum of the logs of the ECDF edge weights. |
51 | 52 |
|
52 | 53 |
The follwing arguments can be passed to \code{pathRanker(method="prob.shortest.path")}: |
... | ... |
@@ -54,17 +55,17 @@ The follwing arguments can be passed to \code{pathRanker(method="prob.shortest.p |
54 | 55 |
\item{\code{K}}{Maximum number of paths to extract. Defaults to 10.} |
55 | 56 |
\item{\code{minPathSize}}{The minimum number of edges for each extracted path. Defualts to 1.} |
56 | 57 |
\item{\code{normalize}}{Specify if you want to normalize the probabilistic edge weights (across different labels) |
57 |
-before extracting the paths. Defaults to TRUE.} |
|
58 |
+before extracting the paths. Defaults to TRUE.} |
|
58 | 59 |
} |
59 | 60 |
} |
60 | 61 |
|
61 | 62 |
\subsection{P-value method}{ |
62 |
-\code{pathRanker(method="pvalue")} searches all paths between the specified start and end vertices, and if a |
|
63 |
-significant path is found it returns it. However, It doesn't search for the best path between the start and |
|
64 |
-terminal vertices, as there could be many paths which lead to the same terminal vertex, and searching through |
|
63 |
+\code{pathRanker(method="pvalue")} searches all paths between the specified start and end vertices, and if a |
|
64 |
+significant path is found it returns it. However, It doesn't search for the best path between the start and |
|
65 |
+terminal vertices, as there could be many paths which lead to the same terminal vertex, and searching through |
|
65 | 66 |
all of them is time comsuming. We just stop when the first significant path is found. |
66 | 67 |
|
67 |
-All provided edge weights are recaled from 0-1. Path significance is calculated based on the empirical distribution |
|
68 |
+All provided edge weights are recaled from 0-1. Path significance is calculated based on the empirical distribution |
|
68 | 69 |
of random paths of the same length. This can be estimated using \code{\link{samplePaths}} and passed as an argument. |
69 | 70 |
|
70 | 71 |
The follwing arguments can be passed to \code{pathRanker(method="pvalue")}: |
... | ... |
@@ -75,7 +76,7 @@ The follwing arguments can be passed to \code{pathRanker(method="pvalue")}: |
75 | 76 |
} |
76 | 77 |
} |
77 | 78 |
\examples{ |
78 |
-## Prepare a weighted reaction network. |
|
79 |
+ ## Prepare a weighted reaction network. |
|
79 | 80 |
## Conver a metabolic network to a reaction network. |
80 | 81 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
81 | 82 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -84,21 +85,22 @@ The follwing arguments can be passed to \code{pathRanker(method="pvalue")}: |
84 | 85 |
# Calculate Pearson's correlation. |
85 | 86 |
data(ex_microarray) # Part of ALL dataset. |
86 | 87 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
87 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
88 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
88 | 89 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
89 | 90 |
|
90 | 91 |
## Get ranked paths using probabilistic shortest paths. |
91 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
92 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
92 | 93 |
K=20, minPathSize=6) |
93 |
- |
|
94 |
+ |
|
94 | 95 |
## Get significantly correlated paths using "p-valvue" method. |
95 |
- ## First, establish path score distribution by calling "samplePaths" |
|
96 |
+ ## First, establish path score distribution by calling "samplePaths" |
|
96 | 97 |
pathsample <- samplePaths(rgraph, max.path.length=10, |
97 | 98 |
num.samples=100, num.warmup=10) |
98 |
- |
|
99 |
- ## Get all significant paths with p<0.1 |
|
100 |
- significant.p <- pathRanker(rgraph, method = "pvalue", |
|
99 |
+ |
|
100 |
+ ## Get all significant paths with p<0.1 |
|
101 |
+ significant.p <- pathRanker(rgraph, method = "pvalue", |
|
101 | 102 |
sampledpaths = pathsample ,alpha=0.1) |
103 |
+ |
|
102 | 104 |
} |
103 | 105 |
\author{ |
104 | 106 |
Timothy Hancock, Ichigaku Takigawa, Nicolas Wicker and Ahmed Mohamed |
... | ... |
@@ -106,7 +108,7 @@ Timothy Hancock, Ichigaku Takigawa, Nicolas Wicker and Ahmed Mohamed |
106 | 108 |
\seealso{ |
107 | 109 |
getPathsAsEIDs, extractPathNetwork |
108 | 110 |
|
109 |
-Other Path ranking methods: \code{\link{extractPathNetwork}}; |
|
110 |
- \code{\link{getPathsAsEIDs}}; \code{\link{samplePaths}} |
|
111 |
+Other Path ranking methods: \code{\link{extractPathNetwork}}, |
|
112 |
+ \code{\link{getPathsAsEIDs}}, \code{\link{samplePaths}} |
|
111 | 113 |
} |
112 | 114 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathClassifier.R |
|
2 | 3 |
\name{pathsToBinary} |
3 | 4 |
\alias{pathsToBinary} |
4 | 5 |
\title{Converts the result from pathRanker into something suitable for pathClassifier or pathCluster.} |
... | ... |
@@ -18,17 +19,17 @@ A list with the following elements. |
18 | 19 |
Converts the result from pathRanker into something suitable for pathClassifier or pathCluster. |
19 | 20 |
} |
20 | 21 |
\details{ |
21 |
-Converts a set of pathways from \code{\link{pathRanker}} |
|
22 |
-into a list of binary pathway matrices. If the pathways are grouped by a response label then the |
|
23 |
-\emph{pathsToBinary} returns a list labeled by response class where each element is the binary |
|
22 |
+Converts a set of pathways from \code{\link{pathRanker}} |
|
23 |
+into a list of binary pathway matrices. If the pathways are grouped by a response label then the |
|
24 |
+\emph{pathsToBinary} returns a list labeled by response class where each element is the binary |
|
24 | 25 |
pathway matrix for each class. If the pathways are from \code{\link{pathRanker}} then a list wiht |
25 |
-a single element containing the binary pathway matrix is returned. To look up the structure of a |
|
26 |
+a single element containing the binary pathway matrix is returned. To look up the structure of a |
|
26 | 27 |
specific binary path in the corresponding \code{ypaths} object simply use matrix index by calling |
27 |
-\code{ypaths[[ybinpaths\$pidx[i,]]]}, where \code{i} is the row in the binary paths object you |
|
28 |
+\code{ypaths[[ybinpaths\$pidx[i,]]]}, where \code{i} is the row in the binary paths object you |
|
28 | 29 |
wish to reference. |
29 | 30 |
} |
30 | 31 |
\examples{ |
31 |
-## Prepare a weighted reaction network. |
|
32 |
+ ## Prepare a weighted reaction network. |
|
32 | 33 |
## Conver a metabolic network to a reaction network. |
33 | 34 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
34 | 35 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -37,31 +38,30 @@ wish to reference. |
37 | 38 |
# Calculate Pearson's correlation. |
38 | 39 |
data(ex_microarray) # Part of ALL dataset. |
39 | 40 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
40 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
41 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
41 | 42 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
42 | 43 |
|
43 | 44 |
## Get ranked paths using probabilistic shortest paths. |
44 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
45 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
45 | 46 |
K=20, minPathSize=6) |
46 |
- |
|
47 |
- ## Convert paths to binary matrix. |
|
47 |
+ |
|
48 |
+ ## Convert paths to binary matrix. |
|
48 | 49 |
ybinpaths <- pathsToBinary(ranked.p) |
49 | 50 |
p.cluster <- pathCluster(ybinpaths, M=3) |
50 | 51 |
plotClusters(ybinpaths, p.cluster, col=c("red", "green", "blue") ) |
52 |
+ |
|
51 | 53 |
} |
52 | 54 |
\author{ |
53 | 55 |
Timothy Hancock and Ichigaku Takigawa |
54 | 56 |
} |
55 | 57 |
\seealso{ |
56 |
-Other Path clustering & classification methods: \code{\link{pathClassifier}}; |
|
57 |
- \code{\link{pathCluster}}; |
|
58 |
- \code{\link{plotClassifierROC}}; |
|
58 |
+Other Path clustering & classification methods: \code{\link{pathClassifier}}, |
|
59 |
+ \code{\link{pathCluster}}, |
|
60 |
+ \code{\link{plotClassifierROC}}, |
|
59 | 61 |
\code{\link{plotClusterMatrix}}, |
60 |
- \code{\link{plotClusterProbs}}, |
|
61 |
- \code{\link{plotClusters}}; |
|
62 |
- \code{\link{plotPathClassifier}}; |
|
63 |
- \code{\link{plotPathCluster}}; |
|
64 |
- \code{\link{predictPathClassifier}}; |
|
62 |
+ \code{\link{plotPathClassifier}}, |
|
63 |
+ \code{\link{plotPathCluster}}, |
|
64 |
+ \code{\link{predictPathClassifier}}, |
|
65 | 65 |
\code{\link{predictPathCluster}} |
66 | 66 |
} |
67 | 67 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/plotPath.R |
|
2 | 3 |
\name{plotAllNetworks} |
3 | 4 |
\alias{plotAllNetworks} |
4 | 5 |
\title{Higlighting ranked paths over multiple network representations.} |
... | ... |
@@ -34,7 +35,7 @@ This function highlighting ranked paths over different network representations, |
34 | 35 |
gene networks. The functions finds equivalent paths across different networks and marks them. |
35 | 36 |
} |
36 | 37 |
\examples{ |
37 |
-## Prepare a weighted reaction network. |
|
38 |
+ ## Prepare a weighted reaction network. |
|
38 | 39 |
## Conver a metabolic network to a reaction network. |
39 | 40 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
40 | 41 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -43,28 +44,27 @@ gene networks. The functions finds equivalent paths across different networks an |
43 | 44 |
# Calculate Pearson's correlation. |
44 | 45 |
data(ex_microarray) # Part of ALL dataset. |
45 | 46 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
46 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
47 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
47 | 48 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
48 | 49 |
|
49 | 50 |
## Get ranked paths using probabilistic shortest paths. |
50 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
51 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
51 | 52 |
K=20, minPathSize=6) |
52 | 53 |
|
53 | 54 |
plotAllNetworks(ranked.p, metabolic.net = ex_sbml, reaction.net = rgraph, |
54 | 55 |
vertex.label = "", vertex.size = 4) |
56 |
+ |
|
55 | 57 |
} |
56 | 58 |
\author{ |
57 | 59 |
Ahmed Mohamed |
58 | 60 |
} |
59 | 61 |
\seealso{ |
60 |
-Other Plotting methods: \code{\link{colorVertexByAttr}}; |
|
61 |
- \code{\link{layoutVertexByAttr}}; |
|
62 |
- \code{\link{plotClassifierROC}}; |
|
62 |
+Other Plotting methods: \code{\link{colorVertexByAttr}}, |
|
63 |
+ \code{\link{layoutVertexByAttr}}, |
|
64 |
+ \code{\link{plotClassifierROC}}, |
|
63 | 65 |
\code{\link{plotClusterMatrix}}, |
64 |
- \code{\link{plotClusterProbs}}, |
|
65 |
- \code{\link{plotClusters}}; \code{\link{plotCytoscape}}, |
|
66 |
- \code{\link{plotCytoscapeGML}}; |
|
67 |
- \code{\link{plotNetwork}}; |
|
68 |
- \code{\link{plotPathClassifier}}; \code{\link{plotPaths}} |
|
66 |
+ \code{\link{plotCytoscapeGML}}, |
|
67 |
+ \code{\link{plotNetwork}}, |
|
68 |
+ \code{\link{plotPathClassifier}}, \code{\link{plotPaths}} |
|
69 | 69 |
} |
70 | 70 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathClassifier.R |
|
2 | 3 |
\name{plotClassifierROC} |
3 | 4 |
\alias{plotClassifierROC} |
4 | 5 |
\title{Diagnostic plots for pathClassifier.} |
... | ... |
@@ -10,11 +11,11 @@ plotClassifierROC(mix) |
10 | 11 |
} |
11 | 12 |
\value{ |
12 | 13 |
Diagnostic plots of the result from pathClassifier. |
13 |
-item{Top}{ROC curves for the posterior probabilities (\code{mix\$posterior.probs}) |
|
14 |
-and for each HME3M component (\code{mix\$h}). This gives information about what response |
|
15 |
-label each relates to. A ROC curve with an \code{AUC < 0.5} relates to \code{y = 0}. |
|
14 |
+item{Top}{ROC curves for the posterior probabilities (\code{mix\$posterior.probs}) |
|
15 |
+and for each HME3M component (\code{mix\$h}). This gives information about what response |
|
16 |
+label each relates to. A ROC curve with an \code{AUC < 0.5} relates to \code{y = 0}. |
|
16 | 17 |
Conversely ROC curves with \code{AUC > 0.5} relate to \code{y = 1}. } |
17 |
-item{Bottom}{The likelihood convergence history for the HME3M model. If the parameters |
|
18 |
+item{Bottom}{The likelihood convergence history for the HME3M model. If the parameters |
|
18 | 19 |
\code{alpha} or \code{lambda} are set too large then the likelihood may decrease.} |
19 | 20 |
} |
20 | 21 |
\description{ |
... | ... |
@@ -24,24 +25,20 @@ Diagnostic plots for \code{\link{pathClassifier}}. |
24 | 25 |
Timothy Hancock and Ichigaku Takigawa |
25 | 26 |
} |
26 | 27 |
\seealso{ |
27 |
-Other Path clustering & classification methods: \code{\link{pathClassifier}}; |
|
28 |
- \code{\link{pathCluster}}; \code{\link{pathsToBinary}}; |
|
28 |
+Other Path clustering & classification methods: \code{\link{pathClassifier}}, |
|
29 |
+ \code{\link{pathCluster}}, \code{\link{pathsToBinary}}, |
|
29 | 30 |
\code{\link{plotClusterMatrix}}, |
30 |
- \code{\link{plotClusterProbs}}, |
|
31 |
- \code{\link{plotClusters}}; |
|
32 |
- \code{\link{plotPathClassifier}}; |
|
33 |
- \code{\link{plotPathCluster}}; |
|
34 |
- \code{\link{predictPathClassifier}}; |
|
31 |
+ \code{\link{plotPathClassifier}}, |
|
32 |
+ \code{\link{plotPathCluster}}, |
|
33 |
+ \code{\link{predictPathClassifier}}, |
|
35 | 34 |
\code{\link{predictPathCluster}} |
36 | 35 |
|
37 |
-Other Plotting methods: \code{\link{colorVertexByAttr}}; |
|
38 |
- \code{\link{layoutVertexByAttr}}; |
|
39 |
- \code{\link{plotAllNetworks}}; |
|
36 |
+Other Plotting methods: \code{\link{colorVertexByAttr}}, |
|
37 |
+ \code{\link{layoutVertexByAttr}}, |
|
38 |
+ \code{\link{plotAllNetworks}}, |
|
40 | 39 |
\code{\link{plotClusterMatrix}}, |
41 |
- \code{\link{plotClusterProbs}}, |
|
42 |
- \code{\link{plotClusters}}; \code{\link{plotCytoscape}}, |
|
43 |
- \code{\link{plotCytoscapeGML}}; |
|
44 |
- \code{\link{plotNetwork}}; |
|
45 |
- \code{\link{plotPathClassifier}}; \code{\link{plotPaths}} |
|
40 |
+ \code{\link{plotCytoscapeGML}}, |
|
41 |
+ \code{\link{plotNetwork}}, |
|
42 |
+ \code{\link{plotPathClassifier}}, \code{\link{plotPaths}} |
|
46 | 43 |
} |
47 | 44 |
|
... | ... |
@@ -1,4 +1,5 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/pathCluster.R |
|
2 | 3 |
\name{plotClusterMatrix} |
3 | 4 |
\alias{plotClusterMatrix} |
4 | 5 |
\alias{plotClusterProbs} |
... | ... |
@@ -24,7 +25,7 @@ plotClusters(ybinpaths, clusters, col, ...) |
24 | 25 |
\item{...}{Extra paramaters passed to \code{plotClusterMatrix}} |
25 | 26 |
} |
26 | 27 |
\value{ |
27 |
-\code{plotClusterMatrix} plots an image of all paths the training dataset. Rows are the paths and columns |
|
28 |
+\code{plotClusterMatrix} plots an image of all paths the training dataset. Rows are the paths and columns |
|
28 | 29 |
are the genes (features) included within each path. Paths are colored according to cluster membership. |
29 | 30 |
|
30 | 31 |
\code{plotClusterProbs} The training set posterior probabilities for each path belonging to a 3M component. \cr |
... | ... |
@@ -35,7 +36,7 @@ are the genes (features) included within each path. Paths are colored according |
35 | 36 |
Plots the structure of all path clusters |
36 | 37 |
} |
37 | 38 |
\examples{ |
38 |
-## Prepare a weighted reaction network. |
|
39 |
+ ## Prepare a weighted reaction network. |
|
39 | 40 |
## Conver a metabolic network to a reaction network. |
40 | 41 |
data(ex_sbml) # bipartite metabolic network of Carbohydrate metabolism. |
41 | 42 |
rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
... | ... |
@@ -44,37 +45,37 @@ Plots the structure of all path clusters |
44 | 45 |
# Calculate Pearson's correlation. |
45 | 46 |
data(ex_microarray) # Part of ALL dataset. |
46 | 47 |
rgraph <- assignEdgeWeights(microarray = ex_microarray, graph = rgraph, |
47 |
- weight.method = "cor", use.attr="miriam.uniprot", |
|
48 |
+ weight.method = "cor", use.attr="miriam.uniprot", |
|
48 | 49 |
y=factor(colnames(ex_microarray)), bootstrap = FALSE) |
49 | 50 |
|
50 | 51 |
## Get ranked paths using probabilistic shortest paths. |
51 |
- ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
52 |
+ ranked.p <- pathRanker(rgraph, method="prob.shortest.path", |
|
52 | 53 |
K=20, minPathSize=8) |
53 |
- |
|
54 |
- ## Convert paths to binary matrix. |
|
54 |
+ |
|
55 |
+ ## Convert paths to binary matrix. |
|
55 | 56 |
ybinpaths <- pathsToBinary(ranked.p) |
56 | 57 |
p.cluster <- pathCluster(ybinpaths, M=2) |
57 | 58 |
plotClusters(ybinpaths, p.cluster, col=c("red", "blue") ) |
59 |
+ |
|
58 | 60 |
} |
59 | 61 |
\author{ |
60 | 62 |
Ahmed Mohamed |
61 | 63 |
} |
62 | 64 |
\seealso{ |
63 |
-Other Path clustering & classification methods: \code{\link{pathClassifier}}; |
|
64 |
- \code{\link{pathCluster}}; \code{\link{pathsToBinary}}; |
|
65 |
- \code{\link{plotClassifierROC}}; |
|
66 |
- \code{\link{plotPathClassifier}}; |
|
67 |
- \code{\link{plotPathCluster}}; |
|
68 |
- \code{\link{predictPathClassifier}}; |
|
65 |
+Other Path clustering & classification methods: \code{\link{pathClassifier}}, |
|
66 |
+ \code{\link{pathCluster}}, \code{\link{pathsToBinary}}, |
|
67 |
+ \code{\link{plotClassifierROC}}, |
|
68 |
+ \code{\link{plotPathClassifier}}, |
|
69 |
+ \code{\link{plotPathCluster}}, |
|
70 |
+ \code{\link{predictPathClassifier}}, |
|
69 | 71 |
\code{\link{predictPathCluster}} |
70 | 72 |
|
71 |
-Other Plotting methods: \code{\link{colorVertexByAttr}}; |
|
72 |
- \code{\link{layoutVertexByAttr}}; |
|
73 |
- \code{\link{plotAllNetworks}}; |
|
74 |
- \code{\link{plotClassifierROC}}; |
|
75 |
- \code{\link{plotCytoscape}}, |
|
76 |
- \code{\link{plotCytoscapeGML}}; |
|
77 |
- \code{\link{plotNetwork}}; |
|
78 |
- \code{\link{plotPathClassifier}}; \code{\link{plotPaths}} |
|
73 |
+Other Plotting methods: \code{\link{colorVertexByAttr}}, |
|
74 |
+ \code{\link{layoutVertexByAttr}}, |
|
75 |
+ \code{\link{plotAllNetworks}}, |
|
76 |
+ \code{\link{plotClassifierROC}}, |
|
77 |
+ \code{\link{plotCytoscapeGML}}, |
|
78 |
+ \code{\link{plotNetwork}}, |
|
79 |
+ \code{\link{plotPathClassifier}}, \code{\link{plotPaths}} |
|
79 | 80 |
} |
80 | 81 |
|
... | ... |
@@ -1,20 +1,15 @@ |
1 |
-% Generated by roxygen2 (4.0.1): do not edit by hand |
|
2 |
-\name{plotCytoscape} |
|
3 |
-\alias{plotCytoscape} |
|
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/plotPath.R |
|
3 |
+\name{plotCytoscapeGML} |
|
4 | 4 |
\alias{plotCytoscapeGML} |
5 | 5 |
\title{Plots an annotated igraph object in Cytoscape.} |
6 | 6 |
\usage{ |
7 |
-plotCytoscape(graph, title, layout = layout.auto, vertex.size, vertex.label, |
|
8 |
- vertex.shape, vertex.color, edge.color) |
|
9 |
- |
|
10 | 7 |
plotCytoscapeGML(graph, file, layout = layout.auto, vertex.size, vertex.label, |
11 | 8 |
vertex.shape, vertex.color, edge.color) |
12 | 9 |
} |
13 | 10 |
\arguments{ |
14 | 11 |
\item{graph}{An annotated igraph object.} |
15 | 12 |
|
16 |
-\item{title}{Will be set as a window title in Cytoscape.} |
|
17 |
- |
|
18 | 13 |
\item{file}{Output GML file name to which the network plot is exported.} |
19 | 14 |
|
20 | 15 |
\item{layout}{Either a graph layout function, or a two-column matrix specifiying vertex coordinates.} |
... | ... |
@@ -35,43 +30,30 @@ supported. If missing, the vertex attribute "color" (\preformatted{V(g)$color)}) |
35 | 30 |
(\preformatted{E(g)$color)}) will be used.} |
36 | 31 |
} |
37 | 32 |
\value{ |
38 |
-A CytoscapeWindow object constructed by \code{\link[RCytoscape]{new.CytoscapeWindow}}. |
|
39 |
- |
|
40 | 33 |
For \code{plotCytoscapeGML}, results are written to file. |
41 | 34 |
} |
42 | 35 |
\description{ |
43 |
-Thess functions provide ways to plot igraph object in Cytoscape, enabling |
|
44 |
-interactive investigation of the network. \link{plotCytoscape} uses RCytoscape |
|
45 |
-interface to plot graphs in Cytoscape directly form R. The function is compatible with Cytoscape |
|
46 |
-2.8.3 or lower, and requires an open Cytoscape window, with CytoscapeRPC plugin installed and activated. |
|
36 |
+\code{plotCytoscape} function has been removed because RCytoscape is no longer prensent in Bioconductor. |
|
37 |
+Future plans will use RCy3 for Cytoscape plotting, once RCy3 is supported on MacOS and Windows. |
|
47 | 38 |
\link{plotCytoscapeGML} exports the network plot in GML format, that can be later imported into Cytoscape |
48 | 39 |
(using "import network from file" option). This fuction is compatible with all Cytoscape versions. |
49 | 40 |
} |
50 | 41 |
\examples{ |
51 |
-data("ex_sbml") |
|
52 |
- rgraph <- makeReactionNetwork(ex_sbml, simplify=TRUE) |
|
53 |
- v.layout <- layoutVertexByAttr(rgraph, "compartment") |
|
< |