HoloNet.plotting.lr_umap#

HoloNet.plotting.lr_umap(lr_df, cell_cci_centrality, plot_lr_list=None, cluster_col='cluster', fname=None, **kwargs)#

Display the LR pair in low-dimention space.

Parameters
lr_df DataFrame

A preprocessed LR-gene dataframe, must contain the columns ‘LR_pair’ and clustering results.

cell_cci_centrality Tensor

A tensor (LR_num * cell_num) for the centrality of each cell according to each LR pair.

plot_lr_list List[str] | NoneOptional[List[str]] (default: None)

The LR pair list (in the ‘LR_pair’ column of lr_df) need to be visualized in the UMAP plot.

cluster_col str (default: 'cluster')

The columns in lr_df dataframe storing the clustering results of each LR pair.

fname str | Path | NoneUnion[str, Path, None] (default: None)

The output file name. If None, not save the figure.

kwargs

Other parameters in plt.scatter