bngeneplot: bngeneplot

bngeneplotR Documentation

bngeneplot

Description

Plot gene relationship within the specified pathway

Usage

bngeneplot(
  results,
  exp,
  expSample = NULL,
  algo = "hc",
  R = 20,
  returnNet = FALSE,
  algorithm.args = NULL,
  bypassConverting = FALSE,
  edgeLink = FALSE,
  pathNum = NULL,
  convertSymbol = TRUE,
  expRow = "ENSEMBL",
  interactive = FALSE,
  cexCategory = 1,
  cl = NULL,
  showDir = FALSE,
  chooseDir = FALSE,
  scoreType = "bic-g",
  labelSize = 4,
  layout = "nicely",
  clusterAlpha = 0.2,
  strType = "normal",
  delZeroDegree = TRUE,
  otherVar = NULL,
  otherVarName = NULL,
  onlyDf = FALSE,
  disc = FALSE,
  tr = NULL,
  remainCont = NULL,
  sp = "hsapiens",
  compareRef = FALSE,
  compareRefType = "intersection",
  pathDb = "reactome",
  dep = NULL,
  depMeta = NULL,
  sizeDep = FALSE,
  showDepHist = TRUE,
  cellLineName = "5637_URINARY_TRACT",
  showLineage = FALSE,
  orgDb = org.Hs.eg.db,
  shadowText = TRUE,
  bgColor = "white",
  textColor = "black",
  strengthPlot = FALSE,
  nStrength = 10,
  strThresh = NULL,
  hub = NULL,
  seed = 1,
  useSiGN = FALSE
)

Arguments

results

the enrichment analysis result

exp

gene expression matrix

expSample

candidate samples 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

returnNet

whether to return the network

algorithm.args

parameters to pass to bnlearn structure learnng function

bypassConverting

bypass the symbol converting If you use custom annotation databases that does not have SYMBOL listed in keys. ID of rownames and those listed in EA result must be same.

edgeLink

use geom_edge_link() instead of geom_edge_diagonal()

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 (default: FALSE)

scoreType

score type to use on choosing direction

labelSize

the size of label of the nodes

layout

ggraph layout, default to "nicely"

clusterAlpha

if specified multiple pathways, the parameter is passed to geom_mark_hull()

strType

"normal" or "ms" for multiscale implementation

delZeroDegree

delete zero degree nodes

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 parametersas the other dataset

remainCont

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

sp

query to graphite::pathways(), default to "hsapiens"

compareRef

whether compare to the reference network

compareRefType

"intersection" or "difference"

pathDb

query to graphite::pathways(), default to "reactome"

dep

the tibble storing dependency score from library depmap

depMeta

depmap::depmap_metadata(), needed for showLineage

sizeDep

whether to reflect DepMap score to the node size

showDepHist

whether to show depmap histogram

cellLineName

the cell line name to be included

showLineage

show the dependency score across the lineage

orgDb

perform clusterProfiler::setReadable based on this organism database

shadowText

whether to use shadow text for the better readability default: TRUE

bgColor

color for text background when shadowText is TRUE

textColor

color for text when shadowText is TRUE

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

seed

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

useSiGN

default to FALSE. For using SiGN-BN in the function in Windows 10/11, 1. Download the SiGN-BN HC+BS binary in WSL (https://sign.hgc.jp/signbn/download.html) 2. Set PATH to executable (sign.1.8.3)

Value

ggplot2 object

Examples

data("exampleEaRes");data("exampleGeneExp")
res <- bngeneplot(results = exampleEaRes, exp = exampleGeneExp, pathNum = 1,
                  R = 10, convertSymbol = TRUE, expRow = "ENSEMBL")


noriakis/CBNplot documentation built on Oct. 10, 2024, 12:21 p.m.