Skip to content

Simulator to approximate the allele age probability distribution for a Wright-Fisher model

Notifications You must be signed in to change notification settings

dekoning-lab/allele_age_simulator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Allele age simulator

This is a simulator of a reversed absorbing Markov process that can be used to approximate the probability distribution of allele ages.

The process of interest is a Wright-Fisher model with mutation, selection and dominance, where the starting allele number is 1, and the observed allele frequency is x.

The simulator first creates a reversed process for the given chain, and then simulates from it.

The reversed absorbing Markov process is implemented according to Chae and Kim, 1994

Dependencies

This project depends on armadillo, gsl, and openmp.

Installation

With the dependencies installed:

mkdir build && cd build
cmake ..
make

./allele_age_simulator --help

Mac OS notes

This code was tested with GCC, since it fully supports OpenMP. Therefore, it is necessary to export the paths to the GCC executables before running cmake.

mkdir build && cd build

brew install gcc openmp armadillo gsl

export CC=/usr/local/bin/gcc-6
export CXX=/usr/local/bin/g++-6

cmake ..
make

Linux notes

This code was tested against linuxbrew installation. Therefore, with linuxbrew in place, the compilation process should be the same as Mac OS.

About

Simulator to approximate the allele age probability distribution for a Wright-Fisher model

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published