rotifer.db.sql.sqlite3.IPGCursor#
- class rotifer.db.sql.sqlite3.IPGCursor(path, replace=False, identical='c100', identical_column='c100i100', *args, **kwargs)[source]#
Bases:
SequenceCursor,BaseSQLite3CursorFetch identical protein group (IPG) reports from a local SQLite3 database.
Depending on
identical, results are built either from a precomputed non-redundant clustering table (nr) or directly from thefeaturestable.- Parameters:
- pathstr
Path to a local SQLite3 database.
- replacebool, default False
If True, overwrite the database file.
- identicalstr or None, default ‘c100’
Name of the clustering column used to group identical proteins. If None, IPGs are derived from
featuresalone.- identical_columnstr, default ‘c100i100’
Column added to the report identifying the cluster representative.
See also
rotifer.db.sql.sqlite3.GeneNeighborhoodCursorgene neighborhood cursor
rotifer.db.ncbi.entrez.IPGCursorequivalent cursor backed by NCBI Entrez
Examples
>>> from rotifer.db.sql import sqlite3 as rdss >>> ic = rdss.IPGCursor("genomes.sqlite3") >>> df = ic.fetchall("YP_009724395.1")
- __getitem__(accessions)[source]#
Fetch identical protein group reports, dictionary style.
- Parameters:
- accessionsstr or iterable of str
Database identifiers.
- Returns:
- pandas.DataFrame
Columns as listed in
self._columnsplusself._added_columns. Empty if the SQL file for the selectedidenticalmode could not be found.