4.1. datanator package

4.1.1. Subpackages

4.1.2. Submodules

4.1.3. datanator.__main__ module

Command line utilities

Author

Yosef Roth <yosefdroth@gmail.com>

Author

Jonathan Karr <jonrkarr@gmail.com>

Author

Saahith Pochiraju <saahith116@gmail.com>

Date

2017-04-12

Copyright

2017, Karr Lab

License

MIT

class datanator.__main__.AggregateBuildController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['--path'], {'type': <class 'str'>, 'default': '/root/.wc/data/datanator', 'help': 'path to build the database'}), (['--verbose'], {'type': <class 'bool'>, 'default': False, 'help': 'verbosity'}), (['--max-entries'], {'type': <class 'int'>, 'default': inf, 'help': 'number of normalized entries to add per database. Default: Full Database'}), (['--build-on-existing'], {'type': <class 'bool'>, 'default': False, 'help': 'load from existing database on karr lab server'}), (['--load-full-small-dbs'], {'type': <class 'bool'>, 'default': True, 'help': 'loads entire small database modules'})][source]
description = 'Builds Aggregated Database'[source]
help = 'Builds Aggregated Database'[source]
label = 'aggregate'[source]
stacked_on = 'build'[source]
stacked_type = 'nested'[source]
class datanator.__main__.App(label=None, **kw)[source]

Bases: cement.core.foundation.App

class Meta[source]

Bases: object

