bngeneplotCustom: bngeneplotCustom

bngeneplotCustomR Documentation

bngeneplotCustom

Description

Plot gene relationship within the specified pathway using customized theme

Usage

bngeneplotCustom(
  results,
  exp,
  expSample = NULL,
  algo = "hc",
  R = 20,
  pathNum = NULL,
  convertSymbol = TRUE,
  expRow = "ENSEMBL",
  interactive = FALSE,
  cexCategory = 1,
  cl = NULL,
  showDir = FALSE,
  chooseDir = FALSE,
  algorithm.args = NULL,
  labelSize = 4,
  layout = "nicely",
  strType = "normal",
  returnNet = FALSE,
  otherVar = NULL,
  otherVarName = NULL,
  onlyDf = FALSE,
  disc = FALSE,
  tr = NULL,
  remainCont = NULL,
  dep = NULL,
  sizeDep = FALSE,
  orgDb = org.Hs.eg.db,
  bypassConverting = FALSE,
  edgeLink = FALSE,
  cellLineName = "5637_URINARY_TRACT",
  fontFamily = "sans",
  strengthPlot = FALSE,
  nStrength = 10,
  strThresh = NULL,
  hub = NULL,
  glowEdgeNum = NULL,
  nodePal = c("blue", "red"),
  edgePal = c("blue", "red"),
  textCol = "black",
  titleCol = "black",
  backCol = "white",
  barTextCol = "black",
  barPal = c("red", "blue"),
  barBackCol = "white",
  scoreType = "bic-g",
  barLegendKeyCol = "white",
  barAxisCol = "black",
  bg.colour = NULL,
  bg.r = 0.1,
  barPanelGridCol = "black",
  titleSize = 24,
  seed = 1
)

Arguments

results

the enrichment analysis result

exp

gene expression matrix

expSample

candidate rows to be included in the inference default to all

algo

structure learning method used in boot.strength() default to "hc"

R

the number of bootstrap

pathNum

the pathway number (the number of row of the original result, ordered by p-value)

convertSymbol

whether the label of resulting network is converted to symbol, default to TRUE

expRow

the type of the identifier of rows of expression matrix

interactive

whether to use bnviewer (default to FALSE)

cexCategory

scaling factor of size of nodes

cl

cluster object from parallel::makeCluster()

showDir

show the confidence of direction of edges

chooseDir

if undirected edges are present, choose direction of edges

algorithm.args

parameters to pass to bnlearn structure learnng function

labelSize

the size of label of the nodes

layout

ggraph layout, default to "nicely"

strType

"normal" or "ms" for multiscale implementation

returnNet

whether to return the network

otherVar

other variables to be included in the inference

otherVarName

the names of other variables

onlyDf

return only data.frame used for inference

disc

discretize the expressoin data

tr

Specify data.frame if one needs to discretize as the same parameters as the other dataset

remainCont

Specify characters when perform discretization, if some columns are to be remain continuous

dep

the tibble storing dependency score from library depmap

sizeDep

whether to reflect DepMap score to the node size

orgDb

perform clusterProfiler::setReadable based on this organism database

bypassConverting

bypass the symbol converting ID of rownames and those listed in EA result must be same

edgeLink

use geom_edge_link() instead of geom_edge_diagonal()

cellLineName

the cell line name to be included

fontFamily

font family name to be used for plotting

strengthPlot

append the barplot depicting edges with high strength

nStrength

specify how many edges are included in the strength plot

strThresh

the threshold for strength

hub

visualize the genes with top-n hub scores

glowEdgeNum

edges with top-n confidence of direction are highlighted

nodePal

vector of coloring of nodes (low, high)

edgePal

vector of coloring of edges (low, high)

textCol

color of texts in network plot

titleCol

color of title in network plot

backCol

color of background in network plot

barTextCol

text color in barplot

barPal

bar color

barBackCol

background color in barplot

scoreType

score type to use on inference

barLegendKeyCol

legend key color in barplot

barAxisCol

axis color in barplot

bg.colour

parameter to pass to geom_node_text

bg.r

parameter to pass to geom_node_text

barPanelGridCol

panel grid color in barplot

titleSize

the size of title

seed

A random seed to make the analysis reproducible, default is 1.

Value

ggplot2 object

Examples

data("exampleEaRes");data("exampleGeneExp")
res <- bngeneplotCustom(results=exampleEaRes, exp=exampleGeneExp,
                        pathNum=1, glowEdgeNum=NULL, hub=3, R=40,
                        fontFamily="sans")

noriakis/CBNplot documentation built on April 7, 2024, 8:27 p.m.