stlearn.tl.cci.het.count_grid

stlearn.tl.cci.het.count_grid(adata: anndata._core.anndata.AnnData, num_row: int = 30, num_col: int = 30, use_clustering: str = None, use_het: str = 'cci_het_grid', radius: int = 1, verbose: bool = True) → anndata._core.anndata.AnnData

Count the cell type densities :param adata: :type adata: AnnData The data object including the cell types to count :param num_row: :type num_row: int Number of grids on height :param num_col: :type num_col: int Number of grids on width :param use_clustering: :type use_clustering: The cell type results to use in counting :param use_het: :type use_het: The stoarge place for result :param radius: :type radius: int Distance to determine the neighbour grids (default: 1=nearest), radius=0 means within grid

Returns

adata

Return type

AnnData With the counts of specified clusters in each grid of the tissue stored as adata.uns[‘het’]