Basic Usage

[1]:
import stringdb
[2]:
genes = ['TP53', 'BRCA1', 'FANCD1', 'FANCL']
string_ids = stringdb.get_string_ids(genes)
string_ids
[2]:
queryItem queryIndex stringId ncbiTaxonId taxonName preferredName annotation
0 TP53 0 9606.ENSP00000269305 9606 Homo sapiens TP53 Cellular tumor antigen p53; Acts as a tumor su...
1 BRCA1 1 9606.ENSP00000418960 9606 Homo sapiens BRCA1 Breast cancer type 1 susceptibility protein; E...
2 FANCD1 2 9606.ENSP00000369497 9606 Homo sapiens BRCA2 Breast cancer type 2 susceptibility protein; I...
3 FANCL 3 9606.ENSP00000385021 9606 Homo sapiens FANCL E3 ubiquitin-protein ligase FANCL; Ubiquitin l...
[3]:
enrichment_df = stringdb.get_enrichment(string_ids.queryItem)
enrichment_df.sort_values('fdr')
[3]:
category term number_of_genes number_of_genes_in_background ncbiTaxonId inputGenes preferredNames p_value fdr description
64 PMID PMID.22918243 4 8 9606 TP53,FANCD1,FANCL,BRCA1 TP53,BRCA2,FANCL,BRCA1 8.100000e-14 1.160000e-08 (2012) Switch of FANCL, a key FA-BRCA componen...
106 PMID PMID.26842001 4 12 9606 TP53,FANCD1,FANCL,BRCA1 TP53,BRCA2,FANCL,BRCA1 2.980000e-13 2.140000e-08 (2016) Fanconi anemia genes in lung adenocarci...
127 PMID PMID.28423363 4 22 9606 TP53,FANCD1,FANCL,BRCA1 TP53,BRCA2,FANCL,BRCA1 2.450000e-12 2.390000e-08 (2017) Multiple-gene panel analysis in a case ...
126 PMID PMID.28387924 4 15 9606 TP53,FANCD1,FANCL,BRCA1 TP53,BRCA2,FANCL,BRCA1 6.340000e-13 2.390000e-08 (2017) High number of kinome-mutations in non-...
79 PMID PMID.24439051 4 21 9606 TP53,FANCD1,FANCL,BRCA1 TP53,BRCA2,FANCL,BRCA1 2.070000e-12 2.390000e-08 (2014) Poly(ADP-ribose) polymerase inhibitor C...
... ... ... ... ... ... ... ... ... ... ...
12 InterPro IPR013083 2 441 9606 FANCL,BRCA1 FANCL,BRCA1 3.000000e-03 4.170000e-02 Zinc finger, RING/FYVE/PHD-type
150 Process GO.0008285 2 669 9606 TP53,FANCD1 TP53,BRCA2 6.700000e-03 4.210000e-02 negative regulation of cell population prolife...
149 Process GO.0008283 2 676 9606 TP53,FANCD1 TP53,BRCA2 6.900000e-03 4.260000e-02 cell population proliferation
141 Process GO.0006325 2 683 9606 TP53,FANCD1 TP53,BRCA2 7.000000e-03 4.310000e-02 chromatin organization
22 Keyword KW-0007 3 3335 9606 TP53,FANCL,BRCA1 TP53,FANCL,BRCA1 1.730000e-02 4.760000e-02 Acetylation

195 rows × 10 columns

There are 5 functions for querying a list of stringIds, which follow the patter get_*

* can be ‘enrichment’, ‘interaction_partners’, ‘ppi_enrichment’, ‘network’, and ‘functional_annotation’

[ ]: