top_counts_genes

besca.pp.top_counts_genes(adata, top_n=10)[source]

Give out the genes that contribute the largest fraction to the total UMI counts.

Calculates the genes which contribute the largest fraction of UMI counts to the total

UMI counts (i.e. the most abundant transcripts).

Parameters:
  • adata (AnnData) – The annotated data matrix.

  • top_n (int | default = 10) – Integer defining the number of entries to return. If None then the entire table is returned.

Returns:

pandas DataFrame containing the top_n genes

Return type:

DataFrame

Example

>>> import besca as bc
>>> adata = bc.datasets.simulated_pbmc3k_raw()
>>> genes = bc.pp.top_counts_genes(adata)