Skip to main content

No project description provided

Project description

ExP Selection

LCT gene

Requirements

  • python >= 3.8
  • vcftools (repository)
  • space on disk (.vcf files are usually quite large)

Install

pip install exp-selection

Usage

Get data

Extract only SNP

You can give an .vcf or .vcf.gz file

# Gziped VCF
vcftools --gzvcf DATA.vcf.gz --remove-indels --recode --recode-INFO-all --out DATA.recode.vcf

# Plan VCF
vcftools --vcf DATA.vcf --remove-indels --recode --recode-INFO-all --out DATA.recode.vcf

Prepare data for computing

# DATA.recode.vcf a vcf from previous step
# DATA.zarr is path where zarr will be saved
exp-selection prepare DATA.recode.vcf DATA.zarr

Compute

# DATA.zarr a zarr data from previous step
# DATA.xpehh a path where xpehh will be saved
exp-selection compute DATA.zarr genotypes.panel DATA.xpehh

Plot graph

  • --begin, --end (required)
    • plot boundaries
  • --title (optional)
    • name of the image
  • --cmap (optional)
  • --output (optional)
    • png output path
bin/plot FILE.recode.xpehh --begin BEING --end END --title TITLE
# => TITLE.png

Example

# Download datasets
wget "ftp.1000genomes.ebi.ac.uk/vol1/ftp/release/20130502/supporting/GRCh38_positions/ALL.chr22_GRCh38.genotypes.20170504.vcf.gz" -O chr22.genotypes.vcf.gz
wget "ftp.1000genomes.ebi.ac.uk/vol1/ftp/release/20130502/integrated_call_samples_v3.20130502.ALL.panel" -O genotypes.panel


# Compute files for graph
vcftools --gzvcf chr22.genotypes.vcf.gz \
         --remove-indels \
         --recode \
         --recode-INFO-all \
         --out chr22.genotypes.recode.vcf

exp-selection prepare chr22.genotypes.recode.vcf
exp-selection compute chr22.genotypes.recode.zarr genotypes.panel

# Plot heatmap
exp-selection plot chr22.genotypes.recode.xpehh --begin 50481556 --end 50486440 --title ADM2 --output adm2

# A heatmap is saved at adm2.png

Contributors

Acknowledgement



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

exp-selection-1.0.0.tar.gz (10.8 kB view hashes)

Uploaded Source

Built Distribution

exp_selection-1.0.0-py3-none-any.whl (11.7 kB view hashes)

Uploaded Python 3

Supported by

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