FACSPy.tl._compute_diffmap#
- FACSPy.tl._compute_diffmap(adata, n_comps=15, neighbors_key=None, random_state=187)#
Internal function to compute the Diffmap embedding. The core of the function is implemented from scanpy with the important difference that the diffmap coordinates are returned and not written to the adata object.
- Parameters:
adata (
AnnData) – The anndata object of shape n_obs x n_vars where rows correspond to cells and columns to the channelsn_comps (
int) – The number of dimensions of the representation.neighbors_key (
Optional[str]) – If specified, umap looks .uns[neighbors_key] for neighbors settings and .obsp[f’{neighbors_key}’][‘connectivities_key’] for connectivities.
- Return type:
tuple[ndarray,ndarray]- Returns:
dpt.eigen_basis – The diffusion map coordinates
dpt.eigen_values – The diffusion map eigen values