TruSD co-infers selection coefficients and genetic drift from allele trajectories using a maximum-likelihood framework.
Project description
TruSD
Trajectories under Selection and Drift is an implementation of a method that co-infers selection coefficients and genetic drift from allele trajectories using a maximum-likelihood framework.
If you find the software useful in your research please cite this package.
Installation
TruSD needs Python 3.6 or newer. Python 2 is not supported! TruSD was only tested on Linux (Ubuntu), but should work on Mac and Windows as well.
We suggest to use a virtual environment for use of TruSD. To install TruSD, run:
pip3 install trusd # add --user to install only for the user
This will install TruSD as importable module and three command line tools,
trusd
, trusd-plot
, and trusd-sim
.
Update
If you later want to update TruSD, use the pip command:
pip3 install --upgrade trusd
Running TruSD from within a Python script
Import the trusd
module from your Python 3 script:
# inside python3 script or interactive prompt
import trusd
help(trusd.trusd) # gives package content
For an example, download two files (for example with wget
):
wget https://github.com/mathiasbockwoldt/TruSD/blob/master/examples/min_working_example.py
wget https://github.com/mathiasbockwoldt/TruSD/blob/master/examples/traj_example.txt
You can start an example run with
python3 min_working_example.py
The min_working_example.py
is documented to explain the basic steps.
It uses traj_example.txt
as input and produces outfile.txt
(the results),
outfile.json
(the metadata) and outfile.pdf
(the plot).
Running TruSD as command line program
The command line programs are self-explanatory using the --help
flag.
trusd --help
trusd-plot --help
trusd-sim --help
The parameters are the same as in the Python modules.
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
File details
Details for the file TruSD-0.0.5.tar.gz
.
File metadata
- Download URL: TruSD-0.0.5.tar.gz
- Upload date:
- Size: 12.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 532a973b6a943e835898d28e674244028eff11689ce5bff2c40761fbcee85f0b |
|
MD5 | d7213223627c1311fd010d41f7282677 |
|
BLAKE2b-256 | 0868d89336f8200fa0fa429afd5206a4c15c228920fefeeaffe74b3316d242c6 |
File details
Details for the file TruSD-0.0.5-py3-none-any.whl
.
File metadata
- Download URL: TruSD-0.0.5-py3-none-any.whl
- Upload date:
- Size: 14.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.1 pkginfo/1.8.2 requests/2.22.0 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 26cd85ccff5b6cd71179b7c6cb41bfbfe5478106ddd999e9eeb346098887ba49 |
|
MD5 | 81e5e87399fb425e8bf16c91e1246318 |
|
BLAKE2b-256 | d1ee70aa508d56a16e0ebcee111a4b46feadbcad929c58fe621122456ec2320b |