Fredrik Ronquist, Jan Kudlicka, Viktor Senderov, Johannes Borgström, Nicolas Lartillot, Daniel Lundén, Lawrence Murray, Thomas B. Schön, David Broman (F.R., J.K., and V.S. contributed equally to this work)
This is the source code repository accompanying the paper.
- Preprint available at bioRxiv
- Corresponding author: Fredrik Ronquist, fredrik.ronquist (at) nrm.se
Directory | Description |
---|---|
birch |
Phylogenetic models in Birch |
data |
Phylogenetic trees used in the analysis |
R |
Auxilliary R package for testing |
webppl |
Phylogenetic models in WebPPL |
git clone http://github.com/phyppl/probabilistic-programming
To install and use the models in Birch, please download and install the Birch compiler, library, (optional) examples, and their dependencies. Installation instructions can be found on the getting started with Birch webpage. The phylogenetic models presented in this paper can then be run like regular Birch packages. Follow the Birch README in the birch
directory for detailed instructions.
To install and use the models in WebPPL, the following packages have been provided:
- phywppl main package containing the models (implemented in WebPPL)
- phyjs dependency package with shared library functions (implemented in JavaScript)
- rppl (optional) R package used in verification
An npm package phywppl
has been provided. To install it:
- Download and install Node, if it has not been installed already.
- Download and install WebPPL, if it has not been installed already.
- Download this repository (see above), if it has not been downloaded already.
- Change to the
webppl/phywppl
package directory:
cd webppl/phywwpl
- Install dependency packages
phyjs
(local) andshelljs
:
npm install ../phyjs
npm install shelljs
Now, all WebPPL programs from the paper can be run from the shell with the tools that are found in the repository. Consult the phywppl README for instructions.
An optional R package rppl
is provided, which is needed to generate the verification plots from the WebPPL source tree.
- Install R.
- From R, type
install.packages(file.choose(), repos = NULL, type = "source")
- When R prompts you to select the desired package, indicate the
rppl_1.0.0.tar.gz
package from theR
directory.
The WebPPL and Birch scripts we provide simulate diversification along observed reconstructed trees. We use a new JSON format for phylogenetic trees named PhyJSON. Supported by the resources we provide in the repository, both WebPPL and Birch have mechanisms for reading in phylogenetic trees stored in the PhyJSON format. We also provide a stand-alone tool, nexus2phyjson, which can be used to convert trees in Nexus tree files to PhyJSON format.
For convenience, we provide several built-in phylogenetic trees in the phyjs package for purposes such as testing and verification. They can be used directly, without the need to input them from a PhyJSON file.