base_controller = 'base'[source]
handlers = [<class 'datanator.__main__.BaseController'>, <class 'datanator.__main__.UploadDataController'>, <class 'datanator.__main__.UploadReferenceGenome'>, <class 'datanator.__main__.UploadRNASeqExperiment'>, <class 'datanator.__main__.UploadData'>, <class 'datanator.__main__.DownloadController'>, <class 'datanator.__main__.BuildController'>, <class 'datanator.__main__.AggregateBuildController'>, <class 'datanator.__main__.GenerateTemplateController'>, <class 'datanator.__main__.GenerateRNASeqTemplate'>, <class 'datanator.__main__.TaxonomyController'>, <class 'datanator.__main__.TaxonomyGetRankController'>, <class 'datanator.__main__.TaxonomyGetParentsController'>, <class 'datanator.__main__.TaxonomyGetCommonAncestorController'>, <class 'datanator.__main__.TaxonomyGetDistanceToCommonAncestorController'>, <class 'datanator.__main__.TaxonomyGetDistanceToRoot'>, <class 'datanator.__main__.MoleculeController'>, <class 'datanator.__main__.MoleculeGetStructureController'>, <class 'datanator.__main__.MoleculeConvertStructureController'>, <class 'datanator.__main__.ReactionController'>, <class 'datanator.__main__.ReactionGetEcNumberController'>][source]
label = 'datanator'[source]
class datanator.__main__.BaseController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['-v', '--version'], {'action': 'version', 'version': '0.2'})][source]
description = 'Utilities for aggregating data for biochemical models'[source]
help = 'Utilities for aggregating data for biochemical models'[source]
label = 'base'[source]
class datanator.__main__.BuildController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['--max-entries'], {'type': <class 'int'>, 'default': inf, 'help': 'number of normalized entries to add per database. Default: Full Database'}), (['--path'], {'type': <class 'str'>, 'default': '/root/.wc/data/datanator', 'help': 'path to build the database'}), (['--clear-existing-content'], {'type': <class 'bool'>, 'default': False, 'help': 'clears existing content of the db if exists'}), (['--verbose'], {'type': <class 'bool'>, 'default': False, 'help': 'verbosity'})][source]
description = 'Build aggregated database'[source]
help = 'Build aggregated database'[source]
label = 'build'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
array_express()[source]
corum()[source]
ecmdb()[source]
intact()[source]
jaspar()[source]
pax()[source]
sabio()[source]
uniprot()[source]
class datanator.__main__.DownloadController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['--path'], {'type': <class 'str'>, 'help': 'path to download the modules', 'default': '/root/.wc/data/datanator'})][source]
description = 'Download existing databases from Karr Lab Server'[source]
help = 'Download existing databases from Karr Lab Server'[source]
label = 'download'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
aggregate()[source]
array_express()[source]
corum()[source]
ecmdb()[source]
intact()[source]
jaspar()[source]
pax()[source]
sabio()[source]
uniprot()[source]
class datanator.__main__.GenerateRNASeqTemplate(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['directory_name'], {'type': <class 'str'>, 'help': 'path to save the directory'})][source]
description = 'Generate a folder with excel tables to upload rna-seq experiments'[source]
help = 'Generate a folder with excel tables to upload rna-seq experiments'[source]
label = 'generate-rna-seq-template'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
class datanator.__main__.GenerateTemplateController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['filename'], {'type': <class 'str'>, 'help': 'path to save the Excel template'})][source]
description = 'Generate an Excel template for specifying which reactions to aggregate kinetic data about'[source]
help = 'Generate an Excel template for specifying which reactions to aggregate kinetic data about'[source]
label = 'generate-template'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
class datanator.__main__.MoleculeController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [][source]
description = 'Molecule utilities'[source]
help = 'Molecule utilities'[source]
label = 'molecule'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
class datanator.__main__.MoleculeConvertStructureController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['structure'], {'type': <class 'str'>, 'help': 'Structure in InChI, MOL, or canonical SMILES format'}), (['format'], {'type': <class 'str'>, 'help': 'Output format: inchi (InChI), mol (MOL), or can (canonical SMILES)'})][source]
description = 'Convert molecule structure'[source]
help = 'Convert molecule structure'[source]
label = 'convert-structure'[source]
stacked_on = 'molecule'[source]
stacked_type = 'nested'[source]
class datanator.__main__.MoleculeGetStructureController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['--by-name'], {'dest': 'by_name', 'action': 'store_true', 'default': True, 'help': 'If set, lookup structure by name'}), (['--by-id'], {'dest': 'by_name', 'action': 'store_false', 'default': True, 'help': 'If set, lookup structure by id'}), (['--namespace'], {'type': <class 'str'>, 'help': 'Namespace of id'}), (['name_or_id'], {'type': <class 'str'>, 'help': 'Name or id of the molecule'})][source]
description = 'Get the structure of a molecule by its name or id'[source]
help = 'Get the structure of a molecule by its name or id'[source]
label = 'get-structure'[source]
stacked_on = 'molecule'[source]
stacked_type = 'nested'[source]
class datanator.__main__.ReactionController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [][source]
description = 'Reaction utilities'[source]
help = 'Reaction utilities'[source]
label = 'reaction'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
class datanator.__main__.ReactionGetEcNumberController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['--do-not-restore-data'], {'dest': 'restore_data', 'action': 'store_false', 'help': 'If set, do not restore the data'}), (['--restore-schema'], {'dest': 'restore_schema', 'action': 'store_true', 'help': 'If set, restore the schema'}), (['--do-not-exit-on-error'], {'dest': 'exit_on_error', 'action': 'store_false', 'help': 'If set, do not exit on errors'})][source]
description = 'Restore the content of the Datanator database'[source]
help = 'Restore the content of the Datanator database'[source]
label = 'restore'[source]
stacked_on = 'db'[source]
stacked_type = 'nested'[source]
class datanator.__main__.TaxonomyController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [][source]
description = 'Taxonomy utilities'[source]
help = 'Taxonomy utilities'[source]
label = 'taxonomy'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
class datanator.__main__.TaxonomyGetCommonAncestorController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['taxon_id_or_name_1'], {'type': <class 'str'>, 'help': "Taxon id or name (examples: 9606, 'Homo sapiens')"}), (['taxon_id_or_name_2'], {'type': <class 'str'>, 'help': "Taxon id or name (examples: 9606, 'Homo sapiens')"})][source]
description = 'Get the latest common ancestor between two taxa'[source]
help = 'Get the latest common ancestor between two taxa'[source]
label = 'get-common-ancestor'[source]
stacked_on = 'taxonomy'[source]
stacked_type = 'nested'[source]
class datanator.__main__.TaxonomyGetDistanceToCommonAncestorController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['taxon_id_or_name_1'], {'type': <class 'str'>, 'help': "Taxon id or name (examples: 9606, 'Homo sapiens')"}), (['taxon_id_or_name_2'], {'type': <class 'str'>, 'help': "Taxon id or name (examples: 9606, 'Homo sapiens')"})][source]
description = 'Get the distance to the latest common ancestor between two taxa'[source]
help = 'Get the distance to the latest common ancestor between two taxa'[source]
label = 'get-distance-to-common-ancestor'[source]
stacked_on = 'taxonomy'[source]
stacked_type = 'nested'[source]
class datanator.__main__.TaxonomyGetDistanceToRoot(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['taxon_id_or_name'], {'type': <class 'str'>, 'help': "Taxon id or name (examples: 9606, 'Homo sapiens')"})][source]
description = 'Get the distance to from a taxon to the root of the taxonomic tree'[source]
help = 'Get the distance to from a taxon to the root of the taxonomic tree'[source]
label = 'get-distance-to-root'[source]
stacked_on = 'taxonomy'[source]
stacked_type = 'nested'[source]
class datanator.__main__.TaxonomyGetParentsController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['taxon_id_or_name'], {'type': <class 'str'>, 'help': "Taxon id or name (examples: 9606, 'Homo sapiens')"})][source]
description = 'Get the parents of a taxon'[source]
help = 'Get the parents of a taxon'[source]
label = 'get-parents'[source]
stacked_on = 'taxonomy'[source]
stacked_type = 'nested'[source]
class datanator.__main__.TaxonomyGetRankController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['taxon_id_or_name'], {'type': <class 'str'>, 'help': "Taxon id or name (examples: 9606, 'Homo sapiens')"})][source]
description = 'Get the rank of a taxon'[source]
help = 'Get the rank of a taxon'[source]
label = 'get-rank'[source]
stacked_on = 'taxonomy'[source]
stacked_type = 'nested'[source]
class datanator.__main__.UploadData(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['data_type'], {'type': <class 'str'>, 'help': 'type of data to be uploaded'})][source]
description = 'Upload data from overall schema'[source]
help = 'Upload data from overall schema'[source]
label = 'general-data'[source]
stacked_on = 'upload'[source]
stacked_type = 'nested'[source]
class datanator.__main__.UploadDataController(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [][source]
description = 'Upload reference genome into Datanator. The reference genome must be in Genbank or Ensembl format'[source]
help = 'Upload reference genome into Datanator. The reference genome must be in Genbank or Ensembl format'[source]
label = 'upload'[source]
stacked_on = 'base'[source]
stacked_type = 'nested'[source]
class datanator.__main__.UploadRNASeqExperiment(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['ref-genome-path'], {'type': <class 'str'>, 'help': 'path to reference genome', 'default': '/root/.wc/data/datanator'}), (['--db-path'], {'type': <class 'str'>, 'help': 'path to build the database', 'default': '/root/.wc/data/datanator'})][source]
description = 'Upload an RNA-seq experiment'[source]
help = 'Upload an RNA-seq experiment'[source]
label = 'rna-seq-experiment'[source]
stacked_on = 'upload'[source]
stacked_type = 'nested'[source]
class datanator.__main__.UploadReferenceGenome(*args, **kw)[source]

