/Predict-Genomic-Resolution-of-BSA

This repository stores the codes that run SLiM simulations and plot the graphs for the paper that derives the analytical solution for genomic resolution of Bulk Segregant Analysis (BSA).

Primary LanguageJupyter Notebook

Predicting Genomic Resolution of BSA

This repository stores the codes that run SLiM simulations and plot the graphs for the paper that predicts the genomic resolution of Bulk Segregant Analysis (BSA).

predict_bsa_resolution.py is the python script that can be used to calculate the expected genomic resolution of a BSA experiment based on the analytical solutions derived in our paper. No additional python package is needed to run the script. The python script takes five arguments in order: the estimated effective population size Ne, the length of the experiment t, the average recombination rate r, the sample size for genome sequencing s and the analytical model used for the calculation integration or recursion. An example is shown below:

python predict_bsa_resolution.py 100 10 1e-8 20 integration uses the integration model to calculate the expected genomic resolution of a BSA experiment with Ne=100, running from F0 to F10, an estimated recombination probablity of 1e-8 and sampling a total of 20 diploid individuals for genome sequencing. The output of running the script would be:

Expected Genomic Resolution of BSA Experiment with Ne=100, Gen=10, R=1.000e-08, s=20 using integration model is: 7.149e+05 bp.