BioClients 0.2.30__tar.gz → 0.2.34__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {BioClients-0.2.30/BioClients.egg-info → bioclients-0.2.34}/PKG-INFO +36 -20
- {BioClients-0.2.30 → bioclients-0.2.34}/README.md +11 -11
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chebi/Client.py +35 -11
- BioClients-0.2.30/BioClients/chebi/Utils.py → bioclients-0.2.34/bioclients/chebi/Client_SOAP.py +68 -3
- bioclients-0.2.34/bioclients/chebi/Utils.py +170 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chembl/Utils.py +16 -6
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/drugcentral/Client.py +4 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/drugcentral/Utils.py +39 -0
- bioclients-0.2.34/bioclients/fda/aer/Client.py +69 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/fda/aer/Utils.py +78 -54
- bioclients-0.2.34/bioclients/ncats/__init__.py +2 -0
- bioclients-0.2.34/bioclients/ncats/stitcher/Client.py +72 -0
- bioclients-0.2.34/bioclients/ncats/stitcher/Utils.py +94 -0
- bioclients-0.2.34/bioclients/tinx/Client.py +85 -0
- bioclients-0.2.34/bioclients/tinx/Utils.py +180 -0
- bioclients-0.2.34/bioclients/uniprot/Client.py +70 -0
- bioclients-0.2.34/bioclients/uniprot/Utils.py +191 -0
- bioclients-0.2.34/bioclients/util/owl/App.py +110 -0
- bioclients-0.2.34/bioclients/util/owl/Utils.py +163 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/pandas/App.py +20 -17
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/rdf/Utils.py +2 -3
- bioclients-0.2.34/bioclients/who/__init__.py +1 -0
- bioclients-0.2.34/bioclients/who/atc/Client.py +54 -0
- bioclients-0.2.34/bioclients/who/atc/Utils.py +45 -0
- bioclients-0.2.34/bioclients/who/atc/__init__.py +1 -0
- bioclients-0.2.34/bioclients/wikidata/__init__.py +1 -0
- bioclients-0.2.34/bioclients/wikipathways/__init__.py +1 -0
- {BioClients-0.2.30 → bioclients-0.2.34/bioclients.egg-info}/PKG-INFO +36 -20
- bioclients-0.2.34/bioclients.egg-info/SOURCES.txt +302 -0
- bioclients-0.2.34/bioclients.egg-info/requires.txt +10 -0
- bioclients-0.2.34/bioclients.egg-info/top_level.txt +1 -0
- bioclients-0.2.34/pyproject.toml +34 -0
- {BioClients-0.2.30 → bioclients-0.2.34}/setup.py +8 -4
- BioClients-0.2.30/BioClients/fda/aer/Client.py +0 -81
- BioClients-0.2.30/BioClients/ncats/__init__.py +0 -1
- BioClients-0.2.30/BioClients/uniprot/Client.py +0 -61
- BioClients-0.2.30/BioClients/uniprot/Utils.py +0 -43
- BioClients-0.2.30/BioClients/util/owl/App.py +0 -31
- BioClients-0.2.30/BioClients/util/owl/Utils.py +0 -34
- BioClients-0.2.30/BioClients.egg-info/SOURCES.txt +0 -289
- BioClients-0.2.30/BioClients.egg-info/top_level.txt +0 -1
- {BioClients-0.2.30 → bioclients-0.2.34}/LICENSE +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/allen/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/allen/brain/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/allen/brain/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/allen/brain/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/amp/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/amp/t2d/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/amp/t2d/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/amp/t2d/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/badapple/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/badapple/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/badapple/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/bindingdb/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/bindingdb/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/bindingdb/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/biogrid/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/biogrid/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/biogrid/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/biomarkerkb/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/biomarkerkb/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/biomarkerkb/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/bioregistry/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/bioregistry/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/bioregistry/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/brenda/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/brenda/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/brenda/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cas/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cas/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cas/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cdc/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cdc/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cdc/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cfde/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cfde/cfchemdb/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cfde/cfchemdb/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/cfde/cfchemdb/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chebi/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chem2bio2rdf/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chem2bio2rdf/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chem2bio2rdf/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chem2bio2rdf/slap/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chem2bio2rdf/slap/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chem2bio2rdf/slap/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chembl/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chembl/FetchByID.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chembl/UnichemClient.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chembl/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chemidplus/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chemidplus/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/chemidplus/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/clinicaltrials/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/clinicaltrials/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/clinicaltrials/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/disgenet/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/disgenet/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/disgenet/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/dnorm/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/dnorm/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/drugcentral/Test.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/drugcentral/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/emblebi/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/emblebi/identifiers/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/emblebi/identifiers/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/emblebi/identifiers/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/emblebi/unichem/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/emblebi/unichem/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/emblebi/unichem/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ensembl/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ensembl/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ensembl/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ensembl/biomart/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ensembl/biomart/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ensembl/biomart/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/entrez/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/entrez/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/entrez/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/fda/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/fda/aer/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/geneontology/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/geneontology/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/geneontology/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/glygen/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/glygen/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/glygen/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/gtex/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/gtex/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/gtex/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/gwascatalog/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/gwascatalog/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/gwascatalog/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/hubmap/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/hubmap/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/hubmap/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/hugo/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/hugo/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/hugo/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/humanbase/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/humanbase/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/icite/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/icite/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/icite/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/pharos/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/pharos/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/pharos/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/rss/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/rss/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/rss/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tcrd/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tcrd/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tcrd/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tiga/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tiga/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tiga/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tinx/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tinx/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/idg/tinx/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/iuphar/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/iuphar/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/iuphar/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/jensenlab/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/jensenlab/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/jensenlab/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/lincs/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/lincs/Client_lincscloud.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/lincs/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/lincs/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/lincs/sigcom/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/lincs/sigcom/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/lincs/sigcom/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/maayanlab/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/maayanlab/archs4/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/maayanlab/archs4/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/maayanlab/archs4/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/maayanlab/harmonizome/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/maayanlab/harmonizome/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/maayanlab/harmonizome/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/medline/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/medline/connect/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/medline/connect/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/medline/connect/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/medline/genetics/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/medline/genetics/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/medline/genetics/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/mesh/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/mesh/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/mesh/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/monarch/Biolink.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/monarch/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/monarch/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/monarch/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/mygene/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/mygene/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/mygene/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ncats/gsrs/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ncats/gsrs/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ncats/gsrs/__init__.py +0 -0
- {BioClients-0.2.30/BioClients/ncbo → bioclients-0.2.34/bioclients/ncats/stitcher}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ncbo/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ncbo/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/oncotree → bioclients-0.2.34/bioclients/ncbo}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/omim/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/omim/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/oncotree/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/oncotree/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/openphacts → bioclients-0.2.34/bioclients/oncotree}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/openphacts/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/openphacts/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/opentargets → bioclients-0.2.34/bioclients/openphacts}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/opentargets/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/opentargets/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/pdb → bioclients-0.2.34/bioclients/opentargets}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/panther/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/panther/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pdb/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pdb/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/pubchem/ftp → bioclients-0.2.34/bioclients/pdb}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/pubchem/soap → bioclients-0.2.34/bioclients/pubchem/ftp}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/pubchem_ftp_actives.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/pubchem_ftp_assay_fetch.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/pubchem_ftp_assay_results.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/pubchem_ftp_assay_search.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/pubchem_ftp_assaysim.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/pubchem_ftp_compound_assaystats.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/ftp/pubchem_ftp_gini_index.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/rdf/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/rdf/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/soap/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/soap/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/pubtator → bioclients-0.2.34/bioclients/pubchem/soap}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/soap/pug_aids2assays.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/soap/pug_ids2mols.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubchem/soap/pug_substance_search.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubmed/App_XML.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubmed/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubmed/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubmed/Utils_XML.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubmed/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubtator/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/pubtator/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/rxnorm → bioclients-0.2.34/bioclients/pubtator}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/reactome/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/reactome/SMBL_utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/reactome/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/reactome/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/rxnorm/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/rxnorm/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/stringdb → bioclients-0.2.34/bioclients/rxnorm}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/stringdb/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/stringdb/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/tcga → bioclients-0.2.34/bioclients/stringdb}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/tcga/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/tcga/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/ubkg → bioclients-0.2.34/bioclients/tcga}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients/umls → bioclients-0.2.34/bioclients/tinx}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ubkg/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/ubkg/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/uniprot → bioclients-0.2.34/bioclients/ubkg}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/umls/CPTClient.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/umls/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/umls/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/db → bioclients-0.2.34/bioclients/umls}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients/util/graphql → bioclients-0.2.34/bioclients/uniprot}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/db/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/hdf → bioclients-0.2.34/bioclients/util/db}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/graphql/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/igraph → bioclients-0.2.34/bioclients/util/graphql}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/hdf/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/neo4j → bioclients-0.2.34/bioclients/util/hdf}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/igraph/App.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/igraph/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/obo → bioclients-0.2.34/bioclients/util/igraph}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/neo4j/App.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/neo4j/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/owl → bioclients-0.2.34/bioclients/util/neo4j}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/obo/App.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/obo/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/pandas → bioclients-0.2.34/bioclients/util/obo}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients/util/rdf → bioclients-0.2.34/bioclients/util/owl}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/pandas/Csv2Html.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/pandas/Csv2Markdown.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/pandas/Csv2Sql.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/pandas/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/rest → bioclients-0.2.34/bioclients/util/pandas}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/rdf/App.py +0 -0
- {BioClients-0.2.30/BioClients/util/sparql → bioclients-0.2.34/bioclients/util/rdf}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/rest/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/xml → bioclients-0.2.34/bioclients/util/rest}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/sparql/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/sparql/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/util/yaml → bioclients-0.2.34/bioclients/util/sparql}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/xml/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/wikidata → bioclients-0.2.34/bioclients/util/xml}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/util/yaml/Utils.py +0 -0
- {BioClients-0.2.30/BioClients/wikipathways → bioclients-0.2.34/bioclients/util/yaml}/__init__.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/wikidata/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/wikidata/Utils.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/wikipathways/Client.py +0 -0
- {BioClients-0.2.30/BioClients → bioclients-0.2.34/bioclients}/wikipathways/Utils.py +0 -0
- {BioClients-0.2.30/BioClients.egg-info → bioclients-0.2.34/bioclients.egg-info}/dependency_links.txt +0 -0
- {BioClients-0.2.30 → bioclients-0.2.34}/setup.cfg +0 -0
|
@@ -1,18 +1,34 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
2
|
-
Name:
|
|
3
|
-
Version: 0.2.
|
|
4
|
-
Summary: Clients for online biomedical resources, usually via REST APIs.
|
|
5
|
-
Home-page: https://github.com/jeremyjyang/
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: bioclients
|
|
3
|
+
Version: 0.2.34
|
|
4
|
+
Summary: Clients and tools for online biomedical resources, usually via REST APIs.
|
|
5
|
+
Home-page: https://github.com/jeremyjyang/bioclients
|
|
6
6
|
Author: Jeremy Yang
|
|
7
|
-
Author-email: jeremyjyang@gmail.com
|
|
7
|
+
Author-email: Jeremy J Yang <jeremyjyang@gmail.com>
|
|
8
|
+
License-Expression: MIT AND (Apache-2.0 OR BSD-2-Clause)
|
|
9
|
+
Project-URL: HomePage, https://github.com/jeremyjyang/bioclients
|
|
10
|
+
Classifier: Development Status :: 4 - Beta
|
|
11
|
+
Classifier: Intended Audience :: Developers
|
|
8
12
|
Classifier: Programming Language :: Python :: 3
|
|
9
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
10
|
-
Classifier: Operating System :: OS Independent
|
|
11
13
|
Requires-Python: >=3.10
|
|
12
14
|
Description-Content-Type: text/markdown
|
|
13
15
|
License-File: LICENSE
|
|
14
|
-
|
|
15
|
-
|
|
16
|
+
Requires-Dist: pandas
|
|
17
|
+
Requires-Dist: readline
|
|
18
|
+
Requires-Dist: requests
|
|
19
|
+
Requires-Dist: pyyaml
|
|
20
|
+
Requires-Dist: numpy
|
|
21
|
+
Requires-Dist: pyquery
|
|
22
|
+
Requires-Dist: sqlalchemy
|
|
23
|
+
Requires-Dist: psycopg2
|
|
24
|
+
Requires-Dist: click
|
|
25
|
+
Requires-Dist: tqdm
|
|
26
|
+
Dynamic: author
|
|
27
|
+
Dynamic: home-page
|
|
28
|
+
Dynamic: license-file
|
|
29
|
+
Dynamic: requires-python
|
|
30
|
+
|
|
31
|
+
# `bioclients` <img align="right" src="doc/images/bioclients.png" height="120" alt="bioclients logo">
|
|
16
32
|
|
|
17
33
|
Python package for access to online biomedical resources,
|
|
18
34
|
usually via REST APIs. Modules generally include
|
|
@@ -26,16 +42,16 @@ and transforms into usable formats, often TSV.
|
|
|
26
42
|
|
|
27
43
|
### Installing from PyPI
|
|
28
44
|
|
|
29
|
-
Releases at <https://pypi.org/project/
|
|
45
|
+
Releases at <https://pypi.org/project/bioclients/>.
|
|
30
46
|
|
|
31
47
|
```
|
|
32
|
-
pip3 install
|
|
48
|
+
pip3 install bioclients
|
|
33
49
|
```
|
|
34
50
|
However, current development snapshot may included additional functionality.
|
|
35
51
|
|
|
36
52
|
### Installing from source
|
|
37
53
|
|
|
38
|
-
Source at <https://github.com/jeremyjyang/
|
|
54
|
+
Source at <https://github.com/jeremyjyang/bioclients>
|
|
39
55
|
|
|
40
56
|
___(First download or clone.)___
|
|
41
57
|
|
|
@@ -49,7 +65,7 @@ python3 -m pip install --upgrade build
|
|
|
49
65
|
Install using `build`. This supercedes the deprecated `setup.py install` and `easy_install` methods.
|
|
50
66
|
|
|
51
67
|
```
|
|
52
|
-
cd
|
|
68
|
+
cd bioclients
|
|
53
69
|
python3 -m build
|
|
54
70
|
```
|
|
55
71
|
|
|
@@ -60,14 +76,14 @@ python3 -m build
|
|
|
60
76
|
|
|
61
77
|
## Modules
|
|
62
78
|
|
|
63
|
-
[__Allen__](doc/allen.md) • [__AMP-T2D__](doc/amp__t2d.md) • [__Badapple__](doc/badapple.md) • [__BindingDb__](doc/bindingdb.md) • [__BioGrid__](doc/biogrid.md) • [__BiomarkerKB__](doc/biomarkerkb.md) • [__Bioregistry__](doc/bioregistry.md) • [__BRENDA__](doc/brenda.md) • [__CAS__](doc/cas.md) • [__CDC__](doc/cdc.md) • [__CFDE__](doc/cfde.md) • [__Chem2Bio2RDF__](doc/chem2bio2rdf.md) • [__ChEBI__](doc/chebi.md) • [__ChEMBL__](doc/chembl.md) • [__ChemIdPlus__](doc/chemidplus.md) • [__ClinicalTrials.gov__](doc/clinicaltrials.md) • [__Disease Ontology__](doc/diseaseontology.md) • [__DisGeNet__](doc/disgenet.md) • [__DNorm__](doc/dnorm.md) • [__DrugCentral__](doc/drugcentral.md) • [__EMBL-EBI__](doc/emblebi.md) • [__EnsEMBL__](doc/ensembl.md) • [__Entrez__](doc/entrez.md) • [__FDA__](doc/fda.md) • [__Gene Ontology__](doc/geneontology.md) • [__GTEx__](doc/gtex.md) • [__GWAS Catalog__](doc/gwascatalog.md) • [__HUGO__](doc/hugo.md) • [__HumanBase__](doc/humanbase.md) • [__iCite__](doc/icite.md) • [__IDG__](doc/idg.md) • [__JensenLab__](doc/jensenlab.md) • [__LINCS__](doc/lincs.md) • [__MaayanLab__](doc/maayanlab.md) • [__Medline__](doc/medline.md) • [__MeSH__](doc/mesh.md) • [__MONARCH__](doc/monarch.md) • [__MyGene__](doc/mygene.md) • [__NCBO__](doc/ncbo.md) • [__NCATS__](doc/ncats.md) • [__OMIM__](doc/omim.md) • [__OncoTree__](doc/oncotree.md) • [__Open Targets__](doc/opentargets.md) • [__Panther__](doc/panther.md) • [__PDB__](doc/pdb.md) • [__PubChem__](doc/pubchem.md) • [__PubMed__](doc/pubmed.md) • [__PubTator__](doc/pubtator.md) • [__Reactome__](doc/reactome.md) • [__RXNorm__](doc/rxnorm.md) • [__STRINGDB__](doc/stringdb.md) • [__TCGA__](doc/tcga.md) • [__UBKG__](doc/ubkg.md) • [__UMLS__](doc/umls.md) • [__UniProt__](doc/uniprot.md) • [__Wikidata__](doc/wikidata.md) • [__WikiPathways__](doc/wikipathways.md)
|
|
79
|
+
[__Allen__](doc/allen.md) • [__AMP-T2D__](doc/amp__t2d.md) • [__Badapple__](doc/badapple.md) • [__BindingDb__](doc/bindingdb.md) • [__BioGrid__](doc/biogrid.md) • [__BiomarkerKB__](doc/biomarkerkb.md) • [__Bioregistry__](doc/bioregistry.md) • [__BRENDA__](doc/brenda.md) • [__CAS__](doc/cas.md) • [__CDC__](doc/cdc.md) • [__CFDE__](doc/cfde.md) • [__Chem2Bio2RDF__](doc/chem2bio2rdf.md) • [__ChEBI__](doc/chebi.md) • [__ChEMBL__](doc/chembl.md) • [__ChemIdPlus__](doc/chemidplus.md) • [__ClinicalTrials.gov__](doc/clinicaltrials.md) • [__Disease Ontology__](doc/diseaseontology.md) • [__DisGeNet__](doc/disgenet.md) • [__DNorm__](doc/dnorm.md) • [__DrugCentral__](doc/drugcentral.md) • [__EMBL-EBI__](doc/emblebi.md) • [__EnsEMBL__](doc/ensembl.md) • [__Entrez__](doc/entrez.md) • [__FDA__](doc/fda.md) • [__Gene Ontology__](doc/geneontology.md) • [__GTEx__](doc/gtex.md) • [__GWAS Catalog__](doc/gwascatalog.md) • [__HUGO__](doc/hugo.md) • [__HumanBase__](doc/humanbase.md) • [__iCite__](doc/icite.md) • [__IDG__](doc/idg.md) • [__JensenLab__](doc/jensenlab.md) • [__LINCS__](doc/lincs.md) • [__MaayanLab__](doc/maayanlab.md) • [__Medline__](doc/medline.md) • [__MeSH__](doc/mesh.md) • [__MONARCH__](doc/monarch.md) • [__MyGene__](doc/mygene.md) • [__NCBO__](doc/ncbo.md) • [__NCATS__](doc/ncats.md) • [__OMIM__](doc/omim.md) • [__OncoTree__](doc/oncotree.md) • [__Open Targets__](doc/opentargets.md) • [__Panther__](doc/panther.md) • [__PDB__](doc/pdb.md) • [__PubChem__](doc/pubchem.md) • [__PubMed__](doc/pubmed.md) • [__PubTator__](doc/pubtator.md) • [__Reactome__](doc/reactome.md) • [__RXNorm__](doc/rxnorm.md) • [__STRINGDB__](doc/stringdb.md) • [__TCGA__](doc/tcga.md) • [__TINX__](doc/tinx.md) • [__UBKG__](doc/ubkg.md) • [__UMLS__](doc/umls.md) • [__UniProt__](doc/uniprot.md) • [__Wikidata__](doc/wikidata.md) • [__WikiPathways__](doc/wikipathways.md)
|
|
64
80
|
|
|
65
81
|
Miscellaneous utilities: [__UTIL__](doc/util.md)
|
|
66
82
|
|
|
67
83
|
## Usage Example
|
|
68
84
|
|
|
69
85
|
```
|
|
70
|
-
python3 -m
|
|
86
|
+
python3 -m bioclients.pubchem.Client -h
|
|
71
87
|
```
|
|
72
88
|
|
|
73
89
|
## Design pattern
|
|
@@ -80,7 +96,7 @@ or return a Pandas dataframe (if output file unspecified).
|
|
|
80
96
|
|
|
81
97
|
## Data structures and formats, XML, JSON, and TSV
|
|
82
98
|
|
|
83
|
-
|
|
99
|
+
bioclients is designed to be simple and practical, and XML, JSON
|
|
84
100
|
and TSV are likewise simple in many respects, yet a great deal
|
|
85
101
|
of conceptual and technological progress is reflected. XML and JSON
|
|
86
102
|
can represent arbitrarily complex data objects, comprised of nested lists,
|
|
@@ -92,7 +108,7 @@ applications (e.g. machine learning).
|
|
|
92
108
|
|
|
93
109
|
## Conda environment
|
|
94
110
|
|
|
95
|
-
|
|
111
|
+
bioclients depends on numerous Python packages. (See [conda/environment.yml](conda/environment.yml)).
|
|
96
112
|
The following commands create and activate a Conda environment `bioclients`:
|
|
97
113
|
|
|
98
114
|
```
|
|
@@ -105,7 +121,7 @@ $ conda create -n bioclients -c conda-forge pandas readline requests pyyaml tqdm
|
|
|
105
121
|
then:
|
|
106
122
|
```
|
|
107
123
|
$ conda activate bioclients
|
|
108
|
-
(bioclients) $ pip install
|
|
124
|
+
(bioclients) $ pip install bioclients
|
|
109
125
|
```
|
|
110
126
|
and install additional packages as needed via `pip`, e.g.:
|
|
111
127
|
```
|
|
@@ -119,4 +135,4 @@ and install additional packages as needed via `pip`, e.g.:
|
|
|
119
135
|
|
|
120
136
|
## Venv, etc.
|
|
121
137
|
|
|
122
|
-
It may not be necessary or advantageous to configure an environment for all of
|
|
138
|
+
It may not be necessary or advantageous to configure an environment for all of bioclients functionality. Specific modules may be supported with `venv` environments with required dependencies. Module documentation should indicate needed package dependencies.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# `
|
|
1
|
+
# `bioclients` <img align="right" src="doc/images/bioclients.png" height="120" alt="bioclients logo">
|
|
2
2
|
|
|
3
3
|
Python package for access to online biomedical resources,
|
|
4
4
|
usually via REST APIs. Modules generally include
|
|
@@ -12,16 +12,16 @@ and transforms into usable formats, often TSV.
|
|
|
12
12
|
|
|
13
13
|
### Installing from PyPI
|
|
14
14
|
|
|
15
|
-
Releases at <https://pypi.org/project/
|
|
15
|
+
Releases at <https://pypi.org/project/bioclients/>.
|
|
16
16
|
|
|
17
17
|
```
|
|
18
|
-
pip3 install
|
|
18
|
+
pip3 install bioclients
|
|
19
19
|
```
|
|
20
20
|
However, current development snapshot may included additional functionality.
|
|
21
21
|
|
|
22
22
|
### Installing from source
|
|
23
23
|
|
|
24
|
-
Source at <https://github.com/jeremyjyang/
|
|
24
|
+
Source at <https://github.com/jeremyjyang/bioclients>
|
|
25
25
|
|
|
26
26
|
___(First download or clone.)___
|
|
27
27
|
|
|
@@ -35,7 +35,7 @@ python3 -m pip install --upgrade build
|
|
|
35
35
|
Install using `build`. This supercedes the deprecated `setup.py install` and `easy_install` methods.
|
|
36
36
|
|
|
37
37
|
```
|
|
38
|
-
cd
|
|
38
|
+
cd bioclients
|
|
39
39
|
python3 -m build
|
|
40
40
|
```
|
|
41
41
|
|
|
@@ -46,14 +46,14 @@ python3 -m build
|
|
|
46
46
|
|
|
47
47
|
## Modules
|
|
48
48
|
|
|
49
|
-
[__Allen__](doc/allen.md) • [__AMP-T2D__](doc/amp__t2d.md) • [__Badapple__](doc/badapple.md) • [__BindingDb__](doc/bindingdb.md) • [__BioGrid__](doc/biogrid.md) • [__BiomarkerKB__](doc/biomarkerkb.md) • [__Bioregistry__](doc/bioregistry.md) • [__BRENDA__](doc/brenda.md) • [__CAS__](doc/cas.md) • [__CDC__](doc/cdc.md) • [__CFDE__](doc/cfde.md) • [__Chem2Bio2RDF__](doc/chem2bio2rdf.md) • [__ChEBI__](doc/chebi.md) • [__ChEMBL__](doc/chembl.md) • [__ChemIdPlus__](doc/chemidplus.md) • [__ClinicalTrials.gov__](doc/clinicaltrials.md) • [__Disease Ontology__](doc/diseaseontology.md) • [__DisGeNet__](doc/disgenet.md) • [__DNorm__](doc/dnorm.md) • [__DrugCentral__](doc/drugcentral.md) • [__EMBL-EBI__](doc/emblebi.md) • [__EnsEMBL__](doc/ensembl.md) • [__Entrez__](doc/entrez.md) • [__FDA__](doc/fda.md) • [__Gene Ontology__](doc/geneontology.md) • [__GTEx__](doc/gtex.md) • [__GWAS Catalog__](doc/gwascatalog.md) • [__HUGO__](doc/hugo.md) • [__HumanBase__](doc/humanbase.md) • [__iCite__](doc/icite.md) • [__IDG__](doc/idg.md) • [__JensenLab__](doc/jensenlab.md) • [__LINCS__](doc/lincs.md) • [__MaayanLab__](doc/maayanlab.md) • [__Medline__](doc/medline.md) • [__MeSH__](doc/mesh.md) • [__MONARCH__](doc/monarch.md) • [__MyGene__](doc/mygene.md) • [__NCBO__](doc/ncbo.md) • [__NCATS__](doc/ncats.md) • [__OMIM__](doc/omim.md) • [__OncoTree__](doc/oncotree.md) • [__Open Targets__](doc/opentargets.md) • [__Panther__](doc/panther.md) • [__PDB__](doc/pdb.md) • [__PubChem__](doc/pubchem.md) • [__PubMed__](doc/pubmed.md) • [__PubTator__](doc/pubtator.md) • [__Reactome__](doc/reactome.md) • [__RXNorm__](doc/rxnorm.md) • [__STRINGDB__](doc/stringdb.md) • [__TCGA__](doc/tcga.md) • [__UBKG__](doc/ubkg.md) • [__UMLS__](doc/umls.md) • [__UniProt__](doc/uniprot.md) • [__Wikidata__](doc/wikidata.md) • [__WikiPathways__](doc/wikipathways.md)
|
|
49
|
+
[__Allen__](doc/allen.md) • [__AMP-T2D__](doc/amp__t2d.md) • [__Badapple__](doc/badapple.md) • [__BindingDb__](doc/bindingdb.md) • [__BioGrid__](doc/biogrid.md) • [__BiomarkerKB__](doc/biomarkerkb.md) • [__Bioregistry__](doc/bioregistry.md) • [__BRENDA__](doc/brenda.md) • [__CAS__](doc/cas.md) • [__CDC__](doc/cdc.md) • [__CFDE__](doc/cfde.md) • [__Chem2Bio2RDF__](doc/chem2bio2rdf.md) • [__ChEBI__](doc/chebi.md) • [__ChEMBL__](doc/chembl.md) • [__ChemIdPlus__](doc/chemidplus.md) • [__ClinicalTrials.gov__](doc/clinicaltrials.md) • [__Disease Ontology__](doc/diseaseontology.md) • [__DisGeNet__](doc/disgenet.md) • [__DNorm__](doc/dnorm.md) • [__DrugCentral__](doc/drugcentral.md) • [__EMBL-EBI__](doc/emblebi.md) • [__EnsEMBL__](doc/ensembl.md) • [__Entrez__](doc/entrez.md) • [__FDA__](doc/fda.md) • [__Gene Ontology__](doc/geneontology.md) • [__GTEx__](doc/gtex.md) • [__GWAS Catalog__](doc/gwascatalog.md) • [__HUGO__](doc/hugo.md) • [__HumanBase__](doc/humanbase.md) • [__iCite__](doc/icite.md) • [__IDG__](doc/idg.md) • [__JensenLab__](doc/jensenlab.md) • [__LINCS__](doc/lincs.md) • [__MaayanLab__](doc/maayanlab.md) • [__Medline__](doc/medline.md) • [__MeSH__](doc/mesh.md) • [__MONARCH__](doc/monarch.md) • [__MyGene__](doc/mygene.md) • [__NCBO__](doc/ncbo.md) • [__NCATS__](doc/ncats.md) • [__OMIM__](doc/omim.md) • [__OncoTree__](doc/oncotree.md) • [__Open Targets__](doc/opentargets.md) • [__Panther__](doc/panther.md) • [__PDB__](doc/pdb.md) • [__PubChem__](doc/pubchem.md) • [__PubMed__](doc/pubmed.md) • [__PubTator__](doc/pubtator.md) • [__Reactome__](doc/reactome.md) • [__RXNorm__](doc/rxnorm.md) • [__STRINGDB__](doc/stringdb.md) • [__TCGA__](doc/tcga.md) • [__TINX__](doc/tinx.md) • [__UBKG__](doc/ubkg.md) • [__UMLS__](doc/umls.md) • [__UniProt__](doc/uniprot.md) • [__Wikidata__](doc/wikidata.md) • [__WikiPathways__](doc/wikipathways.md)
|
|
50
50
|
|
|
51
51
|
Miscellaneous utilities: [__UTIL__](doc/util.md)
|
|
52
52
|
|
|
53
53
|
## Usage Example
|
|
54
54
|
|
|
55
55
|
```
|
|
56
|
-
python3 -m
|
|
56
|
+
python3 -m bioclients.pubchem.Client -h
|
|
57
57
|
```
|
|
58
58
|
|
|
59
59
|
## Design pattern
|
|
@@ -66,7 +66,7 @@ or return a Pandas dataframe (if output file unspecified).
|
|
|
66
66
|
|
|
67
67
|
## Data structures and formats, XML, JSON, and TSV
|
|
68
68
|
|
|
69
|
-
|
|
69
|
+
bioclients is designed to be simple and practical, and XML, JSON
|
|
70
70
|
and TSV are likewise simple in many respects, yet a great deal
|
|
71
71
|
of conceptual and technological progress is reflected. XML and JSON
|
|
72
72
|
can represent arbitrarily complex data objects, comprised of nested lists,
|
|
@@ -78,7 +78,7 @@ applications (e.g. machine learning).
|
|
|
78
78
|
|
|
79
79
|
## Conda environment
|
|
80
80
|
|
|
81
|
-
|
|
81
|
+
bioclients depends on numerous Python packages. (See [conda/environment.yml](conda/environment.yml)).
|
|
82
82
|
The following commands create and activate a Conda environment `bioclients`:
|
|
83
83
|
|
|
84
84
|
```
|
|
@@ -91,7 +91,7 @@ $ conda create -n bioclients -c conda-forge pandas readline requests pyyaml tqdm
|
|
|
91
91
|
then:
|
|
92
92
|
```
|
|
93
93
|
$ conda activate bioclients
|
|
94
|
-
(bioclients) $ pip install
|
|
94
|
+
(bioclients) $ pip install bioclients
|
|
95
95
|
```
|
|
96
96
|
and install additional packages as needed via `pip`, e.g.:
|
|
97
97
|
```
|
|
@@ -105,4 +105,4 @@ and install additional packages as needed via `pip`, e.g.:
|
|
|
105
105
|
|
|
106
106
|
## Venv, etc.
|
|
107
107
|
|
|
108
|
-
It may not be necessary or advantageous to configure an environment for all of
|
|
108
|
+
It may not be necessary or advantageous to configure an environment for all of bioclients functionality. Specific modules may be supported with `venv` environments with required dependencies. Module documentation should indicate needed package dependencies.
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env python3
|
|
2
2
|
"""
|
|
3
|
-
Utility for ChEBI
|
|
3
|
+
Utility for ChEBI REST API.
|
|
4
4
|
|
|
5
|
-
* https://www.ebi.ac.uk/chebi/
|
|
5
|
+
* https://www.ebi.ac.uk/chebi/
|
|
6
|
+
* https://www.ebi.ac.uk/chebi/backend/api/docs/
|
|
6
7
|
"""
|
|
7
8
|
###
|
|
8
9
|
import sys,os,re,json,argparse,time,logging
|
|
@@ -12,19 +13,28 @@ from .. import chebi
|
|
|
12
13
|
#
|
|
13
14
|
##############################################################################
|
|
14
15
|
if __name__=='__main__':
|
|
15
|
-
epilog="
|
|
16
|
-
|
|
16
|
+
epilog="""\
|
|
17
|
+
Note that database accessions include citations.
|
|
18
|
+
Example entity IDs: 16737, 30273,33246,24433\
|
|
19
|
+
"""
|
|
20
|
+
parser = argparse.ArgumentParser(description='ChEBI REST API client', epilog=epilog)
|
|
17
21
|
ops = [
|
|
22
|
+
"list_sources",
|
|
18
23
|
"get_entity",
|
|
24
|
+
"get_entity_names",
|
|
25
|
+
"get_entity_secondary_ids",
|
|
26
|
+
"get_entity_database_accessions",
|
|
19
27
|
"get_entity_children",
|
|
20
28
|
"get_entity_parents",
|
|
29
|
+
"get_entity_origins",
|
|
30
|
+
"get_compound_data",
|
|
21
31
|
"search"
|
|
22
32
|
]
|
|
23
33
|
parser.add_argument("op", choices=ops, help='OPERATION (select one)')
|
|
24
34
|
parser.add_argument("--ids", help="input IDs")
|
|
25
35
|
parser.add_argument("--i", dest="ifile", help="input file, IDs")
|
|
26
36
|
parser.add_argument("--o", dest="ofile", help="output (TSV)")
|
|
27
|
-
parser.add_argument("--query", help="search query (
|
|
37
|
+
parser.add_argument("--query", help="search query (Elastic search)")
|
|
28
38
|
parser.add_argument("--skip", type=int, default=0)
|
|
29
39
|
parser.add_argument("--nmax", type=int, default=None)
|
|
30
40
|
parser.add_argument("--api_host", default=chebi.API_HOST)
|
|
@@ -54,17 +64,31 @@ if __name__=='__main__':
|
|
|
54
64
|
parser.error(f"--i or --ids required for operation {args.op}.")
|
|
55
65
|
|
|
56
66
|
if args.op == "get_entity":
|
|
57
|
-
chebi.GetEntity(ids, base_url, fout)
|
|
67
|
+
chebi.GetEntity(ids, False, False, base_url, fout)
|
|
68
|
+
|
|
69
|
+
elif args.op == "get_entity_parents":
|
|
70
|
+
chebi.GetEntity(ids, True, False, base_url, fout)
|
|
58
71
|
|
|
59
72
|
elif args.op == "get_entity_children":
|
|
60
|
-
chebi.
|
|
73
|
+
chebi.GetEntity(ids, False, True, base_url, fout)
|
|
61
74
|
|
|
62
|
-
elif args.op == "
|
|
63
|
-
chebi.
|
|
75
|
+
elif args.op == "get_entity_database_accessions":
|
|
76
|
+
chebi.GetEntityDatabaseAccessions(ids, base_url, fout)
|
|
77
|
+
|
|
78
|
+
elif args.op == "get_entity_names":
|
|
79
|
+
chebi.GetEntityNames(ids, base_url, fout)
|
|
80
|
+
|
|
81
|
+
elif args.op == "get_compound_data":
|
|
82
|
+
chebi.GetCompoundData(ids, base_url, fout)
|
|
83
|
+
|
|
84
|
+
elif args.op == "list_sources":
|
|
85
|
+
chebi.ListSources(base_url, fout)
|
|
64
86
|
|
|
65
87
|
elif args.op == "search":
|
|
66
|
-
|
|
67
|
-
|
|
88
|
+
if not args.query:
|
|
89
|
+
parser.error(f'--query QUERY required for operation: {args.op}')
|
|
90
|
+
#parser.error(f'Not yet implemented: {args.op}')
|
|
91
|
+
chebi.Search(args.query, base_url, fout)
|
|
68
92
|
|
|
69
93
|
else:
|
|
70
94
|
parser.error(f'Invalid operation: {args.op}')
|
BioClients-0.2.30/BioClients/chebi/Utils.py → bioclients-0.2.34/bioclients/chebi/Client_SOAP.py
RENAMED
|
@@ -1,11 +1,18 @@
|
|
|
1
1
|
#!/usr/bin/env python3
|
|
2
2
|
"""
|
|
3
|
-
Utility
|
|
4
|
-
|
|
3
|
+
Utility for ChEBI SOAP API -- DEPRECATED.
|
|
4
|
+
|
|
5
|
+
* https://www.ebi.ac.uk/chebi/webServices.do
|
|
5
6
|
"""
|
|
6
7
|
###
|
|
7
|
-
import sys,os,re,json,time,
|
|
8
|
+
import sys,os,re,json,argparse,time,logging
|
|
8
9
|
import pandas as pd
|
|
10
|
+
#
|
|
11
|
+
#from .. import chebi
|
|
12
|
+
##############################################################################
|
|
13
|
+
# Utility functions for ChEBI SOAP API.
|
|
14
|
+
###
|
|
15
|
+
import time,urllib.parse
|
|
9
16
|
import requests
|
|
10
17
|
import collections
|
|
11
18
|
import xmltodict
|
|
@@ -89,3 +96,61 @@ def GetEntityParents(ids, base_url=BASE_URL, fout=None):
|
|
|
89
96
|
return df
|
|
90
97
|
|
|
91
98
|
#############################################################################
|
|
99
|
+
##############################################################################
|
|
100
|
+
if __name__=='__main__':
|
|
101
|
+
epilog="Example entity IDs: 30273,33246,24433"
|
|
102
|
+
parser = argparse.ArgumentParser(description='ChEBI SOAP API client -- DEPRECATED', epilog=epilog)
|
|
103
|
+
ops = [
|
|
104
|
+
"get_entity",
|
|
105
|
+
"get_entity_children",
|
|
106
|
+
"get_entity_parents",
|
|
107
|
+
"search"
|
|
108
|
+
]
|
|
109
|
+
parser.add_argument("op", choices=ops, help='OPERATION (select one)')
|
|
110
|
+
parser.add_argument("--ids", help="input IDs")
|
|
111
|
+
parser.add_argument("--i", dest="ifile", help="input file, IDs")
|
|
112
|
+
parser.add_argument("--o", dest="ofile", help="output (TSV)")
|
|
113
|
+
parser.add_argument("--query", help="search query (SMILES)")
|
|
114
|
+
parser.add_argument("--skip", type=int, default=0)
|
|
115
|
+
parser.add_argument("--nmax", type=int, default=None)
|
|
116
|
+
parser.add_argument("--api_host", default=API_HOST)
|
|
117
|
+
parser.add_argument("--api_base_path", default=API_BASE_PATH)
|
|
118
|
+
parser.add_argument("-v","--verbose", action="count", default=0)
|
|
119
|
+
args = parser.parse_args()
|
|
120
|
+
|
|
121
|
+
logging.basicConfig(format='%(levelname)s:%(message)s', level=(logging.DEBUG if args.verbose>1 else logging.INFO))
|
|
122
|
+
|
|
123
|
+
base_url='https://'+args.api_host+args.api_base_path
|
|
124
|
+
|
|
125
|
+
fout = open(args.ofile, 'w') if args.ofile else sys.stdout
|
|
126
|
+
|
|
127
|
+
ids=[];
|
|
128
|
+
if args.ifile:
|
|
129
|
+
fin = open(args.ifile)
|
|
130
|
+
while True:
|
|
131
|
+
line = fin.readline()
|
|
132
|
+
if not line: break
|
|
133
|
+
ids.append(line.rstrip())
|
|
134
|
+
fin.close()
|
|
135
|
+
elif args.ids:
|
|
136
|
+
ids = re.split('[, ]+', args.ids.strip())
|
|
137
|
+
if len(ids)>0: logging.info('Input IDs: %d'%(len(ids)))
|
|
138
|
+
|
|
139
|
+
if args.op[:3]=="get" and not (args.ifile or args.ids):
|
|
140
|
+
parser.error(f"--i or --ids required for operation {args.op}.")
|
|
141
|
+
|
|
142
|
+
if args.op == "get_entity":
|
|
143
|
+
GetEntity(ids, base_url, fout)
|
|
144
|
+
|
|
145
|
+
elif args.op == "get_entity_children":
|
|
146
|
+
GetEntityChildren(ids, base_url, fout)
|
|
147
|
+
|
|
148
|
+
elif args.op == "get_entity_parents":
|
|
149
|
+
GetEntityParents(ids, base_url, fout)
|
|
150
|
+
|
|
151
|
+
elif args.op == "search":
|
|
152
|
+
parser.error(f'Not yet implemented: {args.op}')
|
|
153
|
+
#Search(args.query, base_url, fout)
|
|
154
|
+
|
|
155
|
+
else:
|
|
156
|
+
parser.error(f'Invalid operation: {args.op}')
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""
|
|
3
|
+
Utility functions for ChEBI REST API.
|
|
4
|
+
https://www.ebi.ac.uk/chebi/backend/api/docs/
|
|
5
|
+
"""
|
|
6
|
+
###
|
|
7
|
+
import sys,os,re,json,time,urllib.parse,logging,requests,collections
|
|
8
|
+
import pandas as pd
|
|
9
|
+
#
|
|
10
|
+
API_HOST="www.ebi.ac.uk"
|
|
11
|
+
API_BASE_PATH="/chebi/backend/api/public"
|
|
12
|
+
BASE_URL="https://"+API_HOST+API_BASE_PATH
|
|
13
|
+
#
|
|
14
|
+
NCHUNK=100
|
|
15
|
+
#
|
|
16
|
+
##############################################################################
|
|
17
|
+
def ListSources(base_url=BASE_URL, fout=None):
|
|
18
|
+
n_out=0; tags=None; df=None;
|
|
19
|
+
response = requests.get(f"{base_url}/advanced_search/sources_list", headers={"Accept":"application/json"})
|
|
20
|
+
result = response.json()
|
|
21
|
+
logging.debug(json.dumps(result, indent=2))
|
|
22
|
+
for source in result:
|
|
23
|
+
if not tags:
|
|
24
|
+
tags = [tag for tag in source.keys() if type(source[tag]) not in (list, dict, collections.OrderedDict)]
|
|
25
|
+
df_this = pd.DataFrame({tag:[source[tag] if tag in source else ''] for tag in tags})
|
|
26
|
+
if fout is None: df = pd.concat([df, df_this])
|
|
27
|
+
else: df_this.to_csv(fout, sep="\t", index=False, header=bool(n_out==0))
|
|
28
|
+
n_out += df_this.shape[0]
|
|
29
|
+
logging.info(f"n_out: {n_out}")
|
|
30
|
+
return df
|
|
31
|
+
|
|
32
|
+
##############################################################################
|
|
33
|
+
def GetEntity(ids, include_parents=False, include_children=False, base_url=BASE_URL, fout=None):
|
|
34
|
+
n_out=0; tags=None; df=None;
|
|
35
|
+
for id_this in ids:
|
|
36
|
+
url_this = f"{base_url}/compound/{id_this}"
|
|
37
|
+
url_this = f"{url_this}/?{'true' if include_parents else 'false'}&{'true' if include_children else 'false'}"
|
|
38
|
+
response = requests.get(url_this, headers={"Accept":"application/json"})
|
|
39
|
+
result = response.json()
|
|
40
|
+
if result is None: continue
|
|
41
|
+
logging.debug(json.dumps(result, indent=2))
|
|
42
|
+
if not tags:
|
|
43
|
+
tags = [tag for tag in result.keys() if type(result[tag]) not in (list, dict, collections.OrderedDict)]
|
|
44
|
+
df_this = pd.DataFrame({tag:[result[tag] if tag in result else ''] for tag in tags})
|
|
45
|
+
if fout is None: df = pd.concat([df, df_this])
|
|
46
|
+
else: df_this.to_csv(fout, sep="\t", index=False, header=bool(n_out==0))
|
|
47
|
+
n_out += df_this.shape[0]
|
|
48
|
+
logging.info(f"n_out: {n_out}")
|
|
49
|
+
return df
|
|
50
|
+
|
|
51
|
+
##############################################################################
|
|
52
|
+
def GetEntityNames(ids, base_url=BASE_URL, fout=None):
|
|
53
|
+
n_out=0; df=None; tags_entity=None; tags_name = ["name", "status", "type", "source", "ascii_name", "adapted", "language_code"]
|
|
54
|
+
for id_this in ids:
|
|
55
|
+
url_this = f"{base_url}/compound/{id_this}"
|
|
56
|
+
response = requests.get(url_this, headers={"Accept":"application/json"})
|
|
57
|
+
result = response.json()
|
|
58
|
+
if result is None: continue
|
|
59
|
+
logging.debug(json.dumps(result, indent=2))
|
|
60
|
+
if not tags_entity:
|
|
61
|
+
tags_entity = [tag for tag in result.keys() if type(result[tag]) not in (list, dict, collections.OrderedDict)]
|
|
62
|
+
df_this_entity = pd.DataFrame({tag:[result[tag] if tag in result else ''] for tag in tags_entity})
|
|
63
|
+
|
|
64
|
+
names = result["names"] if "names" in result else {}
|
|
65
|
+
synonyms = names["SYNONYM"] if "SYNONYM" in names else []
|
|
66
|
+
iupac_names = names["IUPAC NAME"] if "IUPAC NAME" in names else []
|
|
67
|
+
uniprot_names = names["UNIPROT NAME"] if "UNIPROT NAME" in names else []
|
|
68
|
+
for name in synonyms+iupac_names+uniprot_names:
|
|
69
|
+
|
|
70
|
+
df_this_name = pd.DataFrame({tag:[name[tag] if tag in name else ''] for tag in tags_name})
|
|
71
|
+
df_this = pd.concat([df_this_entity, df_this_name], axis=1)
|
|
72
|
+
|
|
73
|
+
if fout is None: df = pd.concat([df, df_this])
|
|
74
|
+
else: df_this.to_csv(fout, sep="\t", index=False, header=bool(n_out==0))
|
|
75
|
+
n_out += df_this.shape[0]
|
|
76
|
+
|
|
77
|
+
logging.info(f"n_out: {n_out}")
|
|
78
|
+
return df
|
|
79
|
+
|
|
80
|
+
##############################################################################
|
|
81
|
+
def GetEntityDatabaseAccessions(ids, base_url=BASE_URL, fout=None):
|
|
82
|
+
n_out=0; df=None; tags_entity=None; tags_dbacc = ["id", "accession_number", "type", "source_name", "url", "prefix"]
|
|
83
|
+
for id_this in ids:
|
|
84
|
+
url_this = f"{base_url}/compound/{id_this}"
|
|
85
|
+
response = requests.get(url_this, headers={"Accept":"application/json"})
|
|
86
|
+
result = response.json()
|
|
87
|
+
if result is None: continue
|
|
88
|
+
logging.debug(json.dumps(result, indent=2))
|
|
89
|
+
if not tags_entity:
|
|
90
|
+
tags_entity = [tag for tag in result.keys() if type(result[tag]) not in (list, dict, collections.OrderedDict)]
|
|
91
|
+
df_this_entity = pd.DataFrame({tag:[result[tag] if tag in result else ''] for tag in tags_entity})
|
|
92
|
+
|
|
93
|
+
database_accessions = result["database_accessions"] if "database_accessions" in result else {}
|
|
94
|
+
xrefs = database_accessions["MANUAL_X_REF"] if "MANUAL_X_REF" in database_accessions else []
|
|
95
|
+
cas_rns = database_accessions["CAS"] if "CAS" in database_accessions else []
|
|
96
|
+
rns = database_accessions["REGISTRY_NUMBER"] if "REGISTRY_NUMBER" in database_accessions else []
|
|
97
|
+
citations = database_accessions["CITATION"] if "CITATION" in database_accessions else []
|
|
98
|
+
|
|
99
|
+
for acc in xrefs+cas_rns+rns+citations:
|
|
100
|
+
df_this_acc = pd.DataFrame({tag:[acc[tag] if tag in acc else ''] for tag in tags_dbacc})
|
|
101
|
+
if "id" in df_this_acc:
|
|
102
|
+
df_this_acc["accession_id"] = df_this_acc.pop("id")
|
|
103
|
+
df_this_acc = df_this_acc [['accession_id'] + [col for col in df_this_acc.columns if col != 'accession_id']]
|
|
104
|
+
|
|
105
|
+
df_this = pd.concat([df_this_entity, df_this_acc], axis=1)
|
|
106
|
+
|
|
107
|
+
if fout is None: df = pd.concat([df, df_this])
|
|
108
|
+
else: df_this.to_csv(fout, sep="\t", index=False, header=bool(n_out==0))
|
|
109
|
+
n_out += df_this.shape[0]
|
|
110
|
+
|
|
111
|
+
logging.info(f"n_out: {n_out}")
|
|
112
|
+
return df
|
|
113
|
+
|
|
114
|
+
##############################################################################
|
|
115
|
+
def GetCompoundData(ids, base_url=BASE_URL, fout=None):
|
|
116
|
+
n_out=0; df=None; tags_entity=None; tags_chemical = ["formula", "charge", "mass", "monoisotopic_mass"]
|
|
117
|
+
tags_structure = ["id", "smiles", "standard_inchi", "standard_inchi_key", "wurcs", "is_r_group"]
|
|
118
|
+
for id_this in ids:
|
|
119
|
+
url_this = f"{base_url}/compound/{id_this}"
|
|
120
|
+
response = requests.get(url_this, headers={"Accept":"application/json"})
|
|
121
|
+
result = response.json()
|
|
122
|
+
if result is None: continue
|
|
123
|
+
logging.debug(json.dumps(result, indent=2))
|
|
124
|
+
if not tags_entity:
|
|
125
|
+
tags_entity = [tag for tag in result.keys() if type(result[tag]) not in (list, dict, collections.OrderedDict)]
|
|
126
|
+
df_this_entity = pd.DataFrame({tag:[result[tag] if tag in result else ''] for tag in tags_entity})
|
|
127
|
+
|
|
128
|
+
chemical_data = result["chemical_data"] if "chemical_data" in result else {}
|
|
129
|
+
default_structure = result["default_structure"] if "default_structure" in result else {}
|
|
130
|
+
|
|
131
|
+
df_this_chemical = pd.DataFrame({tag:[chemical_data[tag] if tag in chemical_data else ''] for tag in tags_chemical})
|
|
132
|
+
df_this_structure = pd.DataFrame({tag:[default_structure[tag] if tag in default_structure else ''] for tag in tags_structure})
|
|
133
|
+
if "id" in df_this_structure:
|
|
134
|
+
df_this_structure["structure_id"] = df_this_structure.pop("id")
|
|
135
|
+
df_this_structure = df_this_structure [['structure_id'] + [col for col in df_this_structure.columns if col != 'structure_id']]
|
|
136
|
+
df_this = pd.concat([df_this_entity, df_this_chemical, df_this_structure], axis=1)
|
|
137
|
+
|
|
138
|
+
if fout is None: df = pd.concat([df, df_this])
|
|
139
|
+
else: df_this.to_csv(fout, sep="\t", index=False, header=bool(n_out==0))
|
|
140
|
+
n_out += df_this.shape[0]
|
|
141
|
+
|
|
142
|
+
logging.info(f"n_out: {n_out}")
|
|
143
|
+
return df
|
|
144
|
+
|
|
145
|
+
##############################################################################
|
|
146
|
+
def Search(query, base_url=BASE_URL, fout=None):
|
|
147
|
+
n_out=0; df=None;
|
|
148
|
+
tags_source=[ "chebi_accession", "name", "ascii_name", "stars", "default_structure", "definition", "monoisotopicmass", "charge", "formula", "smiles", "mass", "structures", ];
|
|
149
|
+
url = f"{base_url}/es_search/?term={query}&size={NCHUNK}"
|
|
150
|
+
i_page=1;
|
|
151
|
+
while True:
|
|
152
|
+
url_this = f"{url}&page={i_page}"
|
|
153
|
+
response = requests.get(url_this, headers={"Accept":"application/json"})
|
|
154
|
+
rval = response.json()
|
|
155
|
+
logging.debug(json.dumps(rval, indent=2))
|
|
156
|
+
results = rval["results"]
|
|
157
|
+
n_total = rval["total"] if "total" in rval else 0
|
|
158
|
+
n_pages = rval["number_pages"] if "number_pages" in rval else 0
|
|
159
|
+
for result in results:
|
|
160
|
+
source_data = result["_source"] if "_source" in result else {}
|
|
161
|
+
df_this = pd.DataFrame({tag:[source_data[tag] if tag in source_data else ''] for tag in tags_source})
|
|
162
|
+
if fout is None: df = pd.concat([df, df_this])
|
|
163
|
+
else: df_this.to_csv(fout, sep="\t", index=False, header=bool(n_out==0))
|
|
164
|
+
n_out += df_this.shape[0]
|
|
165
|
+
if n_out >= n_total: break
|
|
166
|
+
i_page+=1
|
|
167
|
+
logging.info(f"n_out: {n_out}")
|
|
168
|
+
return df
|
|
169
|
+
|
|
170
|
+
##############################################################################
|
|
@@ -635,19 +635,29 @@ def GetMolecule(ids, base_url=BASE_URL, fout=None):
|
|
|
635
635
|
mol = response.json()
|
|
636
636
|
if not tq: tq = tqdm.tqdm(total=len(ids), unit="mols")
|
|
637
637
|
tq.update()
|
|
638
|
+
logging.debug(json.dumps(mol, sort_keys=True, indent=2))
|
|
638
639
|
if not mol_tags:
|
|
639
640
|
mol_tags = [tag for tag in sorted(list(mol.keys())) if type(mol[tag]) not in (dict, list)]
|
|
640
641
|
if not struct_tags:
|
|
641
|
-
|
|
642
|
-
|
|
642
|
+
molecule_structures = mol["molecule_structures"]
|
|
643
|
+
if type(molecule_structures) is dict:
|
|
644
|
+
struct_tags = sorted(molecule_structures.keys())
|
|
645
|
+
struct_tags.remove("molfile")
|
|
646
|
+
else:
|
|
647
|
+
molecule_structures = {}
|
|
648
|
+
struct_tags = {}
|
|
643
649
|
if not prop_tags:
|
|
644
|
-
|
|
645
|
-
|
|
650
|
+
molecule_properties = mol["molecule_properties"]
|
|
651
|
+
if type(molecule_properties) is dict:
|
|
652
|
+
prop_tags = sorted(molecule_properties.keys())
|
|
653
|
+
else:
|
|
654
|
+
molecule_properties = {}
|
|
655
|
+
prop_tags = {}
|
|
646
656
|
parent_chembl_id = mol["molecule_hierarchy"]["parent_chembl_id"] if "molecule_hierarchy" in mol and "parent_chembl_id" in mol["molecule_hierarchy"] else ""
|
|
647
657
|
df_this = pd.concat([
|
|
648
658
|
pd.DataFrame({tag:[(mol[tag] if tag in mol else None)] for tag in mol_tags}),
|
|
649
|
-
pd.DataFrame({tag:[(
|
|
650
|
-
pd.DataFrame({tag:[(
|
|
659
|
+
pd.DataFrame({tag:[(molecule_structures[tag] if tag in molecule_structures else None)] for tag in struct_tags}),
|
|
660
|
+
pd.DataFrame({tag:[(molecule_properties[tag] if tag in molecule_properties else None)] for tag in prop_tags}),
|
|
651
661
|
pd.DataFrame({"parent_chembl_id":[parent_chembl_id]})], axis=1)
|
|
652
662
|
if fout is None: df = pd.concat([df, df_this])
|
|
653
663
|
else: df_this.to_csv(fout, sep="\t", index=False, header=bool(n_out==0))
|
|
@@ -44,6 +44,7 @@ if __name__=='__main__':
|
|
|
44
44
|
"list_atcs",
|
|
45
45
|
"list_xrefs",
|
|
46
46
|
"list_xref_types",
|
|
47
|
+
"list_targets",
|
|
47
48
|
"search_indications",
|
|
48
49
|
"search_products",
|
|
49
50
|
"meta_listdbs"
|
|
@@ -152,6 +153,9 @@ if __name__=='__main__':
|
|
|
152
153
|
elif args.op=='list_xrefs':
|
|
153
154
|
drugcentral.ListXrefs(dbcon, fout)
|
|
154
155
|
|
|
156
|
+
elif args.op=='list_targets':
|
|
157
|
+
drugcentral.ListTargets(dbcon, fout)
|
|
158
|
+
|
|
155
159
|
elif args.op=='get_structure':
|
|
156
160
|
drugcentral.GetStructure(dbcon, ids, fout)
|
|
157
161
|
|
|
@@ -716,6 +716,45 @@ ORDER BY
|
|
|
716
716
|
logging.info(f"rows: {n_out}")
|
|
717
717
|
return df
|
|
718
718
|
|
|
719
|
+
#############################################################################
|
|
720
|
+
def ListTargets(dbcon, fout=None):
|
|
721
|
+
df=None; n_out=0; tq=None;
|
|
722
|
+
quiet = bool(logging.getLogger().getEffectiveLevel()>15)
|
|
723
|
+
N_row = pd.read_sql("SELECT COUNT(*) FROM target_component", dbcon).iloc[0,0]
|
|
724
|
+
sql="""\
|
|
725
|
+
SELECT
|
|
726
|
+
tdict.id AS target_id,
|
|
727
|
+
tdict.name AS target_name,
|
|
728
|
+
tdict.target_class,
|
|
729
|
+
tdict.protein_type,
|
|
730
|
+
tdict.protein_components,
|
|
731
|
+
tcomp.id AS component_id,
|
|
732
|
+
tcomp.accession AS target_uniprot,
|
|
733
|
+
tcomp.swissprot,
|
|
734
|
+
tcomp.organism AS target_organism,
|
|
735
|
+
tcomp.name AS component_name,
|
|
736
|
+
tcomp.gene AS gene_symbol,
|
|
737
|
+
tcomp.geneid,
|
|
738
|
+
tcomp.tdl
|
|
739
|
+
FROM
|
|
740
|
+
target_component tcomp
|
|
741
|
+
JOIN td2tc ON td2tc.component_id = tcomp.id
|
|
742
|
+
JOIN target_dictionary tdict ON tdict.id = td2tc.target_id
|
|
743
|
+
ORDER BY
|
|
744
|
+
target_id, component_id
|
|
745
|
+
;
|
|
746
|
+
"""
|
|
747
|
+
df_itr = pd.read_sql(sql, dbcon, chunksize=NCHUNK)
|
|
748
|
+
for df_this in df_itr:
|
|
749
|
+
if not quiet and tq is None: tq = tqdm.tqdm(total=N_row)
|
|
750
|
+
if fout is not None: df_this.to_csv(fout, sep="\t", header=bool(n_out==0), index=False)
|
|
751
|
+
else: df = pd.concat([df, df_this])
|
|
752
|
+
if tq is not None: tq.update(df_this.shape[0])
|
|
753
|
+
n_out += df_this.shape[0]
|
|
754
|
+
if tq is not None: tq.close()
|
|
755
|
+
logging.info(f"rows: {n_out}")
|
|
756
|
+
return df
|
|
757
|
+
|
|
719
758
|
#############################################################################
|
|
720
759
|
def GetStructureSynonyms(dbcon, ids, fout=None):
|
|
721
760
|
df=None;
|