netmap.downstream.clustering.spectral_clustering¶
- netmap.downstream.clustering.spectral_clustering(adata, n_clu=2, key_added='spectral')¶
Run sklearn spectral clustering on the neighbour matrix in the anndata object.
- Parameters:
grn_adata (AnnData) – A GRN anndata object to process
n_clu (int) – Number of clusters to compute
key_added (str) – The key to add the new labelling to [Default: spectral]
- Returns:
grn_adata – Clustered Anndata object with an additional column in the .obs slot of the object named key_added
- Return type:
AnnData