Render a heatmap based on a matrix of counts where rows are genes and columns are cells.
renderCeldaHeatmap(counts, z = NULL, y = NULL, scale_log = NULL,
scale_row = scale, normalize = normalizeCounts, trim = c(-2, 2),
pseudocount_normalize = 0, pseudocount_log = 0, gene.ix = NULL,
cell.ix = NULL, cluster_gene = TRUE, cluster_cell = TRUE,
color_scheme = c("divergent", "sequential"),
color_scheme_symmetric = TRUE, color_scheme_center = 0, col = NULL,
annotation_cell = NULL, annotation_gene = NULL, annotation_color = NULL,
breaks = NULL, legend = TRUE, annotation_legend = TRUE,
annotation_names_gene = TRUE, annotation_names_cell = TRUE,
show_genenames = FALSE, show_cellnames = FALSE,
hclust_method = "ward.D2", treeheight_gene = ifelse(cluster_gene, 50, 0),
treeheight_cell = ifelse(cluster_cell, 50, 0), ...)
A count matrix where rows are genes and columns are cells.
A numeric vector of cluster assignments for cell.
A numeric vector of cluster assignments for gene.
Function; Applys a scale function such as log, log2, log10. Set to NULL to disable. Occurs after normalization. Default NULL.
Function; A function to scale each individual row. Set to NULL to disable. Occurs after normalization and log transformation. Defualt is 'scale' and thus will Z-score transform each row.
A function to normalize the columns. Set to NULL to disable. Default is 'normalizeCounts', which normalizes to counts per million (CPM).
A two element vector to specify the lower and upper cutoff for the data. Occurs after normalization, log transformation, and row scaling. Set to NULL to disable. Default c(-2,2).
Numeric; A pseudocount to add to data before normalization. Default 1.
Numeric; A pseudocount to add to data before log transforming. Default 0.
Index of genes to pull out of the matrix after normalization. If NULL, no subsettig will be performed. Default NULL.
Index of genes to pull out of the matrix after normalization. If NULL, no subsettig will be performed. Default NULL.
Logical; determining if rows should be clustered.
Logical; determining if columns should be clustered.
One of "divergent" or "sequential". A "divergent" scheme is best for highlighting either end of the data with a break in the middle (denoted by 'color_scheme_center') such as gene expression data that has been normalized and centered. A "sequential" scheme is best for data that are ordered low to high such as raw counts or probabilities.
Boolean; When the color_scheme is "divergent" and the data contains both positive and negative numbers, TRUE indicates that the color scheme should be symmetric about the center. For example, if the data ranges goes from -1.5 to 2, then setting this to TRUE will force the colors to range from -2 to 2.
Numeric. Indicates the center of a "divergent" color_scheme. Default 0.
color for the heatmap.
A data frame for the cell annotations (columns).
A data frame for the gene annotations (rows).
A list containing color scheme for cell and/or gene annotation. See '?pheatmap' for more details.
a sequence of numbers that covers the range of values in mat and is one element longer than color vector. Used for mapping values to colors. Useful, if needed to map certain values to certain colors, to certain values. If value is NA then the breaks are calculated automatically.
logical; determining if legend should be drawn or not. Default to be TRUE.
Logical; showing if the legend for annotation tracks should be drawn.
Logical; showing if the names for gene annotation tracks should be drawn. Default to be TRUE.
Logical; showing if the names for cell annotation tracks should be drawn. Default to be TRUE.
Logical; specifying if gene names should be shown. Default to be FALSE.
Logical; specifying if cell names should be shown. Default to be FALSE.
Character; Specifies the method to use for the 'hclust' function. Default is "ward.D2". See ?hclust for possible values.
Numeric; Width of the gene dedrogram. Set to 0 to disable plotting of this dendrogram.
Numeric; Hieght of the cell dedrogram. Set to 0 to disable plotting of this dendrogram.
Other arguments to be passed to underlying pheatmap function