plotHeatmap#
Last Updated: Sep 07, 2023
Description#
Creates heatmap for genes and clusters.
Usage#
plotHeatmap(
gobject,
spat_unit = NULL,
feat_type = NULL,
expression_values = c("normalized", "scaled", "custom"),
feats,
genes = NULL,
cluster_column = NULL,
cluster_order = c("size", "correlation", "custom"),
cluster_custom_order = NULL,
cluster_color_code = NULL,
cluster_cor_method = "pearson",
cluster_hclust_method = "ward.D",
feat_order = c("correlation", "custom"),
gene_order = NULL,
feat_custom_order = NULL,
gene_custom_order = NULL,
feat_cor_method = "pearson",
gene_cor_method = NULL,
feat_hclust_method = "complete",
gene_hclust_method = NULL,
show_values = c("rescaled", "z-scaled", "original"),
size_vertical_lines = 1.1,
gradient_colors = c("blue", "yellow", "red"),
feat_label_selection = NULL,
gene_label_selection = NULL,
axis_text_y_size = NULL,
legend_nrows = 1,
show_plot = NA,
return_plot = NA,
save_plot = NA,
save_param = list(),
default_save_name = "plotHeatmap"
)
Arguments#
|
giotto object |
|
spatial unit (e.g. “cell”) |
|
feature type (e.g. “rna”, “dna”, “protein”) |
|
expression values to use (e.g. “normalized”, “scaled”, “custom”) |
|
features to use |
|
deprecated, use feats |
|
name of column to use for clusters (e.g. “leiden_clus”) |
|
method to determine cluster order (e.g. “size”, “correlation”, “custom”) |
|
custom order for clusters |
|
color code for clusters |
|
method for cluster correlation, default to “pearson” |
|
method for hierarchical clustering of clusters, default to “ward.D” |
|
method to determine features order (e.g. “correlation”, “custom”) |
|
deprecated, use feat_order |
|
custom order for features |
|
deprecated, use feat_custom_order |
|
method for features correlation, default to “pearson” |
|
deprecated, use feat_cor_method |
|
method for hierarchical clustering of features, default to “complete” |
|
deprecated, use feat_hclust_method |
|
which values to show on heatmap (e.g. “rescaled”, “z-scaled”, “original”) |
|
sizes for vertical lines |
|
colors for heatmap gradient |
|
subset of features to show on y-axis |
|
deprecated, use feat_label_selection |
|
size for y-axis text |
|
number of rows for the cluster legend |
|
show plot. TRUE or FALSE |
|
return ggplot object. TRUE or FALSE |
|
directly save the plot. TRUE or FALSE |
|
list of saving parameters, see
|
|
default save name |
Details#
If you want to display many genes there are 2 ways to proceed:
set axis_text_y_size to a really small value and show all features
provide a subset of features to display to feat_label_selection
Value#
ggplot