This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Convert gVCF into BED

Project Description

This is a small tool to convert a gVCF file to BED. This is useful for extracting regions that pass a certain genotype quality threshold.

Installation

gvcf2bed is now available through pypi with: pip install gvcf2bed

Requirements

  • Python 3.4+
  • pyvcf
  • cyvcf2

For developers

  • pytest
  • pytest-cov

Changelog

0.3

  • Use cyvcf2 by default in tool. This results in a speed-up of approximately 8-10x. Existing API has not changed, and will still work with pyvcf.
  • Add separate filter for non-variants, as GQ scores may have a different distribution on non-variant records than on variant records.

Usage

usage: gvcf2bed [-h] -I INPUT -O OUTPUT [-s SAMPLE] [-q QUALITY]
                [-nq NON_VARIANT_QUALITY] [-b]

Create a BED file from a gVCF. Regions are based on a minimum genotype
quality. The gVCF file must contain a GQ field in its FORMAT fields. GQ scores
of non-variants records have a different distribution from the GQ score
distribution of variant records. Hence, an option is provided to set a
different threshold for non-variant positions.

optional arguments:
  -h, --help            show this help message and exit
  -I INPUT, --input INPUT
                        Input gVCF
  -O OUTPUT, --output OUTPUT
                        Output bed file
  -s SAMPLE, --sample SAMPLE
                        Sample name in VCF file to use. Will default to first
                        sample (alphabetically) if not supplied
  -q QUALITY, --quality QUALITY
                        Minimum genotype quality (default 20)
  -nq NON_VARIANT_QUALITY, --non-variant-quality NON_VARIANT_QUALITY
                        Minimum genotype quality for non-variant records
                        (default 20)
  -b, --bedgraph        Output in bedgraph mode
Release History

Release History

This version
History Node

0.3

History Node

0.2

History Node

0.1.1

History Node

0.1

Download Files

Download Files

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

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
gvcf2bed-0.3-py3-none-any.whl (5.9 kB) Copy SHA256 Checksum SHA256 py3 Wheel Jun 8, 2017
gvcf2bed-0.3.tar.gz (5.0 kB) Copy SHA256 Checksum SHA256 Source Jun 8, 2017

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting