All Projects → pgxcentre → genipe

pgxcentre / genipe

Licence: other
Genome-wide imputation pipeline

Programming Languages

python
139335 projects - #7 most used programming language
TeX
3793 projects

Projects that are alternatives of or similar to genipe

graphsim
R package: Simulate Expression data from igraph network using mvtnorm (CRAN; JOSS)
Stars: ✭ 16 (-42.86%)
Mutual labels:  genomics, genetics
manhattan generator
Manhattan plot Generator
Stars: ✭ 20 (-28.57%)
Mutual labels:  genomics, genetics
HumanIdiogramLibrary
Resource of human chromosome schematics & images
Stars: ✭ 76 (+171.43%)
Mutual labels:  genomics, genetics
fwdpy11
Forward-time simulation in Python using fwdpp
Stars: ✭ 25 (-10.71%)
Mutual labels:  genomics, genetics
dee2
Digital Expression Explorer 2 (DEE2): a repository of uniformly processed RNA-seq data
Stars: ✭ 32 (+14.29%)
Mutual labels:  genomics, genetics
region-plot
A tool to plot significant regions of GWAS
Stars: ✭ 20 (-28.57%)
Mutual labels:  genomics, genetics
awesome-genetics
A curated list of awesome bioinformatics software.
Stars: ✭ 60 (+114.29%)
Mutual labels:  genomics, genetics
HLA
xHLA: Fast and accurate HLA typing from short read sequence data
Stars: ✭ 84 (+200%)
Mutual labels:  genomics
cellrank
CellRank for directed single-cell fate mapping
Stars: ✭ 222 (+692.86%)
Mutual labels:  genetics
cljam
A DNA Sequence Alignment/Map (SAM) library for Clojure
Stars: ✭ 85 (+203.57%)
Mutual labels:  genomics
Canvasxpress
JavaScript VisualizationTools
Stars: ✭ 247 (+782.14%)
Mutual labels:  genomics
Mitty
Seven Bridges Genomics aligner/caller debugging and analysis tools
Stars: ✭ 13 (-53.57%)
Mutual labels:  genomics
cerebra
A tool for fast and accurate summarizing of variant calling format (VCF) files
Stars: ✭ 55 (+96.43%)
Mutual labels:  genomics
fermi
A WGS de novo assembler based on the FMD-index for large genomes
Stars: ✭ 74 (+164.29%)
Mutual labels:  genomics
assigner
Population assignment analysis using R
Stars: ✭ 17 (-39.29%)
Mutual labels:  genomics
Hap.py
Haplotype VCF comparison tools
Stars: ✭ 249 (+789.29%)
Mutual labels:  genomics
viGEN
viGEN - A bioinformatics pipeline for the exploration of viral RNA in human NGS data
Stars: ✭ 24 (-14.29%)
Mutual labels:  genomics
sequencework
programs and scripts, mainly python, for analyses related to nucleic or protein sequences
Stars: ✭ 22 (-21.43%)
Mutual labels:  genomics
GenomicsDB
Highly performant data storage in C++ for importing, querying and transforming variant data with C/C++/Java/Spark bindings. Used in gatk4.
Stars: ✭ 77 (+175%)
Mutual labels:  genomics
Synopsys-Project-2017
A deep learning based bioinformatics project on epigenetics in Type 2 Diabetes.
Stars: ✭ 14 (-50%)
Mutual labels:  genetics

Build Status PyPI version

genipe - A Python module to perform genome-wide imputation analysis

The genipe module (standing for GENome-wide Imputation PipelinE) includes a script (named genipe-launcher) that automatically runs a genome-wide imputation pipeline using Plink, shapeit and impute2.

If you use genipe in any published work, please cite the paper describing the tool:

Lemieux Perreault LP, Legault MA, Asselin G, Dubé MP: genipe: an automated genome-wide imputation pipeline with automatic reporting and statistical tools. Bioinformatics 2016, 32 (23): 3661-3663 (DOI:10.1093/bioinformatics/btw487).

Documentation

Full documentation is available at http://pgxcentre.github.io/genipe/.

Installation

Version 1.5.0 of genipe should work with the most recent versions of the packages.

We recommend installing the package in a Python 3.7 (or latest) virtual environment. There are two ways to install: pip or conda.

# Using pip
pip install genipe
# Using conda
conda install genipe -c http://statgen.org/wp-content/uploads/Softwares/genipe

The installation process should install all required dependencies to run the main imputation pipeline. Optional dependencies can also be installed manually in order to perform statistical analysis and data management (see below).

The complete installation procedure is available in the documentation.

