GithubHelp home page GithubHelp logo

alizraksi / allelecounter Goto Github PK

View Code? Open in Web Editor NEW

This project forked from secastel/allelecounter

0.0 1.0 0.0 10 KB

Counts the number of reads which map to either the reference or alternate allele at each heterozygous SNP.

Python 100.00%

allelecounter's Introduction

allelecounter

Counts the number of reads which map to either the reference or alternate allele at each heterozygous SNP. Runs on Python2.7.x and has the following dependencies: pyvcf, Samtools (1.2+), awk.

Citation

Castel, S. E., Levy-Moonshine, A., Mohammadi, P., Banks, E. & Lappalainen, T. Tools and best practices for data processing in allelic expression analysis. Genome Biol. 16, 195 (2015).

Usage

Requires a BAM, VCF, and Reference, produces read counts for each allele at each heterozygous SNP. Output is in the same format as the GATK ASEReadCounterTool for cross compatibility. If you would like to exclude duplicate reads they must first be marked using a separate tool, as this script does not mark duplicate reads itself. I suggest using Picard MarkDuplicates. If duplicate reads have been marked, this tool will discard them. Reads whose mates overlap will only be counted once. For more flexibility please consider using the GATK tool.

Arguments

  • --vcf - VCF file containing genotype for the sample. Must be gzipped and Tabix indexed. To improve runtime this file should be pre-processed to only include bi-allelic heterozygous SNPs.
  • --sample - Name of sample to use in VCF file.
  • --bam - BAM file containing reads. Duplicates should be marked, and file must be indexed with Samtools index.
  • --ref - Reference sequence in FASTA format.
  • --min_cov - Minimum coverage for a SNP before it is included in output. Minimum is 2 becuase samtools will not generate pileups for sites with only 1 read.
  • --min_baseq - Minimum base quality at the SNP required for reads to be counted.
  • --min_mapq - Mimimum mapping qualityfor reads to be counted. Note that due to limitations with Samtools mpileup the maximum value is 93. Any value higher than 93 will be set to 93.
  • --max_depth (100000) - Maximum depth to report at each heterozygous variant when calling samtools mpileup. This value must be greater than the most covered site in your data. Any sites that are covered by more reads than this depth could have false positive signals of allelic imbalance because samtools does not randomly sample reads.
  • --o - Output file name.

allelecounter's People

Contributors

secastel avatar

Watchers

Aliz Raksi 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.