rotifer.db.ncbi#
Access NCBI sequence, genome and taxonomy data.
This package is the main entry point for retrieving data from the National Center for Biotechnology Information (NCBI). The cursors defined here are delegators: each one combines several backends (Entrez E-utilities, the NCBI FTP site, local genome mirrors, local indexed FASTA files, the ETE toolkit taxonomy database and SQLite3 stores) and tries them in order until every requested identifier is resolved.
Network, authentication and rate limits#
Entrez based backends send the user email registered in the
configuration and honor the NCBI_API_KEY environment variable.
Without an API key, NCBI limits clients to 3 requests per second and
the Entrez backends restrict themselves to 3 simultaneous threads;
with a key, up to 10 threads are used. FTP backends download files
to the rotifer cache directory (rotifer.config['cache']).
Configuration#
The module level config dictionary is loaded from
~/.rotifer/etc/db/ncbi.yml when that file exists. Its keys
include the Entrez email and API key, the FTP server address, the
path of a local genome mirror and the mapping of backend names to
reader and writer modules.
Functions
|
Load a table documenting all NCBI genome assemblies. |
Classes
|
Fetch sequences from local FASTA files or NCBI, without annotations. |
|
Fetch gene neighborhoods as dataframes. |
|
Fetch annotated genome sequences. |
|
Fetch genome annotation as feature tables. |
|
Fetch identical protein group (IPG) reports. |
|
Fetch annotated sequences from NCBI. |
|
Fetch NCBI Taxonomy data as dataframes. |