Skip to content

Latest commit

 

History

History
26 lines (21 loc) · 1.4 KB

README.md

File metadata and controls

26 lines (21 loc) · 1.4 KB

vcf-stats

A port of BCFtools's "plot-vcfstats"

What this is:

This is basically a Python port of the plot-vcfstats utility included in BCFtools. It's used to visualize the output of wthe bcftools stats command. The original utility is a Perl script that wrote out a Python script to generate the figures with Matplotlib and then a LaTeX document to combine them all in a PDF.

Currently the script vcf_stats_tools.py is as close of a copy to the Perl original as I can get, including writing out a separate Python file and a LaTeX file.

What this isn't:

It isn't pretty, that's for sure. Right now it's pretty Perl-ish and not idiomatic Python at all. It's been tested on several different types of VCFs, but is still experimental.

What this hopefully will become

I'm hoping to turn this into a whole host of tools to work with VCF stats generated by bcftools stats. That will include plotting, but also other analyses of the output. I might even try creating a pure-Python version of bcftools stats so that it can be run on any platform (BCFtools doesn't work on Windows very well).

Here's some of the improvements I have in mind:

  • Make everything more Pythonic (especially fixing up the data structures)
  • Include all the Python code in one file so it doesn't have to write out a second file
  • Use ReportLab to make the PDF
  • Add option for a formatted HTML report