bioclients 0.2.33__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.33/LICENSE +121 -0
- bioclients-0.2.33/PKG-INFO +122 -0
- bioclients-0.2.33/README.md +108 -0
- bioclients-0.2.33/bioclients/__init__.py +1 -0
- bioclients-0.2.33/bioclients/allen/__init__.py +3 -0
- bioclients-0.2.33/bioclients/allen/brain/Client.py +72 -0
- bioclients-0.2.33/bioclients/allen/brain/Utils.py +65 -0
- bioclients-0.2.33/bioclients/allen/brain/__init__.py +1 -0
- bioclients-0.2.33/bioclients/amp/__init__.py +5 -0
- bioclients-0.2.33/bioclients/amp/t2d/Client.py +69 -0
- bioclients-0.2.33/bioclients/amp/t2d/Utils.py +61 -0
- bioclients-0.2.33/bioclients/amp/t2d/__init__.py +1 -0
- bioclients-0.2.33/bioclients/badapple/Client.py +73 -0
- bioclients-0.2.33/bioclients/badapple/Utils.py +114 -0
- bioclients-0.2.33/bioclients/badapple/__init__.py +1 -0
- bioclients-0.2.33/bioclients/bindingdb/Client.py +60 -0
- bioclients-0.2.33/bioclients/bindingdb/Utils.py +33 -0
- bioclients-0.2.33/bioclients/bindingdb/__init__.py +1 -0
- bioclients-0.2.33/bioclients/biogrid/Client.py +102 -0
- bioclients-0.2.33/bioclients/biogrid/Utils.py +101 -0
- bioclients-0.2.33/bioclients/biogrid/__init__.py +1 -0
- bioclients-0.2.33/bioclients/biomarkerkb/Client.py +59 -0
- bioclients-0.2.33/bioclients/biomarkerkb/Utils.py +34 -0
- bioclients-0.2.33/bioclients/biomarkerkb/__init__.py +1 -0
- bioclients-0.2.33/bioclients/bioregistry/Client.py +71 -0
- bioclients-0.2.33/bioclients/bioregistry/Utils.py +51 -0
- bioclients-0.2.33/bioclients/bioregistry/__init__.py +1 -0
- bioclients-0.2.33/bioclients/brenda/Client.py +213 -0
- bioclients-0.2.33/bioclients/brenda/Utils.py +424 -0
- bioclients-0.2.33/bioclients/brenda/__init__.py +1 -0
- bioclients-0.2.33/bioclients/cas/Client.py +52 -0
- bioclients-0.2.33/bioclients/cas/Utils.py +54 -0
- bioclients-0.2.33/bioclients/cas/__init__.py +4 -0
- bioclients-0.2.33/bioclients/cdc/Client.py +45 -0
- bioclients-0.2.33/bioclients/cdc/Utils.py +40 -0
- bioclients-0.2.33/bioclients/cdc/__init__.py +1 -0
- bioclients-0.2.33/bioclients/cfde/__init__.py +0 -0
- bioclients-0.2.33/bioclients/cfde/cfchemdb/Client.py +105 -0
- bioclients-0.2.33/bioclients/cfde/cfchemdb/Utils.py +131 -0
- bioclients-0.2.33/bioclients/cfde/cfchemdb/__init__.py +1 -0
- bioclients-0.2.33/bioclients/chebi/Client.py +94 -0
- bioclients-0.2.33/bioclients/chebi/Client_SOAP.py +156 -0
- bioclients-0.2.33/bioclients/chebi/Utils.py +170 -0
- bioclients-0.2.33/bioclients/chebi/__init__.py +1 -0
- bioclients-0.2.33/bioclients/chem2bio2rdf/Client.py +95 -0
- bioclients-0.2.33/bioclients/chem2bio2rdf/Utils.py +299 -0
- bioclients-0.2.33/bioclients/chem2bio2rdf/__init__.py +5 -0
- bioclients-0.2.33/bioclients/chem2bio2rdf/slap/Client.py +91 -0
- bioclients-0.2.33/bioclients/chem2bio2rdf/slap/Utils.py +808 -0
- bioclients-0.2.33/bioclients/chem2bio2rdf/slap/__init__.py +2 -0
- bioclients-0.2.33/bioclients/chembl/Client.py +198 -0
- bioclients-0.2.33/bioclients/chembl/FetchByID.py +163 -0
- bioclients-0.2.33/bioclients/chembl/UnichemClient.py +190 -0
- bioclients-0.2.33/bioclients/chembl/Utils.py +817 -0
- bioclients-0.2.33/bioclients/chembl/__init__.py +1 -0
- bioclients-0.2.33/bioclients/chemidplus/Client.py +73 -0
- bioclients-0.2.33/bioclients/chemidplus/Utils.py +83 -0
- bioclients-0.2.33/bioclients/chemidplus/__init__.py +4 -0
- bioclients-0.2.33/bioclients/clinicaltrials/Client.py +77 -0
- bioclients-0.2.33/bioclients/clinicaltrials/Utils.py +169 -0
- bioclients-0.2.33/bioclients/clinicaltrials/__init__.py +1 -0
- bioclients-0.2.33/bioclients/disgenet/Client.py +81 -0
- bioclients-0.2.33/bioclients/disgenet/Utils.py +204 -0
- bioclients-0.2.33/bioclients/disgenet/__init__.py +1 -0
- bioclients-0.2.33/bioclients/dnorm/Client.py +115 -0
- bioclients-0.2.33/bioclients/dnorm/__init__.py +0 -0
- bioclients-0.2.33/bioclients/drugcentral/Client.py +212 -0
- bioclients-0.2.33/bioclients/drugcentral/Test.py +60 -0
- bioclients-0.2.33/bioclients/drugcentral/Utils.py +848 -0
- bioclients-0.2.33/bioclients/drugcentral/__init__.py +1 -0
- bioclients-0.2.33/bioclients/emblebi/__init__.py +1 -0
- bioclients-0.2.33/bioclients/emblebi/identifiers/Client.py +80 -0
- bioclients-0.2.33/bioclients/emblebi/identifiers/Utils.py +112 -0
- bioclients-0.2.33/bioclients/emblebi/identifiers/__init__.py +1 -0
- bioclients-0.2.33/bioclients/emblebi/unichem/Client.py +66 -0
- bioclients-0.2.33/bioclients/emblebi/unichem/Utils.py +131 -0
- bioclients-0.2.33/bioclients/emblebi/unichem/__init__.py +1 -0
- bioclients-0.2.33/bioclients/ensembl/Client.py +74 -0
- bioclients-0.2.33/bioclients/ensembl/Utils.py +146 -0
- bioclients-0.2.33/bioclients/ensembl/__init__.py +3 -0
- bioclients-0.2.33/bioclients/ensembl/biomart/Client.py +70 -0
- bioclients-0.2.33/bioclients/ensembl/biomart/Utils.py +83 -0
- bioclients-0.2.33/bioclients/ensembl/biomart/__init__.py +1 -0
- bioclients-0.2.33/bioclients/entrez/Client.py +54 -0
- bioclients-0.2.33/bioclients/entrez/Utils.py +25 -0
- bioclients-0.2.33/bioclients/entrez/__init__.py +3 -0
- bioclients-0.2.33/bioclients/fda/__init__.py +1 -0
- bioclients-0.2.33/bioclients/fda/aer/Client.py +69 -0
- bioclients-0.2.33/bioclients/fda/aer/Utils.py +267 -0
- bioclients-0.2.33/bioclients/fda/aer/__init__.py +1 -0
- bioclients-0.2.33/bioclients/geneontology/Client.py +55 -0
- bioclients-0.2.33/bioclients/geneontology/Utils.py +42 -0
- bioclients-0.2.33/bioclients/geneontology/__init__.py +1 -0
- bioclients-0.2.33/bioclients/glygen/Client.py +66 -0
- bioclients-0.2.33/bioclients/glygen/Utils.py +79 -0
- bioclients-0.2.33/bioclients/glygen/__init__.py +1 -0
- bioclients-0.2.33/bioclients/gtex/Client.py +70 -0
- bioclients-0.2.33/bioclients/gtex/Utils.py +97 -0
- bioclients-0.2.33/bioclients/gtex/__init__.py +1 -0
- bioclients-0.2.33/bioclients/gwascatalog/Client.py +105 -0
- bioclients-0.2.33/bioclients/gwascatalog/Utils.py +447 -0
- bioclients-0.2.33/bioclients/gwascatalog/__init__.py +1 -0
- bioclients-0.2.33/bioclients/hubmap/Client.py +62 -0
- bioclients-0.2.33/bioclients/hubmap/Utils.py +44 -0
- bioclients-0.2.33/bioclients/hubmap/__init__.py +1 -0
- bioclients-0.2.33/bioclients/hugo/Client.py +80 -0
- bioclients-0.2.33/bioclients/hugo/Utils.py +133 -0
- bioclients-0.2.33/bioclients/hugo/__init__.py +1 -0
- bioclients-0.2.33/bioclients/humanbase/Client.py +198 -0
- bioclients-0.2.33/bioclients/humanbase/__init__.py +0 -0
- bioclients-0.2.33/bioclients/icite/Client.py +52 -0
- bioclients-0.2.33/bioclients/icite/Utils.py +62 -0
- bioclients-0.2.33/bioclients/icite/__init__.py +1 -0
- bioclients-0.2.33/bioclients/idg/Client.py +74 -0
- bioclients-0.2.33/bioclients/idg/Utils.py +84 -0
- bioclients-0.2.33/bioclients/idg/__init__.py +5 -0
- bioclients-0.2.33/bioclients/idg/pharos/Client.py +114 -0
- bioclients-0.2.33/bioclients/idg/pharos/Utils.py +121 -0
- bioclients-0.2.33/bioclients/idg/pharos/__init__.py +1 -0
- bioclients-0.2.33/bioclients/idg/rss/Client.py +56 -0
- bioclients-0.2.33/bioclients/idg/rss/Utils.py +46 -0
- bioclients-0.2.33/bioclients/idg/rss/__init__.py +1 -0
- bioclients-0.2.33/bioclients/idg/tcrd/Client.py +175 -0
- bioclients-0.2.33/bioclients/idg/tcrd/Utils.py +560 -0
- bioclients-0.2.33/bioclients/idg/tcrd/__init__.py +1 -0
- bioclients-0.2.33/bioclients/idg/tiga/Client.py +118 -0
- bioclients-0.2.33/bioclients/idg/tiga/Utils.py +160 -0
- bioclients-0.2.33/bioclients/idg/tiga/__init__.py +1 -0
- bioclients-0.2.33/bioclients/idg/tinx/Client.py +110 -0
- bioclients-0.2.33/bioclients/idg/tinx/Utils.py +340 -0
- bioclients-0.2.33/bioclients/idg/tinx/__init__.py +1 -0
- bioclients-0.2.33/bioclients/iuphar/Client.py +135 -0
- bioclients-0.2.33/bioclients/iuphar/Utils.py +415 -0
- bioclients-0.2.33/bioclients/iuphar/__init__.py +1 -0
- bioclients-0.2.33/bioclients/jensenlab/Client.py +54 -0
- bioclients-0.2.33/bioclients/jensenlab/Utils.py +53 -0
- bioclients-0.2.33/bioclients/jensenlab/__init__.py +1 -0
- bioclients-0.2.33/bioclients/lincs/Client.py +86 -0
- bioclients-0.2.33/bioclients/lincs/Client_lincscloud.py +171 -0
- bioclients-0.2.33/bioclients/lincs/Utils.py +170 -0
- bioclients-0.2.33/bioclients/lincs/__init__.py +1 -0
- bioclients-0.2.33/bioclients/lincs/sigcom/Client.py +47 -0
- bioclients-0.2.33/bioclients/lincs/sigcom/Utils.py +30 -0
- bioclients-0.2.33/bioclients/lincs/sigcom/__init__.py +1 -0
- bioclients-0.2.33/bioclients/maayanlab/__init__.py +0 -0
- bioclients-0.2.33/bioclients/maayanlab/archs4/Client.py +41 -0
- bioclients-0.2.33/bioclients/maayanlab/archs4/Utils.py +38 -0
- bioclients-0.2.33/bioclients/maayanlab/archs4/__init__.py +1 -0
- bioclients-0.2.33/bioclients/maayanlab/harmonizome/Client.py +53 -0
- bioclients-0.2.33/bioclients/maayanlab/harmonizome/Utils.py +54 -0
- bioclients-0.2.33/bioclients/maayanlab/harmonizome/__init__.py +1 -0
- bioclients-0.2.33/bioclients/medline/__init__.py +0 -0
- bioclients-0.2.33/bioclients/medline/connect/Client.py +71 -0
- bioclients-0.2.33/bioclients/medline/connect/Utils.py +53 -0
- bioclients-0.2.33/bioclients/medline/connect/__init__.py +1 -0
- bioclients-0.2.33/bioclients/medline/genetics/Client.py +78 -0
- bioclients-0.2.33/bioclients/medline/genetics/Utils.py +127 -0
- bioclients-0.2.33/bioclients/medline/genetics/__init__.py +1 -0
- bioclients-0.2.33/bioclients/mesh/Client.py +77 -0
- bioclients-0.2.33/bioclients/mesh/Utils.py +86 -0
- bioclients-0.2.33/bioclients/mesh/__init__.py +1 -0
- bioclients-0.2.33/bioclients/monarch/Biolink.py +100 -0
- bioclients-0.2.33/bioclients/monarch/Client.py +125 -0
- bioclients-0.2.33/bioclients/monarch/Utils.py +173 -0
- bioclients-0.2.33/bioclients/monarch/__init__.py +1 -0
- bioclients-0.2.33/bioclients/mygene/Client.py +53 -0
- bioclients-0.2.33/bioclients/mygene/Utils.py +42 -0
- bioclients-0.2.33/bioclients/mygene/__init__.py +1 -0
- bioclients-0.2.33/bioclients/ncats/__init__.py +2 -0
- bioclients-0.2.33/bioclients/ncats/gsrs/Client.py +80 -0
- bioclients-0.2.33/bioclients/ncats/gsrs/Utils.py +158 -0
- bioclients-0.2.33/bioclients/ncats/gsrs/__init__.py +1 -0
- bioclients-0.2.33/bioclients/ncats/stitcher/Client.py +72 -0
- bioclients-0.2.33/bioclients/ncats/stitcher/Utils.py +94 -0
- bioclients-0.2.33/bioclients/ncats/stitcher/__init__.py +1 -0
- bioclients-0.2.33/bioclients/ncbo/Client.py +61 -0
- bioclients-0.2.33/bioclients/ncbo/Utils.py +49 -0
- bioclients-0.2.33/bioclients/ncbo/__init__.py +1 -0
- bioclients-0.2.33/bioclients/omim/Client.py +113 -0
- bioclients-0.2.33/bioclients/omim/__init__.py +0 -0
- bioclients-0.2.33/bioclients/oncotree/Client.py +73 -0
- bioclients-0.2.33/bioclients/oncotree/Utils.py +68 -0
- bioclients-0.2.33/bioclients/oncotree/__init__.py +1 -0
- bioclients-0.2.33/bioclients/openphacts/Client.py +84 -0
- bioclients-0.2.33/bioclients/openphacts/Utils.py +279 -0
- bioclients-0.2.33/bioclients/openphacts/__init__.py +1 -0
- bioclients-0.2.33/bioclients/opentargets/Client.py +70 -0
- bioclients-0.2.33/bioclients/opentargets/Utils.py +76 -0
- bioclients-0.2.33/bioclients/opentargets/__init__.py +1 -0
- bioclients-0.2.33/bioclients/panther/Client.py +86 -0
- bioclients-0.2.33/bioclients/panther/__init__.py +0 -0
- bioclients-0.2.33/bioclients/pdb/Client.py +64 -0
- bioclients-0.2.33/bioclients/pdb/Utils.py +94 -0
- bioclients-0.2.33/bioclients/pdb/__init__.py +1 -0
- bioclients-0.2.33/bioclients/pubchem/Client.py +156 -0
- bioclients-0.2.33/bioclients/pubchem/Utils.py +885 -0
- bioclients-0.2.33/bioclients/pubchem/__init__.py +5 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/Client.py +48 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/Utils.py +196 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/__init__.py +1 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/pubchem_ftp_actives.py +439 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/pubchem_ftp_assay_fetch.py +180 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/pubchem_ftp_assay_results.py +152 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/pubchem_ftp_assay_search.py +245 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/pubchem_ftp_assaysim.py +200 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/pubchem_ftp_compound_assaystats.py +290 -0
- bioclients-0.2.33/bioclients/pubchem/ftp/pubchem_ftp_gini_index.py +286 -0
- bioclients-0.2.33/bioclients/pubchem/rdf/Client.py +280 -0
- bioclients-0.2.33/bioclients/pubchem/rdf/__init__.py +0 -0
- bioclients-0.2.33/bioclients/pubchem/soap/Client.py +118 -0
- bioclients-0.2.33/bioclients/pubchem/soap/Utils.py +362 -0
- bioclients-0.2.33/bioclients/pubchem/soap/__init__.py +1 -0
- bioclients-0.2.33/bioclients/pubchem/soap/pug_aids2assays.py +206 -0
- bioclients-0.2.33/bioclients/pubchem/soap/pug_ids2mols.py +199 -0
- bioclients-0.2.33/bioclients/pubchem/soap/pug_substance_search.py +282 -0
- bioclients-0.2.33/bioclients/pubmed/App_XML.py +92 -0
- bioclients-0.2.33/bioclients/pubmed/Client.py +59 -0
- bioclients-0.2.33/bioclients/pubmed/Utils.py +127 -0
- bioclients-0.2.33/bioclients/pubmed/Utils_XML.py +144 -0
- bioclients-0.2.33/bioclients/pubmed/__init__.py +3 -0
- bioclients-0.2.33/bioclients/pubtator/Client.py +68 -0
- bioclients-0.2.33/bioclients/pubtator/Utils.py +41 -0
- bioclients-0.2.33/bioclients/pubtator/__init__.py +1 -0
- bioclients-0.2.33/bioclients/reactome/Client.py +103 -0
- bioclients-0.2.33/bioclients/reactome/SMBL_utils.py +42 -0
- bioclients-0.2.33/bioclients/reactome/Utils.py +145 -0
- bioclients-0.2.33/bioclients/reactome/__init__.py +2 -0
- bioclients-0.2.33/bioclients/rxnorm/Client.py +175 -0
- bioclients-0.2.33/bioclients/rxnorm/Utils.py +254 -0
- bioclients-0.2.33/bioclients/rxnorm/__init__.py +1 -0
- bioclients-0.2.33/bioclients/stringdb/Client.py +99 -0
- bioclients-0.2.33/bioclients/stringdb/Utils.py +128 -0
- bioclients-0.2.33/bioclients/stringdb/__init__.py +1 -0
- bioclients-0.2.33/bioclients/tcga/Client.py +63 -0
- bioclients-0.2.33/bioclients/tcga/Utils.py +105 -0
- bioclients-0.2.33/bioclients/tcga/__init__.py +1 -0
- bioclients-0.2.33/bioclients/tinx/Client.py +85 -0
- bioclients-0.2.33/bioclients/tinx/Utils.py +180 -0
- bioclients-0.2.33/bioclients/tinx/__init__.py +1 -0
- bioclients-0.2.33/bioclients/ubkg/Client.py +123 -0
- bioclients-0.2.33/bioclients/ubkg/Utils.py +254 -0
- bioclients-0.2.33/bioclients/ubkg/__init__.py +1 -0
- bioclients-0.2.33/bioclients/umls/CPTClient.py +144 -0
- bioclients-0.2.33/bioclients/umls/Client.py +156 -0
- bioclients-0.2.33/bioclients/umls/Utils.py +458 -0
- bioclients-0.2.33/bioclients/umls/__init__.py +1 -0
- bioclients-0.2.33/bioclients/uniprot/Client.py +70 -0
- bioclients-0.2.33/bioclients/uniprot/Utils.py +191 -0
- bioclients-0.2.33/bioclients/uniprot/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/__init__.py +3 -0
- bioclients-0.2.33/bioclients/util/db/Utils.py +44 -0
- bioclients-0.2.33/bioclients/util/db/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/graphql/Utils.py +30 -0
- bioclients-0.2.33/bioclients/util/graphql/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/hdf/Utils.py +55 -0
- bioclients-0.2.33/bioclients/util/hdf/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/igraph/App.py +203 -0
- bioclients-0.2.33/bioclients/util/igraph/Utils.py +471 -0
- bioclients-0.2.33/bioclients/util/igraph/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/neo4j/App.py +55 -0
- bioclients-0.2.33/bioclients/util/neo4j/Utils.py +58 -0
- bioclients-0.2.33/bioclients/util/neo4j/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/obo/App.py +23 -0
- bioclients-0.2.33/bioclients/util/obo/Utils.py +62 -0
- bioclients-0.2.33/bioclients/util/obo/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/owl/App.py +110 -0
- bioclients-0.2.33/bioclients/util/owl/Utils.py +163 -0
- bioclients-0.2.33/bioclients/util/owl/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/pandas/App.py +198 -0
- bioclients-0.2.33/bioclients/util/pandas/Csv2Html.py +105 -0
- bioclients-0.2.33/bioclients/util/pandas/Csv2Markdown.py +62 -0
- bioclients-0.2.33/bioclients/util/pandas/Csv2Sql.py +330 -0
- bioclients-0.2.33/bioclients/util/pandas/Utils.py +102 -0
- bioclients-0.2.33/bioclients/util/pandas/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/rdf/App.py +39 -0
- bioclients-0.2.33/bioclients/util/rdf/Utils.py +42 -0
- bioclients-0.2.33/bioclients/util/rdf/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/rest/Utils.py +122 -0
- bioclients-0.2.33/bioclients/util/rest/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/sparql/Client.py +82 -0
- bioclients-0.2.33/bioclients/util/sparql/Utils.py +161 -0
- bioclients-0.2.33/bioclients/util/sparql/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/xml/Utils.py +132 -0
- bioclients-0.2.33/bioclients/util/xml/__init__.py +1 -0
- bioclients-0.2.33/bioclients/util/yaml/Utils.py +14 -0
- bioclients-0.2.33/bioclients/util/yaml/__init__.py +1 -0
- bioclients-0.2.33/bioclients/who/__init__.py +1 -0
- bioclients-0.2.33/bioclients/who/atc/Client.py +54 -0
- bioclients-0.2.33/bioclients/who/atc/Utils.py +45 -0
- bioclients-0.2.33/bioclients/who/atc/__init__.py +1 -0
- bioclients-0.2.33/bioclients/wikidata/Client.py +54 -0
- bioclients-0.2.33/bioclients/wikidata/Utils.py +69 -0
- bioclients-0.2.33/bioclients/wikidata/__init__.py +1 -0
- bioclients-0.2.33/bioclients/wikipathways/Client.py +68 -0
- bioclients-0.2.33/bioclients/wikipathways/Utils.py +51 -0
- bioclients-0.2.33/bioclients/wikipathways/__init__.py +1 -0
- bioclients-0.2.33/bioclients.egg-info/PKG-INFO +122 -0
- bioclients-0.2.33/bioclients.egg-info/SOURCES.txt +300 -0
- bioclients-0.2.33/bioclients.egg-info/dependency_links.txt +1 -0
- bioclients-0.2.33/bioclients.egg-info/top_level.txt +1 -0
- bioclients-0.2.33/setup.cfg +4 -0
- bioclients-0.2.33/setup.py +22 -0
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
Creative Commons Legal Code
|
|
2
|
+
|
|
3
|
+
CC0 1.0 Universal
|
|
4
|
+
|
|
5
|
+
CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE
|
|
6
|
+
LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN
|
|
7
|
+
ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS
|
|
8
|
+
INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES
|
|
9
|
+
REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS
|
|
10
|
+
PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM
|
|
11
|
+
THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED
|
|
12
|
+
HEREUNDER.
|
|
13
|
+
|
|
14
|
+
Statement of Purpose
|
|
15
|
+
|
|
16
|
+
The laws of most jurisdictions throughout the world automatically confer
|
|
17
|
+
exclusive Copyright and Related Rights (defined below) upon the creator
|
|
18
|
+
and subsequent owner(s) (each and all, an "owner") of an original work of
|
|
19
|
+
authorship and/or a database (each, a "Work").
|
|
20
|
+
|
|
21
|
+
Certain owners wish to permanently relinquish those rights to a Work for
|
|
22
|
+
the purpose of contributing to a commons of creative, cultural and
|
|
23
|
+
scientific works ("Commons") that the public can reliably and without fear
|
|
24
|
+
of later claims of infringement build upon, modify, incorporate in other
|
|
25
|
+
works, reuse and redistribute as freely as possible in any form whatsoever
|
|
26
|
+
and for any purposes, including without limitation commercial purposes.
|
|
27
|
+
These owners may contribute to the Commons to promote the ideal of a free
|
|
28
|
+
culture and the further production of creative, cultural and scientific
|
|
29
|
+
works, or to gain reputation or greater distribution for their Work in
|
|
30
|
+
part through the use and efforts of others.
|
|
31
|
+
|
|
32
|
+
For these and/or other purposes and motivations, and without any
|
|
33
|
+
expectation of additional consideration or compensation, the person
|
|
34
|
+
associating CC0 with a Work (the "Affirmer"), to the extent that he or she
|
|
35
|
+
is an owner of Copyright and Related Rights in the Work, voluntarily
|
|
36
|
+
elects to apply CC0 to the Work and publicly distribute the Work under its
|
|
37
|
+
terms, with knowledge of his or her Copyright and Related Rights in the
|
|
38
|
+
Work and the meaning and intended legal effect of CC0 on those rights.
|
|
39
|
+
|
|
40
|
+
1. Copyright and Related Rights. A Work made available under CC0 may be
|
|
41
|
+
protected by copyright and related or neighboring rights ("Copyright and
|
|
42
|
+
Related Rights"). Copyright and Related Rights include, but are not
|
|
43
|
+
limited to, the following:
|
|
44
|
+
|
|
45
|
+
i. the right to reproduce, adapt, distribute, perform, display,
|
|
46
|
+
communicate, and translate a Work;
|
|
47
|
+
ii. moral rights retained by the original author(s) and/or performer(s);
|
|
48
|
+
iii. publicity and privacy rights pertaining to a person's image or
|
|
49
|
+
likeness depicted in a Work;
|
|
50
|
+
iv. rights protecting against unfair competition in regards to a Work,
|
|
51
|
+
subject to the limitations in paragraph 4(a), below;
|
|
52
|
+
v. rights protecting the extraction, dissemination, use and reuse of data
|
|
53
|
+
in a Work;
|
|
54
|
+
vi. database rights (such as those arising under Directive 96/9/EC of the
|
|
55
|
+
European Parliament and of the Council of 11 March 1996 on the legal
|
|
56
|
+
protection of databases, and under any national implementation
|
|
57
|
+
thereof, including any amended or successor version of such
|
|
58
|
+
directive); and
|
|
59
|
+
vii. other similar, equivalent or corresponding rights throughout the
|
|
60
|
+
world based on applicable law or treaty, and any national
|
|
61
|
+
implementations thereof.
|
|
62
|
+
|
|
63
|
+
2. Waiver. To the greatest extent permitted by, but not in contravention
|
|
64
|
+
of, applicable law, Affirmer hereby overtly, fully, permanently,
|
|
65
|
+
irrevocably and unconditionally waives, abandons, and surrenders all of
|
|
66
|
+
Affirmer's Copyright and Related Rights and associated claims and causes
|
|
67
|
+
of action, whether now known or unknown (including existing as well as
|
|
68
|
+
future claims and causes of action), in the Work (i) in all territories
|
|
69
|
+
worldwide, (ii) for the maximum duration provided by applicable law or
|
|
70
|
+
treaty (including future time extensions), (iii) in any current or future
|
|
71
|
+
medium and for any number of copies, and (iv) for any purpose whatsoever,
|
|
72
|
+
including without limitation commercial, advertising or promotional
|
|
73
|
+
purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each
|
|
74
|
+
member of the public at large and to the detriment of Affirmer's heirs and
|
|
75
|
+
successors, fully intending that such Waiver shall not be subject to
|
|
76
|
+
revocation, rescission, cancellation, termination, or any other legal or
|
|
77
|
+
equitable action to disrupt the quiet enjoyment of the Work by the public
|
|
78
|
+
as contemplated by Affirmer's express Statement of Purpose.
|
|
79
|
+
|
|
80
|
+
3. Public License Fallback. Should any part of the Waiver for any reason
|
|
81
|
+
be judged legally invalid or ineffective under applicable law, then the
|
|
82
|
+
Waiver shall be preserved to the maximum extent permitted taking into
|
|
83
|
+
account Affirmer's express Statement of Purpose. In addition, to the
|
|
84
|
+
extent the Waiver is so judged Affirmer hereby grants to each affected
|
|
85
|
+
person a royalty-free, non transferable, non sublicensable, non exclusive,
|
|
86
|
+
irrevocable and unconditional license to exercise Affirmer's Copyright and
|
|
87
|
+
Related Rights in the Work (i) in all territories worldwide, (ii) for the
|
|
88
|
+
maximum duration provided by applicable law or treaty (including future
|
|
89
|
+
time extensions), (iii) in any current or future medium and for any number
|
|
90
|
+
of copies, and (iv) for any purpose whatsoever, including without
|
|
91
|
+
limitation commercial, advertising or promotional purposes (the
|
|
92
|
+
"License"). The License shall be deemed effective as of the date CC0 was
|
|
93
|
+
applied by Affirmer to the Work. Should any part of the License for any
|
|
94
|
+
reason be judged legally invalid or ineffective under applicable law, such
|
|
95
|
+
partial invalidity or ineffectiveness shall not invalidate the remainder
|
|
96
|
+
of the License, and in such case Affirmer hereby affirms that he or she
|
|
97
|
+
will not (i) exercise any of his or her remaining Copyright and Related
|
|
98
|
+
Rights in the Work or (ii) assert any associated claims and causes of
|
|
99
|
+
action with respect to the Work, in either case contrary to Affirmer's
|
|
100
|
+
express Statement of Purpose.
|
|
101
|
+
|
|
102
|
+
4. Limitations and Disclaimers.
|
|
103
|
+
|
|
104
|
+
a. No trademark or patent rights held by Affirmer are waived, abandoned,
|
|
105
|
+
surrendered, licensed or otherwise affected by this document.
|
|
106
|
+
b. Affirmer offers the Work as-is and makes no representations or
|
|
107
|
+
warranties of any kind concerning the Work, express, implied,
|
|
108
|
+
statutory or otherwise, including without limitation warranties of
|
|
109
|
+
title, merchantability, fitness for a particular purpose, non
|
|
110
|
+
infringement, or the absence of latent or other defects, accuracy, or
|
|
111
|
+
the present or absence of errors, whether or not discoverable, all to
|
|
112
|
+
the greatest extent permissible under applicable law.
|
|
113
|
+
c. Affirmer disclaims responsibility for clearing rights of other persons
|
|
114
|
+
that may apply to the Work or any use thereof, including without
|
|
115
|
+
limitation any person's Copyright and Related Rights in the Work.
|
|
116
|
+
Further, Affirmer disclaims responsibility for obtaining any necessary
|
|
117
|
+
consents, permissions or other rights required for any use of the
|
|
118
|
+
Work.
|
|
119
|
+
d. Affirmer understands and acknowledges that Creative Commons is not a
|
|
120
|
+
party to this document and has no duty or obligation with respect to
|
|
121
|
+
this CC0 or use of the Work.
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: bioclients
|
|
3
|
+
Version: 0.2.33
|
|
4
|
+
Summary: Clients and tools for online biomedical resources, usually via REST APIs.
|
|
5
|
+
Home-page: https://github.com/jeremyjyang/bioclients
|
|
6
|
+
Author: Jeremy Yang
|
|
7
|
+
Author-email: jeremyjyang@gmail.com
|
|
8
|
+
Classifier: Programming Language :: Python :: 3
|
|
9
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
10
|
+
Classifier: Operating System :: OS Independent
|
|
11
|
+
Requires-Python: >=3.10
|
|
12
|
+
Description-Content-Type: text/markdown
|
|
13
|
+
License-File: LICENSE
|
|
14
|
+
|
|
15
|
+
# `bioclients` <img align="right" src="doc/images/bioclients.png" height="120" alt="bioclients logo">
|
|
16
|
+
|
|
17
|
+
Python package for access to online biomedical resources,
|
|
18
|
+
usually via REST APIs. Modules generally include
|
|
19
|
+
`Client.py` for command-line use and `Utils.py` for
|
|
20
|
+
integration into other code. With the advent of HTTP web services,
|
|
21
|
+
first SOAP/XML and then mostly REST/JSON, many online APIs
|
|
22
|
+
require very similar methods for data search, requests
|
|
23
|
+
and transforms into usable formats, often TSV.
|
|
24
|
+
|
|
25
|
+
## Availability and installation
|
|
26
|
+
|
|
27
|
+
### Installing from PyPI
|
|
28
|
+
|
|
29
|
+
Releases at <https://pypi.org/project/bioclients/>.
|
|
30
|
+
|
|
31
|
+
```
|
|
32
|
+
pip3 install bioclients
|
|
33
|
+
```
|
|
34
|
+
However, current development snapshot may included additional functionality.
|
|
35
|
+
|
|
36
|
+
### Installing from source
|
|
37
|
+
|
|
38
|
+
Source at <https://github.com/jeremyjyang/bioclients>
|
|
39
|
+
|
|
40
|
+
___(First download or clone.)___
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
Install `build` package.
|
|
44
|
+
|
|
45
|
+
```
|
|
46
|
+
python3 -m pip install --upgrade build
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Install using `build`. This supercedes the deprecated `setup.py install` and `easy_install` methods.
|
|
50
|
+
|
|
51
|
+
```
|
|
52
|
+
cd bioclients
|
|
53
|
+
python3 -m build
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
## Dependencies
|
|
57
|
+
|
|
58
|
+
* Python 3.10+
|
|
59
|
+
* Python packages: `pandas`, `requests`, `yaml`, `psycopg2`, `tqdm`, etc. (See [conda/environment.yml](conda/environment.yml)).
|
|
60
|
+
|
|
61
|
+
## Modules
|
|
62
|
+
|
|
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) • [__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
|
+
|
|
65
|
+
Miscellaneous utilities: [__UTIL__](doc/util.md)
|
|
66
|
+
|
|
67
|
+
## Usage Example
|
|
68
|
+
|
|
69
|
+
```
|
|
70
|
+
python3 -m bioclients.pubchem.Client -h
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
## Design pattern
|
|
74
|
+
|
|
75
|
+
Generally each module includes command-line app `Client.py` which calls
|
|
76
|
+
functions in a corresponding `Utils.py`, providing all capabilities
|
|
77
|
+
by import of the module. Command-line apps not API clients are generally
|
|
78
|
+
named `App.py`. Functions can write to an output file
|
|
79
|
+
or return a Pandas dataframe (if output file unspecified).
|
|
80
|
+
|
|
81
|
+
## Data structures and formats, XML, JSON, and TSV
|
|
82
|
+
|
|
83
|
+
bioclients is designed to be simple and practical, and XML, JSON
|
|
84
|
+
and TSV are likewise simple in many respects, yet a great deal
|
|
85
|
+
of conceptual and technological progress is reflected. XML and JSON
|
|
86
|
+
can represent arbitrarily complex data objects, comprised of nested lists,
|
|
87
|
+
dictionaries, and trees of primary types. TSV represents tables of
|
|
88
|
+
rows and columns, related by common keys, reflecting the development
|
|
89
|
+
of SQL and relational databases. Transforming JSON to TSV, as these
|
|
90
|
+
clients generally do, projects data objects to tables useful for many
|
|
91
|
+
applications (e.g. machine learning).
|
|
92
|
+
|
|
93
|
+
## Conda environment
|
|
94
|
+
|
|
95
|
+
bioclients depends on numerous Python packages. (See [conda/environment.yml](conda/environment.yml)).
|
|
96
|
+
The following commands create and activate a Conda environment `bioclients`:
|
|
97
|
+
|
|
98
|
+
```
|
|
99
|
+
$ conda env create -f conda/environment.yml
|
|
100
|
+
```
|
|
101
|
+
If that fails, try:
|
|
102
|
+
```
|
|
103
|
+
$ conda create -n bioclients -c conda-forge pandas readline requests pyyaml tqdm psycopg2 numpy scipy scikit-learn matplotlib
|
|
104
|
+
```
|
|
105
|
+
then:
|
|
106
|
+
```
|
|
107
|
+
$ conda activate bioclients
|
|
108
|
+
(bioclients) $ pip install bioclients
|
|
109
|
+
```
|
|
110
|
+
and install additional packages as needed via `pip`, e.g.:
|
|
111
|
+
```
|
|
112
|
+
(bioclients) $ pip install sqlalchemy
|
|
113
|
+
(bioclients) $ pip install pyquery
|
|
114
|
+
(bioclients) $ pip install mygene
|
|
115
|
+
(bioclients) $ pip install click
|
|
116
|
+
(bioclients) $ pip install PyMuPDF
|
|
117
|
+
(bioclients) $ pip install py2neo
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
## Venv, etc.
|
|
121
|
+
|
|
122
|
+
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.
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
# `bioclients` <img align="right" src="doc/images/bioclients.png" height="120" alt="bioclients logo">
|
|
2
|
+
|
|
3
|
+
Python package for access to online biomedical resources,
|
|
4
|
+
usually via REST APIs. Modules generally include
|
|
5
|
+
`Client.py` for command-line use and `Utils.py` for
|
|
6
|
+
integration into other code. With the advent of HTTP web services,
|
|
7
|
+
first SOAP/XML and then mostly REST/JSON, many online APIs
|
|
8
|
+
require very similar methods for data search, requests
|
|
9
|
+
and transforms into usable formats, often TSV.
|
|
10
|
+
|
|
11
|
+
## Availability and installation
|
|
12
|
+
|
|
13
|
+
### Installing from PyPI
|
|
14
|
+
|
|
15
|
+
Releases at <https://pypi.org/project/bioclients/>.
|
|
16
|
+
|
|
17
|
+
```
|
|
18
|
+
pip3 install bioclients
|
|
19
|
+
```
|
|
20
|
+
However, current development snapshot may included additional functionality.
|
|
21
|
+
|
|
22
|
+
### Installing from source
|
|
23
|
+
|
|
24
|
+
Source at <https://github.com/jeremyjyang/bioclients>
|
|
25
|
+
|
|
26
|
+
___(First download or clone.)___
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
Install `build` package.
|
|
30
|
+
|
|
31
|
+
```
|
|
32
|
+
python3 -m pip install --upgrade build
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Install using `build`. This supercedes the deprecated `setup.py install` and `easy_install` methods.
|
|
36
|
+
|
|
37
|
+
```
|
|
38
|
+
cd bioclients
|
|
39
|
+
python3 -m build
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Dependencies
|
|
43
|
+
|
|
44
|
+
* Python 3.10+
|
|
45
|
+
* Python packages: `pandas`, `requests`, `yaml`, `psycopg2`, `tqdm`, etc. (See [conda/environment.yml](conda/environment.yml)).
|
|
46
|
+
|
|
47
|
+
## Modules
|
|
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) • [__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
|
+
|
|
51
|
+
Miscellaneous utilities: [__UTIL__](doc/util.md)
|
|
52
|
+
|
|
53
|
+
## Usage Example
|
|
54
|
+
|
|
55
|
+
```
|
|
56
|
+
python3 -m bioclients.pubchem.Client -h
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## Design pattern
|
|
60
|
+
|
|
61
|
+
Generally each module includes command-line app `Client.py` which calls
|
|
62
|
+
functions in a corresponding `Utils.py`, providing all capabilities
|
|
63
|
+
by import of the module. Command-line apps not API clients are generally
|
|
64
|
+
named `App.py`. Functions can write to an output file
|
|
65
|
+
or return a Pandas dataframe (if output file unspecified).
|
|
66
|
+
|
|
67
|
+
## Data structures and formats, XML, JSON, and TSV
|
|
68
|
+
|
|
69
|
+
bioclients is designed to be simple and practical, and XML, JSON
|
|
70
|
+
and TSV are likewise simple in many respects, yet a great deal
|
|
71
|
+
of conceptual and technological progress is reflected. XML and JSON
|
|
72
|
+
can represent arbitrarily complex data objects, comprised of nested lists,
|
|
73
|
+
dictionaries, and trees of primary types. TSV represents tables of
|
|
74
|
+
rows and columns, related by common keys, reflecting the development
|
|
75
|
+
of SQL and relational databases. Transforming JSON to TSV, as these
|
|
76
|
+
clients generally do, projects data objects to tables useful for many
|
|
77
|
+
applications (e.g. machine learning).
|
|
78
|
+
|
|
79
|
+
## Conda environment
|
|
80
|
+
|
|
81
|
+
bioclients depends on numerous Python packages. (See [conda/environment.yml](conda/environment.yml)).
|
|
82
|
+
The following commands create and activate a Conda environment `bioclients`:
|
|
83
|
+
|
|
84
|
+
```
|
|
85
|
+
$ conda env create -f conda/environment.yml
|
|
86
|
+
```
|
|
87
|
+
If that fails, try:
|
|
88
|
+
```
|
|
89
|
+
$ conda create -n bioclients -c conda-forge pandas readline requests pyyaml tqdm psycopg2 numpy scipy scikit-learn matplotlib
|
|
90
|
+
```
|
|
91
|
+
then:
|
|
92
|
+
```
|
|
93
|
+
$ conda activate bioclients
|
|
94
|
+
(bioclients) $ pip install bioclients
|
|
95
|
+
```
|
|
96
|
+
and install additional packages as needed via `pip`, e.g.:
|
|
97
|
+
```
|
|
98
|
+
(bioclients) $ pip install sqlalchemy
|
|
99
|
+
(bioclients) $ pip install pyquery
|
|
100
|
+
(bioclients) $ pip install mygene
|
|
101
|
+
(bioclients) $ pip install click
|
|
102
|
+
(bioclients) $ pip install PyMuPDF
|
|
103
|
+
(bioclients) $ pip install py2neo
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
## Venv, etc.
|
|
107
|
+
|
|
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.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Python package for access to online biomedical resources, usually via REST APIs."""
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
#############################################################################
|
|
3
|
+
### See: http://www.brain-map.org/api/index.html
|
|
4
|
+
### http://help.brain-map.org/display/api/RESTful+Model+Access+%28RMA%29
|
|
5
|
+
###
|
|
6
|
+
### http://api.brain-map.org/api/v2/data/[Model]/[Model.id].[json|xml|csv]
|
|
7
|
+
###
|
|
8
|
+
### http://api.brain-map.org/api/v2/data/Organism/1.xml
|
|
9
|
+
### http://api.brain-map.org/api/v2/data/Gene/15.xml
|
|
10
|
+
### http://api.brain-map.org/api/v2/data/Chromosome/12.json
|
|
11
|
+
### http://api.brain-map.org/api/v2/data/Structure/4005.xml
|
|
12
|
+
###
|
|
13
|
+
### http://api.brain-map.org/api/v2/data/Organism/query.json
|
|
14
|
+
### http://api.brain-map.org/api/v2/data/Gene/describe.json
|
|
15
|
+
### http://api.brain-map.org/api/v2/data/enumerate.json
|
|
16
|
+
###
|
|
17
|
+
### http://api.brain-map.org/api/v2/data/Gene/
|
|
18
|
+
### http://api.brain-map.org/api/v2/data/Gene/18376.json
|
|
19
|
+
###
|
|
20
|
+
### &num_rows=[#]&start_row=[#]&order=[...]
|
|
21
|
+
#############################################################################
|
|
22
|
+
import sys,os,re,argparse,time,json,logging
|
|
23
|
+
|
|
24
|
+
from ... import allen
|
|
25
|
+
#
|
|
26
|
+
##############################################################################
|
|
27
|
+
if __name__=='__main__':
|
|
28
|
+
API_HOST='api.brain-map.org'
|
|
29
|
+
API_BASE_PATH='/api/v2'
|
|
30
|
+
PROG=os.path.basename(sys.argv[0])
|
|
31
|
+
ftype='SYMBOL';
|
|
32
|
+
ops = ["show_info", "list_probes"]
|
|
33
|
+
parser = argparse.ArgumentParser( description='AllenBrainAtlas REST API client')
|
|
34
|
+
parser.add_argument("op", choices=ops, help='OPERATION (select one)')
|
|
35
|
+
parser.add_argument("--i", dest="ifile", help="input file")
|
|
36
|
+
parser.add_argument("--ids", help="input IDs")
|
|
37
|
+
parser.add_argument("--o", dest="ofile", help="output (TSV)")
|
|
38
|
+
parser.add_argument("--api_host", default=API_HOST)
|
|
39
|
+
parser.add_argument("--api_base_path", default=API_BASE_PATH)
|
|
40
|
+
parser.add_argument("-v", "--verbose", action="count", default=0)
|
|
41
|
+
args = parser.parse_args()
|
|
42
|
+
|
|
43
|
+
logging.basicConfig(format='%(levelname)s:%(message)s', level=(logging.DEBUG if args.verbose>1 else logging.INFO))
|
|
44
|
+
|
|
45
|
+
api_base_url='https://'+args.api_host+args.api_base_path
|
|
46
|
+
|
|
47
|
+
fout = open(args.ofile, "w") if args.ofile else sys.stdout
|
|
48
|
+
|
|
49
|
+
ids=[]
|
|
50
|
+
if args.ifile:
|
|
51
|
+
fin = open(args.ifile)
|
|
52
|
+
while True:
|
|
53
|
+
line = fin.readline()
|
|
54
|
+
if not line: break
|
|
55
|
+
ids.append(line.rstrip())
|
|
56
|
+
fin.close()
|
|
57
|
+
elif args.ids:
|
|
58
|
+
ids = re.split('[, ]+', args.ids.strip())
|
|
59
|
+
if len(ids)>0: logging.info('Input IDs: %d'%(len(ids)))
|
|
60
|
+
|
|
61
|
+
t0=time.time()
|
|
62
|
+
|
|
63
|
+
if args.op=="show_info":
|
|
64
|
+
allen.brain.Utils.ShowInfo(api_base_url, fout)
|
|
65
|
+
|
|
66
|
+
elif args.op=="list_probes":
|
|
67
|
+
allen.brain.Utils.ListProbes(api_base_url, ids, fout)
|
|
68
|
+
|
|
69
|
+
else:
|
|
70
|
+
parser.error('Invalid operation: {0}'.format(args.op))
|
|
71
|
+
|
|
72
|
+
logging.info('Elapsed time: %s'%(time.strftime('%Hh:%Mm:%Ss', time.gmtime(time.time()-t0))))
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
#############################################################################
|
|
3
|
+
### See: http://www.brain-map.org/api/index.html
|
|
4
|
+
### http://help.brain-map.org/display/api/RESTful+Model+Access+%28RMA%29
|
|
5
|
+
###
|
|
6
|
+
### http://api.brain-map.org/api/v2/data/[Model]/[Model.id].[json|xml|csv]
|
|
7
|
+
###
|
|
8
|
+
### http://api.brain-map.org/api/v2/data/Organism/1.xml
|
|
9
|
+
### http://api.brain-map.org/api/v2/data/Gene/15.xml
|
|
10
|
+
### http://api.brain-map.org/api/v2/data/Chromosome/12.json
|
|
11
|
+
### http://api.brain-map.org/api/v2/data/Structure/4005.xml
|
|
12
|
+
###
|
|
13
|
+
### http://api.brain-map.org/api/v2/data/Organism/query.json
|
|
14
|
+
### http://api.brain-map.org/api/v2/data/Gene/describe.json
|
|
15
|
+
### http://api.brain-map.org/api/v2/data/enumerate.json
|
|
16
|
+
###
|
|
17
|
+
### http://api.brain-map.org/api/v2/data/Gene/
|
|
18
|
+
### http://api.brain-map.org/api/v2/data/Gene/18376.json
|
|
19
|
+
###
|
|
20
|
+
### &num_rows=[#]&start_row=[#]&order=[...]
|
|
21
|
+
#############################################################################
|
|
22
|
+
import sys,os,re,time,logging
|
|
23
|
+
import urllib.parse,json
|
|
24
|
+
|
|
25
|
+
from ...util import rest
|
|
26
|
+
#
|
|
27
|
+
##############################################################################
|
|
28
|
+
def ShowInfo(base_url, fout):
|
|
29
|
+
rval = rest.Utils.GetURL(base_url+'/data/enumerate.json', parse_json=True)
|
|
30
|
+
print(json.dumps(rval, sort_keys=True, indent=2))
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
##############################################################################
|
|
34
|
+
def ListProbes(base_url, qrys, fout):
|
|
35
|
+
n_probe=0;
|
|
36
|
+
num_rows=0; start_row=0; total_rows=0;
|
|
37
|
+
for qry in qrys:
|
|
38
|
+
while True:
|
|
39
|
+
logging.debug('start_row = %d, num_rows = %d, total_rows = %d'%(start_row, num_rows, total_rows))
|
|
40
|
+
url_this = (base_url+"/data/query.json?start_row=%d&criteria=model::Probe,rma::criteria,gene[acronym$eq'%s']"%(start_row+num_rows, qry))
|
|
41
|
+
try:
|
|
42
|
+
rval = rest.Utils.GetURL(url_this, parse_json=True)
|
|
43
|
+
except Exception as e:
|
|
44
|
+
logging.error(e)
|
|
45
|
+
continue
|
|
46
|
+
success = rval['success'] if 'success' in rval else False
|
|
47
|
+
if not success:
|
|
48
|
+
break
|
|
49
|
+
id_this = rval['id'] if 'id' in rval else None
|
|
50
|
+
total_rows = rval['total_rows'] if 'total_rows' in rval else None
|
|
51
|
+
num_rows = rval['num_rows'] if 'num_rows' in rval else None
|
|
52
|
+
start_row = rval['start_row'] if 'start_row' in rval else None
|
|
53
|
+
probes = rval['msg'] if 'msg' in rval else []
|
|
54
|
+
for probe in probes:
|
|
55
|
+
n_probe+=1
|
|
56
|
+
if n_probe==1:
|
|
57
|
+
tags = sorted(probe.keys()) ##1st probe defines fields
|
|
58
|
+
fout.write('%s\n'%('\t'.join(['query','id']+tags)))
|
|
59
|
+
vals = [qry, id_this]+[(probe[tag] if tag in probe else '') for tag in tags]
|
|
60
|
+
fout.write('%s\n'%('\t'.join(vals)))
|
|
61
|
+
if start_row+num_rows >= total_rows:
|
|
62
|
+
break
|
|
63
|
+
logging.info('probes: %d'%n_probe)
|
|
64
|
+
|
|
65
|
+
##############################################################################
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
from .Utils import *
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""
|
|
3
|
+
utility app for the AMP T2D REST API.
|
|
4
|
+
http://www.type2diabetesgenetics.org/
|
|
5
|
+
http://www.kp4cd.org/apis/t2d
|
|
6
|
+
http://52.54.103.84/kpn-kb-openapi/
|
|
7
|
+
|
|
8
|
+
DEPICT software (Pers, TH, et al., 2015)
|
|
9
|
+
"""
|
|
10
|
+
###
|
|
11
|
+
import sys,os,re,json,argparse,time,logging
|
|
12
|
+
#
|
|
13
|
+
from ... import amp
|
|
14
|
+
#
|
|
15
|
+
API_HOST='public.type2diabeteskb.org'
|
|
16
|
+
API_BASE_PATH='/dccservices'
|
|
17
|
+
#
|
|
18
|
+
#############################################################################
|
|
19
|
+
if __name__=='__main__':
|
|
20
|
+
ops = ["list_tissues", "list_phenotypes", "depict_genepathway"]
|
|
21
|
+
parser = argparse.ArgumentParser(description="AMP T2D REST client")
|
|
22
|
+
parser.add_argument("op",choices=ops,help='operation')
|
|
23
|
+
parser.add_argument("--i", dest="ifile", help="input IDs file")
|
|
24
|
+
parser.add_argument("--ids", help="input IDs, comma-separated")
|
|
25
|
+
parser.add_argument("--gene", help="query gene (e.g. SLC30A8)")
|
|
26
|
+
parser.add_argument("--phenotype", default="T2D")
|
|
27
|
+
parser.add_argument("--max_pval", type=float, default=.0005)
|
|
28
|
+
parser.add_argument("--api_host", default=API_HOST)
|
|
29
|
+
parser.add_argument("--api_base_path", default=API_BASE_PATH)
|
|
30
|
+
parser.add_argument("--skip", type=int, default=0)
|
|
31
|
+
parser.add_argument("--nmax", type=int, default=0)
|
|
32
|
+
parser.add_argument("--o", dest="ofile", help="output (TSV)")
|
|
33
|
+
parser.add_argument("-v", "--verbose", default=0, action="count")
|
|
34
|
+
args = parser.parse_args()
|
|
35
|
+
|
|
36
|
+
logging.basicConfig(format='%(levelname)s:%(message)s', level=(logging.DEBUG if args.verbose>1 else logging.INFO))
|
|
37
|
+
|
|
38
|
+
BASE_URL = 'http://'+args.api_host+args.api_base_path
|
|
39
|
+
|
|
40
|
+
fout = open(args.ofile, "w") if args.ofile else sys.stdout
|
|
41
|
+
|
|
42
|
+
if args.ifile:
|
|
43
|
+
fin = open(args.ifile)
|
|
44
|
+
ids=[]
|
|
45
|
+
while True:
|
|
46
|
+
line = fin.readline()
|
|
47
|
+
if not line: break
|
|
48
|
+
ids.append(line.strip())
|
|
49
|
+
logging.info('input IDs: %d'%(len(ids)))
|
|
50
|
+
fin.close()
|
|
51
|
+
elif args.ids:
|
|
52
|
+
ids = re.split('[, ]+', args.ids.strip())
|
|
53
|
+
|
|
54
|
+
t0=time.time()
|
|
55
|
+
|
|
56
|
+
if args.op == 'list_tissues':
|
|
57
|
+
amp.t2d.ListTissues(BASE_URL, fout)
|
|
58
|
+
|
|
59
|
+
elif args.op == 'list_phenotypes':
|
|
60
|
+
amp.t2d.ListPhenotypes(BASE_URL, fout)
|
|
61
|
+
|
|
62
|
+
elif args.op == 'depict_genepathway':
|
|
63
|
+
amp.t2d.DepictGenePathway(BASE_URL, args.gene, args.phenotype, args.max_pval, fout)
|
|
64
|
+
|
|
65
|
+
else:
|
|
66
|
+
parser.error('Invalid operation: %s'%args.op)
|
|
67
|
+
|
|
68
|
+
logging.info('elapsed time: %s'%(time.strftime('%Hh:%Mm:%Ss', time.gmtime(time.time()-t0))))
|
|
69
|
+
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""
|
|
3
|
+
Utilities for the AMP T2D REST API.
|
|
4
|
+
http://www.type2diabetesgenetics.org/
|
|
5
|
+
http://www.kp4cd.org/apis/t2d
|
|
6
|
+
http://52.54.103.84/kpn-kb-openapi/
|
|
7
|
+
|
|
8
|
+
DEPICT software (Pers, TH, et al., 2015)
|
|
9
|
+
"""
|
|
10
|
+
###
|
|
11
|
+
import sys,os,re,json,time,logging
|
|
12
|
+
#
|
|
13
|
+
from ...util import rest
|
|
14
|
+
#
|
|
15
|
+
#############################################################################
|
|
16
|
+
def ListTissues(base_url, fout):
|
|
17
|
+
rval = rest.Utils.GetURL(base_url+'/graph/tissue/list/object', parse_json=True)
|
|
18
|
+
tissues = rval["data"] if "data" in rval else []
|
|
19
|
+
tags = None; n_out=0;
|
|
20
|
+
for tissue in tissues:
|
|
21
|
+
logging.debug(json.dumps(tissue, indent=2))
|
|
22
|
+
if not tags:
|
|
23
|
+
tags = tissue.keys()
|
|
24
|
+
fout.write('\t'.join(tags)+'\n')
|
|
25
|
+
vals = [str(tissue[tag]) if tag in tissue else '' for tag in tags]
|
|
26
|
+
fout.write('\t'.join(vals)+'\n')
|
|
27
|
+
n_out += 1
|
|
28
|
+
logging.info("n_out: %d"%(n_out))
|
|
29
|
+
|
|
30
|
+
#############################################################################
|
|
31
|
+
def ListPhenotypes(base_url, fout):
|
|
32
|
+
rval=rest.Utils.GetURL(base_url+'/graph/phenotype/list/object', parse_json=True)
|
|
33
|
+
phenotypes = rval["data"] if "data" in rval else []
|
|
34
|
+
tags = None; n_out=0;
|
|
35
|
+
for phenotype in phenotypes:
|
|
36
|
+
logging.debug(json.dumps(phenotype, indent=2))
|
|
37
|
+
if not tags:
|
|
38
|
+
tags = phenotype.keys()
|
|
39
|
+
fout.write('\t'.join(tags)+'\n')
|
|
40
|
+
vals = [str(phenotype[tag]) if tag in phenotype else '' for tag in tags]
|
|
41
|
+
fout.write('\t'.join(vals)+'\n')
|
|
42
|
+
n_out += 1
|
|
43
|
+
logging.info("n_out: %d"%(n_out))
|
|
44
|
+
|
|
45
|
+
##############################################################################
|
|
46
|
+
def DepictGenePathway(base_url, gene, phenotype, max_pval, fout):
|
|
47
|
+
url = base_url+('/testcalls/depict/genepathway/object?gene=%s&phenotype=%s<_value=%f'%(gene, phenotype, max_pval))
|
|
48
|
+
rval = rest.Utils.GetURL(url, parse_json=True)
|
|
49
|
+
pathways = rval["data"] if "data" in rval else []
|
|
50
|
+
tags = None; n_out=0;
|
|
51
|
+
for pathway in pathways:
|
|
52
|
+
logging.debug(json.dumps(pathway, indent=2))
|
|
53
|
+
if not tags:
|
|
54
|
+
tags = pathway.keys()
|
|
55
|
+
fout.write('\t'.join(tags)+'\n')
|
|
56
|
+
vals = [str(pathway[tag]) if tag in pathway else '' for tag in tags]
|
|
57
|
+
fout.write('\t'.join(vals)+'\n')
|
|
58
|
+
n_out += 1
|
|
59
|
+
logging.info("n_out: %d"%(n_out))
|
|
60
|
+
|
|
61
|
+
##############################################################################
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
from .Utils import *
|