gene_network: Creates a gene association network

View source: R/plot_fxns.R

gene_networkR Documentation

Creates a gene association network

Description

Creates a gene association network for genes from a given cluster. The selected cluster acts as the receptor for the gene association network, so only ligands, receptors, and features associated with the receptor cluster will be included in the plot.

Usage

gene_network(
  dom,
  clust = NULL,
  class_cols = c(lig = "#FF685F", rec = "#47a7ff", feat = "#39C740"),
  cols = NULL,
  lig_scale = 1,
  layout = "grid",
  ...
)

Arguments

dom

A domino object with network built (build_domino)

clust

The receptor cluster to create the gene association network for. A vector of clusters may be provided.

class_cols

A named vector of colors used to color classes of vertices. Values must be colors and names must be classes ('rec', 'lig', and 'feat' for receptors, ligands, and features.).

cols

A named vector of colors for individual genes. Genes not included in this vector will be colored according to class_cols.

lig_scale

FALSE or a numeric value to scale the size of ligand vertices based on z-scored expression in the data set.

layout

Type of layout to use. Options are 'grid', 'random', 'sphere', 'circle', 'fr' for Fruchterman-Reingold force directed layout, and 'kk' for Kamada Kawai for directed layout.

...

Other parameters to pass to plot() with an igraph object. See igraph manual for options.


Chris-Cherry/domino documentation built on Dec. 9, 2024, 12:28 a.m.