Giter Site home page Giter Site logo

longshot2's Introduction

Introduction

This repository contains Longshot2 (implemented in python) that implements a two-pass approach to variant calling (both SNVs and short indels) for long reads. Longshot2 uses a C++ implementation of the POA algorithm (https://github.com/rvaser/spoa) and the Longshot tool (github.com/pjedge/longshot). Longshot2 also allows for runningthe variant calling in parallel resulting in significant speed-up.

Longshot is a variant calling tool for diploid genomes using long error prone reads such as Pacific Biosciences (PacBio) SMRT and Oxford Nanopore Technologies (ONT) available from https://github.com/pjedge/longshot

Algorithm overview

  1. In the first pass, SNVs are called using Longshot and reads are separated by haplotype
  2. POA-based consensus algorithm is applied to the haplotype-separated reads to identify variants (both SNVs and indels)
  3. POA-based variants are merged with the SNVs from step (1) using bcftools
  4. The merged set of variants are used as input for a second run of Longshot

Installation

  1. Download and compile the python wrapper for C++ spoa library:
git clone https://github.com/vibansal/spoa_python.git
cd spoa_python
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release ..
make
cd ..
python3.x setup.py build_ext --inplace
cd ..
cp -r spoa_python/spoa .
  1. Install longshot (https://github.com/pjedge/longshot)

  2. Install other dependencies: bgzip, tabix, bcftools

  3. edit the config.txt to change the path to longshot and bcftools

Usage

python3.6 longshot2.py [args]

The python program expects the same arguments as used for longshot. If the "--region" option is not provided, all chromosomes/contigs are processed separately and the VCF files are merged.

Example command:

python3.6 longshot2.py --bam HG002.longreads.bam --region chr20 --ref GRCh38.fasta  --out HG002.chr20.longshot2.vcf 

longshot2's People

Contributors

vibansal avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.