timescape {timescape} | R Documentation |
timescape
is a tool for visualizing temporal clonal evolution data.
timescape(clonal_prev, tree_edges, mutations = "NA", clone_colours = "NA", xaxis_title = "Time Point", yaxis_title = "Clonal Prevalence", phylogeny_title = "Clonal Phylogeny", alpha = 50, genotype_position = "stack", perturbations = "NA", sort = FALSE, show_warnings = TRUE, width = 900, height = NULL)
clonal_prev |
|
tree_edges |
|
mutations |
Any additional field will be shown in the mutation table. |
clone_colours |
|
xaxis_title |
|
yaxis_title |
|
phylogeny_title |
|
alpha |
|
genotype_position |
|
perturbations |
|
sort |
|
show_warnings |
|
width |
|
height |
|
Interactive components:
Mouseover any clone to view its (i) clone ID and (ii) clonal prevalence at each time point.
Click the view switch button to switch from the traditional timescape view to the clonal trajectory view, where each clone changes prevalence on its own track.
Click the download buttons to download a PNG or SVG of the view.
None
# EXAMPLE 1 - Acute myeloid leukemia patient, Ding et al., 2012 # genotype tree edges tree_edges <- read.csv(system.file("extdata", "AML_tree_edges.csv", package = "timescape")) # clonal prevalences clonal_prev <- read.csv(system.file("extdata", "AML_clonal_prev.csv", package = "timescape")) # targeted mutations mutations <- read.csv(system.file("extdata", "AML_mutations.csv", package = "timescape")) # perturbations perturbations <- data.frame( pert_name = c("Chemotherapy"), prev_tp = c("Diagnosis")) # run timescape timescape(clonal_prev = clonal_prev, tree_edges = tree_edges, perturbations = perturbations, mutations = mutations) # EXAMPLE 2 - Patient 7, McPherson and Roth et al., 2016 # genotype tree edges tree_edges <- read.csv(system.file("extdata", "px7_tree_edges.csv", package = "timescape")) # clonal prevalences clonal_prev <- read.csv(system.file("extdata", "px7_clonal_prev.csv", package = "timescape")) # clone colours clone_colours <- data.frame(clone_id = c("A","B","C","D","E"), colour = c("d0ced0", "2CD0AB", "FFD94B", "FD8EE5", "F8766D")) # run timescape timescape(clonal_prev = clonal_prev, tree_edges = tree_edges, clone_colours = clone_colours, height=260, alpha=15)