stlearn.add.apply_mask¶
-
stlearn.add.apply_mask(adata: anndata._core.anndata.AnnData, masks: Optional[list] = 'all', select: str = 'black', cmap: str = 'default', copy: bool = False) → Optional[anndata._core.anndata.AnnData][source]¶ Parsing the old spaital transcriptomics data
- Parameters
adata – Anndata object.
masks – List of masks for parsing if all, apply on all masks
select – color for ROI, choose from black and white.
cmap – Color map to use.
copy – Return a copy instead of writing to adata.
- Returns
Depending on copy, returns or updates adata with the following fields.
**mask_image** (adata.uns field) – Array format of image, saving by Pillow package.