Skip to main content

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.

Release files for TruSD 0.0.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for TruSD 0.0.6
File Size Uploaded
TruSD-0.0.6.tar.gz 13.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for TruSD 0.0.6
File Interpreter ABI Platform
TruSD-0.0.6-py3-none-any.whl Python 3 none any Details

Total release size: 29.2 kB

Release files / TruSD-0.0.6.tar.gz

Download URL TruSD-0.0.6.tar.gz
Size 13.2 kB
Tags Source
SHA-256 checksum
How to use checksums
c820116cb5d0515dfa9bc8367255bc0424a70be358b4542c400e79813f13e08f
BLAKE2b-256 checksum
How to use checksums
e5b2f646673549d29d34dbaf43190160e0d8a21e3cb1995e21ebe3686930d216
Upload date
Uploaded using Trusted Publishing?
What is 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

Release files / TruSD-0.0.6-py3-none-any.whl

Download URL TruSD-0.0.6-py3-none-any.whl
Size 15.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
345a7e93deb9ea00a06e848171ab9f52e913b0cf573b8ad954606e562081a02f
BLAKE2b-256 checksum
How to use checksums
558ca276d5b63b8b171243f900557e9a9aa474b252da3dd093a4fa4240d85061
Upload date
Uploaded using Trusted Publishing?
What is 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

Release history Release notifications | RSS feed

This release

0.0.6 This release

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page