rotifer.db.ncbi.assemblies#
- rotifer.db.ncbi.assemblies(baseurl='ftp://ftp.ncbi.nlm.nih.gov/genomes/ASSEMBLY_REPORTS', targets=['refseq', 'genbank', 'refseq_historical', 'genbank_historical'], taxonomy=True, progress=True)[source]#
Load a table documenting all NCBI genome assemblies.
By default, the concatenated assembly summary tables are downloaded from the
genomes/ASSEMBLY_REPORTSdirectory of the NCBI FTP site. A local directory containingassembly_summary_*.txtfiles may be used instead.- Parameters:
- baseurlstr, optional
URL or directory with
assembly_summary_*.txtfiles. Defaults to the NCBI FTP site named in the configuration.- targetslist of str, optional
Genome database sections to load. Options are
refseq,genbank,refseq_historicalandgenbank_historical. All four are loaded by default.- taxonomybool, default True
Whether to add taxonomy data to the table, using
TaxonomyCursor.- progressbool, default True
Display progress messages.
- Returns:
- pandas.DataFrame
One row per assembly.
Notes
Two columns are added to the original table:
source(the genome database section) andloaded_from(the URL or path each row was read from). Theftp_pathcolumn is rewritten to use theftpscheme.Examples
Download from the NCBI FTP site:
>>> from rotifer.db import ncbi >>> a = ncbi.assemblies()
Load local copies stored in
/db/ncbi:>>> b = ncbi.assemblies(baseurl="/db/ncbi")