Skip to main content

BCFTools

BCFTools is a suit of utilities that manipulate variant calls in the Variant Call Format (VCF) and its binary counterpart BCF. The tool is designed for handling data streams and as such treats input / output files as stdin and stdout. Therefore when passing multiple files they must be properly indexed and compressed.

This suit consists of the following commands:

CommandDescription
annotateadd or remove annotations of a VCF
callSNP/indel calling
cnvCopy number variation caller
concatconcatenate VCF/BCF files from the same set of samples
consensuscreate a consensus sequence by applying VCF variants
convertconvert VCF to BCF and vise versa
csqhaplotype aware consequence caller
filterfilter VCF/BCF files using fixed thresholds
gtcheckcheck sample concordance, detect sample swaps and contamination
headview file headers
indexindex files
isecintersections of files
mergemerge files from non-overlapping sample sets
mpileupmulti-way pileup producing genotype likelihoods
normnormalize indels
pluginrun user-defined plugin
polysomydetect contaminations and whole-chromosome aberrations
querytransform files into user-defined formats
reheadermodify header and change sample names
rohidentify runs of homo/auto-zygosity utilizing a HMM.
sortsort files
statsproduce stats and can be visualized with plot-vcfstats
viewsubset, filter, and convert files

Two additional scripts are bundled with bcftools and they are gff2gff and plot-vcfstats. gff2gff converts a GFF file to the format required by csq while plot-vcfstats plots the output of stats.

For additional information please see the documentation

ml biocontainers bcftools
bcftools stats -s <stdin> > file.vchk
plot-vcfstats -p outdir file.vchk
cat in.gff.gz | gff2gff | gzip -c > out.gff.gz

Parallel Capabilities: Single core only.