Dependencies

The tool requires a standard Python 3.4 (or latest) installation with the following modules:

  • numpy version 1.11.3 and latest
  • Jinja2 version 2.9 and latest
  • pandas version 0.19.2 and latest
  • setuptools version 12.0.5 and latest

The tool requires the binaries for Plink, shapeit and impute2.

Optional dependencies

In order to perform data management and statistical analysis (linear, logistic and Cox's regressions), genipe requires the following Python modules:

  • Matplotlib
  • scipy
  • patsy
  • statsmodels
  • lifelines
  • Biopython
  • pyfaidx
  • drmaa
  • pyplink

Note that statsmodels (specifically MixedLM analysis) version 0.6 is not compatible with numpy version 1.12 and latest.

Finally, the tool requires a LaTeX installation to compile the automatically generated report in PDF format.

Testing

Basic testing was implemented for the script to merge impute2 files resulting from different segments of the same chromosome along with some utility functions of the main package. To test the package (once installed), launch Python and execute the following command:

>>> import genipe
>>> genipe.test()

Some functionalities are difficult to test, since they mostly use external tools to perform analysis (i.e. Plink, shapeit and impute2) and it is assumed that they were properly tested by their author.

We will try to add further tests in the future.

Basic usage

The following options are available when launching a genome-wide imputation analysis.

$ genipe-launcher --help
usage: genipe-launcher [-h] [-v] [--debug] [--thread THREAD] --bfile PREFIX
                       [--reference FILE] [--chrom CHROM [CHROM ...]]
                       [--output-dir DIR] [--bgzip] [--use-drmaa]
                       [--drmaa-config FILE] [--preamble FILE]
                       [--shapeit-bin BINARY] [--shapeit-thread INT]
                       [--shapeit-extra OPTIONS] [--plink-bin BINARY]
                       [--hap-template TEMPLATE] [--legend-template TEMPLATE]
                       [--map-template TEMPLATE] --sample-file FILE
                       [--hap-nonPAR FILE] [--hap-PAR1 FILE] [--hap-PAR2 FILE]
                       [--legend-nonPAR FILE] [--legend-PAR1 FILE]
                       [--legend-PAR2 FILE] [--map-nonPAR FILE]
                       [--map-PAR1 FILE] [--map-PAR2 FILE]
                       [--impute2-bin BINARY] [--segment-length BP]
                       [--filtering-rules RULE [RULE ...]]
                       [--impute2-extra OPTIONS] [--probability FLOAT]
                       [--completion FLOAT] [--info FLOAT]
                       [--report-number NB] [--report-title TITLE]
                       [--report-author AUTHOR]
                       [--report-background BACKGROUND]

Execute the genome-wide imputation pipeline. This script is part of the
'genipe' package, version 1.4.2.

optional arguments:
  -h, --help            show this help message and exit
  -v, --version         show program's version number and exit
  --debug               set the logging level to debug
  --thread THREAD       number of threads [1]

Input Options:
  --bfile PREFIX        The prefix of the binary pedfiles (input data).
  --reference FILE      The human reference to perform an initial strand check
                        (useful for genotyped markers not in the IMPUTE2
                        reference files) (optional).

Output Options:
  --chrom CHROM [CHROM ...]
                        The chromosomes to process. It is possible to write
                        'autosomes' to process all the autosomes (from
                        chromosome 1 to 22, inclusively).
  --output-dir DIR      The name of the output directory. [genipe]
  --bgzip               Use bgzip to compress the impute2 files.

HPC Options:
  --use-drmaa           Launch tasks using DRMAA.
  --drmaa-config FILE   The configuration file for tasks (use this option when
                        launching tasks using DRMAA). This file should
                        describe the walltime and the number of
                        nodes/processors to use for each task.
  --preamble FILE       This option should be used when using DRMAA on a HPC
                        to load required module and set environment variables.
                        The content of the file will be added between the
                        'shebang' line and the tool command.

SHAPEIT Options:
  --shapeit-bin BINARY  The SHAPEIT binary if it's not in the path.
  --shapeit-thread INT  The number of thread for phasing. [1]
  --shapeit-extra OPTIONS
                        SHAPEIT extra parameters. Put extra parameters between
                        single or normal quotes (e.g. --shapeit-extra '--
                        states 100 --window 2').

Plink Options:
  --plink-bin BINARY    The Plink binary if it's not in the path.

IMPUTE2 Autosomal Reference:
  --hap-template TEMPLATE
                        The template for IMPUTE2's haplotype files (replace
                        the chromosome number by '{chrom}', e.g.
                        '1000GP_Phase3_chr{chrom}.hap.gz').
  --legend-template TEMPLATE
                        The template for IMPUTE2's legend files (replace the
                        chromosome number by '{chrom}', e.g.
                        '1000GP_Phase3_chr{chrom}.legend.gz').
  --map-template TEMPLATE
                        The template for IMPUTE2's map files (replace the
                        chromosome number by '{chrom}', e.g.
                        'genetic_map_chr{chrom}_combined_b37.txt').
  --sample-file FILE    The name of IMPUTE2's sample file.

