Skip to main content

A python pipeline for implementing smcpp package to decipher demographic history of populations

Project description

SMCPP_pipeline

A python pipeline for implementing smcpp to decipher demographic history of populations of interest

All the functions assume that the user has generated population population-specific chromosome file and stored it in a directory popname_vcf present in the current working directory. all the chromosome files should be bgzipped and tabix indexed.

If the user has a single genotype file, then user can make use of bcftools script provided here to generate population-specific bgzipped and tabix index VCFs.

from smcpp_pipeline import vcf2smc,estimate,plot

1) Function to convert vcf file to smc format
  def vcf2smc(popfile,chromosome_info,gaps_bed,num_workers):
2) Function to estimate the demographic history of a single population
   def estimate(popfile,mu = 1.25e-8,spline = "piecewise",start_time = 100, end_time=100000,knots = 8):
3) Function to generate plots from the model.json file obtained using estimate function
   def plot(popfile,time_start=100,time_end=15000):

popfile should be a tab separated file containing two columns

sample.id  population
i1          pop1
i2          pop1
i3          pop2  

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

smcpp_pipeline-0.1.0.tar.gz (2.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

smcpp_pipeline-0.1.0-py3-none-any.whl (2.6 kB view details)

Uploaded Python 3

File details

Details for the file smcpp_pipeline-0.1.0.tar.gz.

File metadata

  • Download URL: smcpp_pipeline-0.1.0.tar.gz
  • Upload date:
  • Size: 2.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.9.18

File hashes

Hashes for smcpp_pipeline-0.1.0.tar.gz
Algorithm Hash digest
SHA256 35d8b562a91311d76dbe739c3f57e76d5b652a2a613b5ac39e999ec015ad9265
MD5 5ffb5fef631549c4fe2b9f9092ff95d0
BLAKE2b-256 114d96e7f3d3df0a3b91077d8ad2f3f497d08174b8c92806dc204aa2c435d653

See more details on using hashes here.

File details

Details for the file smcpp_pipeline-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: smcpp_pipeline-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 2.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.9.18

File hashes

Hashes for smcpp_pipeline-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ade74693bfdd57556cff118b5287dfb1d49821efd15273967ddb648733dae8e0
MD5 c44e77426c54644eaf1cf82fed87e035
BLAKE2b-256 4196faa3b749d896e32ec3ee9842f9d2da1a48d0b5e1cc02bf28696ff02f8cb1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page