setNetStyle: Enhancing an igraph originating from the seekNet function

Description Usage Arguments Details Value Examples

View source: R/setNet.R

Description

#' Imports: igraph

Usage

1
2
3
4
5
6
7
8
setNetStyle(
  net,
  set,
  spread = 1,
  vertexSize = 7,
  labelSize = 2,
  markGroups = NA
)

Arguments

net

outout from the setNet() function

set

vector of characters (ENTREZIDs). Genes contained in this set will be colored.

spread

number, factor to expand the plot

vertexSize

number, regulates the size of the nodes/vertexes of the plot

markGroups

list of character vectors (EntrezIds), gene groups that should be highlighted

Details

the variable net has to be a direct output from the function seekNet()

Value

prints a plot and outputs a list: 1) a vector of characters with colors that can be added to the igraph object, 2) a character vector that can directly be used as input for the igraph function 'graph', 3) igraph object, the output of the igraph function 'graph', 4) a layout that can be used when ploting the output from the igraph function 'graph', 5) a vector of numbers for the edge widths in the plot

Examples

1
2
3
4
myGenes <- c("KRT83","CD80","SLC14A1")
sets <- qusage::read.gmt("path/to/file.gmt")
net <- setNet(myGenes, sets, "human")
net1 <- setNetStyle(net, sets[[1]])

Solatar/setR documentation built on Dec. 5, 2020, 10:50 p.m.