Description Usage Arguments Details Author(s) See Also Examples
This is an generic function.
When implemented as the S4 method for class NWA
, this function
invokes the function networkPlot
to plot and save the subnetwork identified
by the 'BioNet' package.
To use this function for objects of class NWA
:
plotSubNet(object, filepath, filename, output, ...)
1 | plotSubNet(object, ...)
|
object |
an object. When implemented as S4 methods of class |
... |
other arguments. (see below for the arguments supported by the method of
class |
a single character value specifying the directory where the figure will be stored
a single character value specifying the name of the figure to save
a single character value specifying the format of output image: "pdf" or "png"
all other arguments for the function pdf
or png
such as
the argument 'width' and 'height'
After the analyses step for an object of class 'NWA', users can generate
the enriched subnetwork identified by the 'BioNet' package. If the slot
'phenotype' was inputted when initializing the object, this function
will send it to the function networkPlot
as the argument phenotypeVector
to highlight nodes in different colors. If the argument species
of the
function analyze
has been assigned, labels of
nodes of this subnetwork will be mapped to gene symbols corresponding to
the species; otherwise, Entrez identifiers will be used as the labels.
Xin Wang xw264@cam.ac.uk
networkPlot
, viewSubNet
, analyze
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 | ## Not run:
library(BioNet)
##load p-values and phenotypes
data("KcViab_Data4Enrich","KcViab_PVals")
##load Biogrid interactome for Drosophila Melanogaster
data("Biogrid_DM_Interactome")
##create a NWA (NetWork Analysis) object
nwa <- new("NWA", pvalues=KcViab_PVals, phenotypes=KcViab_Data4Enrich,
interactome=Biogrid_DM_Interactome)
##preprocessing
nwa <- preprocess(nwa, species="Dm", initialIDs="Entrez.gene",
keepMultipleMappings=TRUE, duplicateRemoverMethod="max")
##To create an interactome:
##nwa<-interactome(nwa, species="Dm", reportDir="HTSanalyzerReport",
##genetic=FALSE)
##do network analysis
nwa <- analyze(nwa, fdr=0.001, species="Dm")
graphics.off()
##plot and save the identified subnetwork
plotSubNet(nwa, filepath=".", filename="subnetwork.pdf",
output="pdf", width=8, height=8)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.