IMPUTE2 Chromosome X Reference:
  --hap-nonPAR FILE     The IMPUTE2's haplotype file for the non-
                        pseudoautosomal region of chromosome 23.
  --hap-PAR1 FILE       The IMPUTE2's haplotype file for the first
                        pseudoautosomal region of chromosome 23.
  --hap-PAR2 FILE       The IMPUTE2's haplotype file for the second
                        pseudoautosomal region of chromosome 23.
  --legend-nonPAR FILE  The IMPUTE2's legend file for the non-pseudoautosomal
                        region of chromosome 23.
  --legend-PAR1 FILE    The IMPUTE2's legend file for the first
                        pseudoautosomal region of chromosome 23.
  --legend-PAR2 FILE    The IMPUTE2's legend file for the second
                        pseudoautosomal region of chromosome 23.
  --map-nonPAR FILE     The IMPUTE2's map file for the non-pseudoautosomal
                        region of chromosome 23.
  --map-PAR1 FILE       The IMPUTE2's map file for the first pseudoautosomal
                        region of chromosome 23.
  --map-PAR2 FILE       The IMPUTE2's map file for the second pseudoautosomal
                        region of chromosome 23.

IMPUTE2 Options:
  --impute2-bin BINARY  The IMPUTE2 binary if it's not in the path.
  --segment-length BP   The length of a single segment for imputation. [5e+06]
  --filtering-rules RULE [RULE ...]
                        IMPUTE2 filtering rules (optional).
  --impute2-extra OPTIONS
                        IMPUTE2 extra parameters. Put the extra parameters
                        between single or normal quotes (e.g. --impute2-extra
                        '-buffer 250 -Ne 20000').

IMPUTE2 Merger Options:
  --probability FLOAT   The probability threshold for no calls. [<0.9]
  --completion FLOAT    The completion rate threshold for site exclusion.
                        [<0.98]
  --info FLOAT          The measure of the observed statistical information
                        associated with the allele frequency estimate
                        threshold for site exclusion. [<0.00]

Automatic Report Options:
  --report-number NB    The report number. [genipe automatic report]
  --report-title TITLE  The report title. [genipe: Automatic genome-wide
                        imputation]
  --report-author AUTHOR
                        The report author. [Automatically generated by genipe]
  --report-background BACKGROUND
                        The report background section (can either be a string
                        or a file containing the background. [General
                        background]

Real life example

The documentation provides a quick and easy tutorial for the complete pipeline. Refer to this page

Automatic report

The pipeline provides a report containing relevant imputation statistics. This report is located in the report directory. It can be compiled into a PDF file using the following make command:

$ make && make clean
...

This report uses LaTeX and the *.tex file can be modified to add project specific information.

Statistical analysis

Once the genome-wide imputation analysis is performed and the quality metrics provided by the automatic report have been reviewed, it is possible to perform different statistical analyses (e.g. linear or logistic regression, or survival analysis using Cox's proportional hazard model) using the provided script named imputed-stats.

$ imputed-stats --help
usage: imputed-stats [-h] [-v] {cox,linear,logistic,mixedlm,skat} ...

Performs statistical analysis on imputed data (either SKAT analysis, or
linear, logistic or survival regression). This script is part of the 'genipe'
package, version 1.4.2.

optional arguments:
  -h, --help            show this help message and exit
  -v, --version         show program's version number and exit

Statistical Analysis Type:
  The type of statistical analysis to be performed on the imputed data.

  {cox,linear,logistic,mixedlm,skat}
    cox                 Cox's proportional hazard model (survival regression).
    linear              Linear regression (ordinary least squares).
    logistic            Logistic regression (GLM with binomial distribution).
    mixedlm             Linear mixed effect model (random intercept).
    skat                SKAT analysis.

See the tutorials for more information: http://pgxcentre.github.io/genipe/tutorials.html

About

This project was initiated at the Beaulieu-Saucier Pharmacogenomics Centre of the Montreal Heart Institute. The aim was to speed up (and automatize) the imputation process for the whole genome.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].