chrysalis.plot_compartment
- chrysalis.plot_compartment(adata: AnnData, fig: figure, ax: axis, selected_dim: int, dim: int = 8, hexcodes: Optional[List[str]] = None, seed: Optional[int] = None, color_first: str = 'black', rotation: Union[int, float] = 0, sample_id: Optional[Union[int, str]] = None, spot_size: float = 1.05, marker: str = 'h', backend='patch_collection', **scr_kw)
Visualize individual tissue compartments.
- Parameters:
adata – The AnnData data matrix of shape n_obs × n_vars. Rows correspond to cells and columns to genes.
fig – Matplotlib figure.
ax – Matplotlib axis.
selected_dim – Selected compartment.
dim – Total number of compartments.
hexcodes – List of hexadecimal colors to replace the default colormap.
seed – Random seed, used for mixing colors.
color_first – Color mapped to 0 domain score values.
sample_id – Sample id defined by .obs[‘sample’] column.
spot_size – Fine adjustments of the spot size.
marker – Marker type.
scr_kw – Matplotlib scatterplot keyword arguments.