scdef.tl.multilevel_paga ¶
multilevel_paga(model: scDEF, neighbors_rep: str = 'X_L0', layers: Optional[List[int]] = None, reuse_pos: bool = True, layout: str = 'fa', random_seed: int = 0, **paga_kwargs: Any) -> None
Compute and cache multilevel PAGA results for plotting.
Runs PAGA once per layer over a single shared neighbourhood graph, so the
coarse and fine graphs describe the same cells at different resolutions. Plot
the cached result with scdef.pl.multilevel_paga.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
model
|
scDEF
|
fitted scDEF model, annotated so that |
required |
neighbors_rep
|
str
|
|
'X_L0'
|
layers
|
Optional[List[int]]
|
layer indices to run, coarsest first. Defaults to every layer with more than one factor — a single-factor layer has no graph to draw. |
None
|
reuse_pos
|
bool
|
initialize each layer's layout from the previous, coarser one, so a group stays in roughly the same place as resolution increases and the layers can be read side by side. |
True
|
layout
|
str
|
graph layout passed to scanpy, |
'fa'
|
random_seed
|
int
|
seed for the layout, so repeated runs place nodes identically. |
0
|
**paga_kwargs
|
Any
|
forwarded to |
{}
|