Skip to main content

Tools to access CHADO databases

Project description

# chado-tools

Python3 command line script providing various tools for accessing CHADO databases

[![Build Status](https://travis-ci.org/sanger-pathogens/chado-tools.svg?branch=master)](https://travis-ci.org/sanger-pathogens/chado-tools)

## Prerequisites

* PostgreSQL
* Python 3.6 or higher

## Installation

Download the latest release from this github repository, or clone the repository.

Change the file with [default connection settings](pychado/data/defaultDatabase.yml) such that it contains an existing PostgreSQL database to which you can connect.
Note: This database is only used for housekeeping purposes, it will never be changed or removed by `chado-tools`. You can thus simply use one of the built-in PostgreSQL databases, such as `template0`.

Then run the tests:

python3 setup.py test

If the tests all pass, install:

python3 setup.py install

## Usage

The installation will put a single script called `chado` in your PATH.
The usage is:

chado <command> [options]

* To list the available commands and brief descriptions, just run `chado -h` or `chado --help`.
* To display the version of the program, type `chado -v` or `chado --version`.
* Use `chado <command> -h` or `chado <command> --help` to get a detailed description and the usage of that command.

## Available commands

| Command | Description |
|-----------------------|----------------------------------------------------------------------|
| connect | connect to a CHADO database for an interactive session |
| create | create a new instance of the CHADO schema |
| dump | dump a CHADO database into an archive file |
| restore | restore a CHADO database from an archive file |
| import | import data from a text file into a table of a CHADO database |
| export | export data from a table of a CHADO database into a text file |

## Examples

Create a new database called `insects` according to the current GMOD schema:

chado create insects

Dump this database into an archive called `insects.dump`:

chado dump insects insects.dump

## Note

Unless explicitly specified by the flag `-c`, all commands employ the [default connection settings](pychado/data/defaultDatabase.yml) also used to run the tests.


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

chado-tools-0.0.4.tar.gz (10.8 kB view details)

Uploaded Source

Built Distributions

chado_tools-0.0.4-py3.6.egg (96.8 kB view details)

Uploaded Source

chado_tools-0.0.4-py3-none-any.whl (77.1 kB view details)

Uploaded Python 3

File details

Details for the file chado-tools-0.0.4.tar.gz.

File metadata

  • Download URL: chado-tools-0.0.4.tar.gz
  • Upload date:
  • Size: 10.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for chado-tools-0.0.4.tar.gz
Algorithm Hash digest
SHA256 350c40f1433cf24465cbc4550efadcf5b7fcbd19f8353e43b22d97cfef33bec9
MD5 12a11215f6418cfee16f57fde2ed065a
BLAKE2b-256 328f83f8e0d56dc2391539111fb5b268fd9c77cfe399a99b9bb6295825f66b6b

See more details on using hashes here.

File details

Details for the file chado_tools-0.0.4-py3.6.egg.

File metadata

File hashes

Hashes for chado_tools-0.0.4-py3.6.egg
Algorithm Hash digest
SHA256 2236a099cf16fde10f328e68c9cb63cbb50f74d14322f02d13ee7a761088c3c4
MD5 4a7bb9917ca1e86c5a1fbb43fa66df2f
BLAKE2b-256 51c02e76fb33645cfd366beb21f7f55708b45a3d07a3ef9bd7c3d08b192a5e4a

See more details on using hashes here.

File details

Details for the file chado_tools-0.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for chado_tools-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 1a93e50e6bb55ac2107358caddc4bc21935b4bba8f7ce96eb494657a68b18328
MD5 e57f389112ee91ea86bb91006842842e
BLAKE2b-256 8dc2a757b5b4a07e385c19963daf8fb1b214205c955a51e84c698d7a35aab39f

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page