Bases: cement.ext.ext_argparse.ArgparseController

class Meta[source]

Bases: object

arguments = [(['genome_path'], {'type': <class 'str'>, 'help': 'path to reference genome', 'default': '/root/.wc/data/datanator'}), (['--db-path'], {'type': <class 'str'>, 'help': 'path to build the database', 'default': '/root/.wc/data/datanator'})][source]
description = 'Upload a ref-seq genome'[source]
help = 'Upload a ref-seq genome'[source]
label = 'reference-genome'[source]
stacked_on = 'upload'[source]
stacked_type = 'nested'[source]
datanator.__main__.create_taxon(id_or_name)[source]

Create a taxon with NCBI id=:obj:id_or_name or name=:obj:id_or_name

Parameters

id_or_name (str) – NCBI id or name

Returns

taxon

Return type

taxonomy_util.Taxon

datanator.__main__.main()[source]

4.1.4. datanator._version module

4.1.5. datanator.parse_metabolite_concentration module

class datanator.parse_metabolite_concentration.ParseMetaboliteConcentration(MongoDB=None, db=None, collection=None, max_entries=inf, username=None, password=None, authSource='admin', readPreference='nearest')[source]

Bases: datanator_query_python.util.mongo_util.MongoUtil

parse_metabolite()[source]

Read JSON metabolite concentration files from Github and insert separate documents for each metabolite into MongoDB database

Parameters

()

Returns

()

datanator.parse_metabolite_concentration.main()[source]

4.1.6. Module contents