No project description provided
Project description
online-BEAST
This command line tool can be used to add sequences to an ongoing analysis in BEAST2 analysis. This framework is called online Bayesian phylodynamic inference (see Gill et al., 2020).
Install
Install online-beast
with pip (requires python -V >= 3.6.2).
pip install online-beast
Usage
Give online-beast
beast the path to a xml file from an previous BEAST run (i.e. one that have been stopped/killed/crashed) and a fasta of sequence to add to the analysis. Sequences in the fasta file must be aligned and the same length as the other sequences in the XML file. Only new sequences (new descriptors) will be added to the analysis, so new sequences can be append to the fasta file as they are acquired.
online-beast data/testGTR.xml data/samples.fasta
The new sequences will by added to the XML file and the associated .state
file (produced automatically by BEAST2).
The analysis can then be resumed (with the additional sequence data) using the BEAST2 resume flag.
beast -resume testGTR.xml
The online analysis can be visualised using Beastiary. The jumps in the trace show where new sequences have been added.
By default the new sequences will be appended to the input XML and Sate files. Output file names can be specified using the --output
flag. This will also create a new .state
file.
online-beast testGTR.xml samples.fasta --output new_testGTR.xml
If you use the BEAST2 -statefile
flag to specify the filename of the state (i.e. it is not xml_filename + .state
). Use the flag --state-file
to specify the state file path.
online-beast testGTR.xml samples.fasta --state-file beast.state
Explanation
Online-beast loosely follows the implementation of Gill et al., 2020 for BEAST1. However, most of the implementation of online-beast is handle by the default state system in BEAST2. Sequences are added to the latest tree in the state file. New sequences are added from the fasta file one at a time. The pairwise distance is calculated between the new sequence and all the other sequences in the XML file. The new sequence is grafted onto the tree in the .state
file half way along the branch of the closest sequence in the XML file. The new sequence is append to the BEAST XML file.
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 online_beast-0.3.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e2b3c009ca01f5485c9448845089a553d735a10a3928ca1dc2400e7a7f491513 |
|
MD5 | 9a28082ceff9380fe10dffb3b880c04e |
|
BLAKE2b-256 | 0998edbf2ce2e43dc1e6fc93c4bf8668e02268b7f9764a483bad07f289abe528 |