prob_heatmap: Plot a heatmap for probability of clone assignment

View source: R/plotting.R

prob_heatmapR Documentation

Plot a heatmap for probability of clone assignment

Description

Plot a heatmap for probability of clone assignment

Usage

prob_heatmap(prob_mat, threshold = 0.5, mode = "best", cell_idx = NULL)

Arguments

prob_mat

A matrix (M x K), the probability of cell j to clone k

threshold

A float value, the threshold for assignable cells

mode

A string, the method for defining scores for filtering cells: best and delta. best: highest probability of a cell to K clones, delta: the difference between the best and second.

cell_idx

A vector the indices of the input cells. If NULL, order by the probability of each clone

Value

a ggplot object

Examples

data(example_donor)
assignments <- clone_id(A_clone, D_clone, Config = tree$Z, inference = "EM")
fig <- prob_heatmap(assignments$prob)

davismcc/cardelino documentation built on Nov. 19, 2022, 2:44 a.m.