viewTrees: Visualize the trees

View source: R/viewTrees.R

viewTreesR Documentation

Visualize the trees

Description

Visualize the trees

Usage

viewTrees(
  phyloTree,
  tree.format = "S4",
  normal.node = "NORMAL",
  group = NULL,
  group.colors = NULL,
  title = "Cancer",
  showBootstrap = TRUE,
  hexpand_ratio = 0.3
)

Arguments

phyloTree

phyloTree: The tree is in Parenthetic format.

tree.format

the format of tree, S4 or list. Default is S4.

normal.node

the sample name of normal sample in the tree.

group

a list that used to indicate the sample groups.

group.colors

an array indicates the colors of sample groups.

title

title of the plot.

showBootstrap

whether showing the bootstrap values. Default is TRUE.

hexpand_ratio

hexpand ratio. see hexpand

Value

a ggtree object

Examples

# This dist file is the output of MEDICC
dist <- system.file(package = "MPTevol", "extdata", "tree_final.dist")

# plot CNA trees without colored samples.
plotCNAtree(dist = dist)

# create a list to indicate the sample groups.
grp <- list(
  NORMAL = "NORMAL",
  Breast = paste0("Breast_", 1:5),
  Coad = paste0("Coad_", 1:5),
  Lung = paste0("Lung_", 1:5),
  OveryLM = paste0("OveryLM_", 1:5),
  OveryRM = paste0("OveryRM_", 1:6),
  UterusM = paste0("UterusM_", c(1:7))
)

plotCNAtree(dist = dist, grp = grp)

qingjian1991/MPTevol documentation built on Jan. 30, 2023, 10:16 p.m.