tangram.plot_utils

Description

This module includes plotting utility functions.

Functions

construct_obs_plot(df_plot, adata[, perc, …])

convert_adata_array(adata)

ordered_predictions(xs, ys, preds[, reverse])

Utility function that orders 2d points based on values associated to each point.

plot_annotation_entropy(adata_map[, annotation])

Utility function to plot entropy box plot by each annotation.

plot_auc(df_all_genes[, test_genes])

Plots auc curve which is used to evaluate model performance.

plot_cell_annotation(adata_map, adata_sp[, …])

Transfer an annotation for a single cell dataset onto space, and visualize corresponding spatial probability maps.

plot_cell_annotation_sc(adata_sp, …[, x, …])

plot_gene_sparsity(adata_1, adata_2[, …])

Compare sparsity of all genes between adata_1 and adata_2.

plot_genes(genes, adata_measured, …[, x, …])

Utility function to plot and compare original and projected gene spatial pattern ordered by intensity of the gene signal.

plot_genes_sc(genes, adata_measured, …[, …])

plot_test_scores(df_gene_score[, bins, alpha])

Plots gene level test scores with each gene’s sparsity for mapping result.

plot_training_scores(adata_map[, bins, alpha])

Plots the 4-panel training diagnosis plot

q_value(data, perc)

Computes min and max values according to percentile for colormap in plot functions

quick_plot_gene(gene, adata[, x, y, s, log, …])

Utility function to quickly plot a gene in a AnnData structure ordered by intensity of the gene signal.