gbk_features_to_df()
Make a table of one kind of feature of GenBank files read with read_gbk.
Usage
python
from geneviewer import gbk_features_to_df
gbk_features_to_df(gbk_list, feature='CDS', keys=None, process_region=True)Arguments
| Argument | Type | Description |
|---|---|---|
gbk_list | dict | From read_gbk. |
feature | str, default "CDS" | The feature key. |
keys | sequence of str, optional | The qualifiers to keep, e.g. ["protein_id", "region"]; by default all of them. |
process_region | bool, default True | Whether to add strand ("complement" or "forward"), start and end from region. start and end are the full span of the location, also of spliced genes listed from right to left. |
Value
pandas.DataFrame: One row per feature, with cluster, the file's name. Qualifier names are made syntactic as in R (function becomes function., db-xref becomes db.xref). Rows and columns that are all missing are left out.
