ToppGene database function
topppy.topp_gene
get_entrez
get_entrez(genes: list) -> list
Convert genes into Entrez format
| Parameters: |
|
|---|
Returns: a vector of genes in Entrez format
Examples:
from topppy import get_entrez
get_entrez(genes)
get_topp_cats
get_topp_cats() -> list
Get a list of ToppFun categories
Returns: a list
Examples:
from topppy import get_topp_cats
get_topp_cats()
topp_fun
topp_fun(markers: DataFrame, topp_categories: list = None, cluster_col: str = 'cluster', gene_col: str = 'gene', p_val_col: str = 'adj_p_val_col', logFC_col: str = 'avg_logFC', num_genes: int = 1000, pval_cutoff: float = 0.5, fc_cutoff: float = 0, fc_filter: str = 'ALL', clusters: list = None, correction: str = 'FDR', key_type: str = 'SYMBOL', min_genes: int = 2, max_genes: int = 1500, max_results: int = 50) -> DataFrame
The topp_fun() function takes a DataFrame and selects genes to use in querying ToppGene.
| Parameters: |
|
|---|
Returns: DataFrame
Examples:
from topppy import *
toppdata=topp_fun(ifnb_de,topp_categories=None,cluster_col='celltype',gene_col='gene',p_val_col='p_val_adj',logFC_col='avg_log2FC')
topp_save
topp_save(topp_data: DataFrame, filename: str = None, save_dir: str = None, split: bool = False, format: str = 'xlsx') -> None
Save topp_data results (optionally) split by celltype/cluster
| Parameters: |
|
|---|
Returns: None
Examples:
from topppy import topp_save, topp_data
topp_save(topp_data, filename="toppFun_results", split = True, format = "xlsx")