Converts an annotated DNA multi-sequence alignment (in NEXUS format) to an EMBL flatfile for submission to ENA via the Webin-CLI submission tool
Project description
annonex2embl
Converts an annotated DNA multi-sequence alignment (in NEXUS format) to an EMBL flatfile for submission to ENA via the Webin-CLI submission tool.
INPUT, OUTPUT AND PREREQUISITES
- Input: an annotated DNA multiple sequence alignment in NEXUS format; a comma-delimited metadata table
- Output: a submission-ready, multi-record EMBL flatfile
Requirements / Input preparation
The annotations of a NEXUS file are specified via SETS-block, which is located beneath a DATA-block and defines sets of characters in the DNA alignment. In such a SETS-block, every gene and every exon charset must be accompanied by one CDS charset. Other charsets can be defined unaccompanied.
Example of a complete SETS-BLOCK
BEGIN SETS;
CHARSET matK_gene_forward = 929-2530;
CHARSET matK_CDS_forward = 929-2530;
CHARSET trnK_intron_forward = 1-928 2531-2813;
END;
Examples of corresponding DESCR variable
DESCR="tRNA-Lys (trnK) intron, partial sequence; maturase K (matK) gene, complete sequence"
EXAMPLE USAGE
On Linux / MacOS
SCRPT=$PWD/scripts/annonex2embl_launcher_CLI.py
INPUT=examples/input/TestData1.nex
METAD=examples/input/Metadata.csv
OTPUT=examples/temp/TestData1.embl
DESCR='description of alignment' # Do not use double-quotes
EMAIL=your_email_here@yourmailserver.com
AUTHR='your name here' # Do not use double-quotes
MNFTS=PRJEB00000
MNFTD=${DESCR//[^[:alnum:]]/_}
python3 $SCRPT -n $INPUT -c $METAD -d "$DESCR" -e $EMAIL -a "$AUTHR" --productlookup True -o $OTPUT --manifeststudy $MNFTS --manifestdescr $MNFTD --compress True
On Windows
SET SCRPT=$PWD\scripts\annonex2embl_launcher_CLI.py
SET INPUT=examples\input\TestData1.nex
SET METAD=examples\input\Metadata.csv
SET OTPUT=examples\temp\TestData1.embl
SET DESCR='description of alignment'
SET EMAIL=your_email_here@yourmailserver.com
SET AUTHR='your name here'
SET MNFTS=PRJEB00000
SET MNFTD=a_unique_description_here
python %SCRPT% -n %INPUT% -c %METAD% -d %DESCR% -e %EMAIL% -a %AUTHR% --productlookup True -o %OTPUT% --manifeststudy %MNFTS% --manifestdescr %MNFTD% --compress True
INSTALLATION
First, please be sure to have Python 3 installed on your system. Then:
To get the most recent stable version of annonex2embl, run:
pip install annonex2embl
Or, alternatively, if you want to get the latest development version of annonex2embl, run:
pip install git+https://github.com/michaelgruenstaeudl/annonex2embl.git
TESTING
Regular testing
python3 setup.py test
pytest # alternative
Testing for development
To run the unittests outside of 'python setup.py test':
python3 -m unittest discover -s tests -p "*_test.py"
CHANGELOG
See CHANGELOG.md
for a list of recent changes to the software.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for annonex2embl-0.7.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 92916b39299acf8830e51e0cca94ceea25b723c7c45099e19225f8a460ba8e06 |
|
MD5 | 89c5f8bc5ffc63ba0eccf9ec4d028d1e |
|
BLAKE2b-256 | 0897b726c63a420bd10a2bdc7e9a0c4a282c104d5ea9900c5185e2effc330501 |