louvain
Detect communities in single-cell RNA sequencing data using the Louvain clustering algorithm. Customize resolution, random state, and clustering flavor (vtraag, igraph, RAPIDS) for precise cell grouping.
Instructions
Louvain clustering algorithm for community detection
Input Schema
Name | Required | Description | Default |
---|---|---|---|
directed | No | Interpret the adjacency matrix as directed graph. | |
flavor | No | Package for computing the clustering: 'vtraag' (default, more powerful), 'igraph' (built-in method), or 'rapids' (GPU accelerated). | vtraag |
key_added | No | Key under which to add the cluster labels. | louvain |
neighbors_key | No | Use neighbors connectivities as adjacency. If specified, louvain looks .obsp[.uns[neighbors_key]['connectivities_key']] for connectivities. | |
obsp | No | Use .obsp[obsp] as adjacency. You can't specify both `obsp` and `neighbors_key` at the same time. | |
partition_kwargs | No | Key word arguments to pass to partitioning, if 'vtraag' method is being used. | |
random_state | No | Change the initialization of the optimization. | |
resolution | No | For the default flavor ('vtraag') or for 'RAPIDS', you can provide a resolution (higher resolution means finding more and smaller clusters), which defaults to 1.0. | |
use_weights | No | Use weights from knn graph. |