Learn R Programming

pathfindR (version 1.4.2)

cluster_graph_vis: Graph Visualization of Clustered Enriched Terms

Description

Graph Visualization of Clustered Enriched Terms

Usage

cluster_graph_vis(
  clu_obj,
  kappa_mat,
  enrichment_res,
  kappa_threshold = 0.35,
  use_description = FALSE
)

Arguments

clu_obj

clustering result (either a matrix obtained via hierarchical_term_clustering or fuzzy_term_clustering `fuzzy_term_clustering` or a vector obtained via `hierarchical_term_clustering`)

kappa_mat

matrix of kappa statistics (output of create_kappa_matrix)

enrichment_res

data frame of pathfindR enrichment results. Must-have columns are "Term_Description" (if use_description = TRUE) or "ID" (if use_description = FALSE), "Down_regulated", and "Up_regulated". If use_active_snw_genes = TRUE, "non_Signif_Snw_Genes" must also be provided.

kappa_threshold

threshold for kappa statistics, defining strong relation (default = 0.35)

use_description

Boolean argument to indicate whether term descriptions (in the "Term_Description" column) should be used. (default = FALSE)

Value

Plots a graph diagram of clustering results. Each node is an enriched term from `enrichment_res`. Size of node corresponds to -log(lowest_p). Thickness of the edges between nodes correspond to the kappa statistic between the two terms. Color of each node corresponds to distinct clusters. For fuzzy clustering, if a term is in multiple clusters, multiple colors are utilized.

Examples

Run this code
# NOT RUN {
cluster_graph_vis(clu_obj, kappa_mat, enrichment_res)
# }

Run the code above in your browser using DataLab