BCFtools is a set of utilities for variant calling and manipulating VCFs and BCFs.
Samtools and BCFtools both use HTSlib internally, but these source packages contain their own copies of htslib so they can be built independently.
Documentation
Slurm script
Using the package under srun
. A batch script can also be used.
$ module load load bcftools $ bcftools view roh.1.vcf.gz ##fileformat=VCFv4.2 ##FILTER= ##reference=test ##contig= ##FORMAT= ##bcftools_viewVersion=1.10.2-14-g70c2e5a-dirty+htslib-1.10.2-12-gd807564 ##bcftools_viewCommand=view -t 1:1e8-2e8 test.vcf.gz; Date=Tue Jan 28 14:12:43 2020 ##bcftools_viewVersion=1.21+htslib-1.21 ##bcftools_viewCommand=view /mnt/nasapps/development/nasapps/bcftools-1.21/test/roh.1.vcf.gz; Date=Thu Mar 6 13:07:01 2025 #CHROM POS ID REF ALT QUAL FILTER INFO FORMAT sample 1 100152183 . C T . PASS . GT 0/1 1 100152206 . T C . PASS . GT 0/1 1 100154233 . T C . PASS . GT 0/1 1 100154467 . G A . PASS . GT 0/1 1 100154643 . C T . PASS . GT 0/1 ...
Build instructions for those who are curious
$ git clone https://github.com/samtools/bcftools.git $ cd bcftools $ ./configure --prefix=/mnt/nasapps/production/bcftools/1.21 --enable-perl-filters --enable-libgsl --enable-configure-htslib $ make -j8 && make test-all && make install