BCFTOOLS CSQ

Predict functional consequences of variants using genome annotation

BCFTOOLS CSQ

Function

bcftools csq predicts functional consequences of variants using a reference genome and gene annotation (GFF/GTF). It is haplotype-aware and annotates variants with effects such as missense, synonymous, frameshift, and stop gained.


Input Format

  • VCF / BCF file (.vcf, .vcf.gz, .bcf)
  • GFF3 / GTF annotation file
  • Reference FASTA genome
  • All files must match coordinate system

Output Format

  • Annotated VCF (.vcf.gz)
  • BCF output (.bcf)
  • INFO field: BCSQ annotations

Applications

  • Variant functional annotation
  • Gene and transcript-level analysis
  • Missense / synonymous classification
  • Frameshift and stop-gain detection
  • Haplotype-aware consequence prediction

Example Usage

bcftools csq -f genome.fa -g genes.gff3 input.vcf.gz -Oz -o output.vcf.gz
bcftools csq -r chr1:1000000-2000000 -f genome.fa -g genes.gff3 input.vcf.gz -Oz -o region.vcf.gz
bcftools query -f '%CHROM\t%POS\t%REF\t%ALT\t%INFO/BCSQ\n' output.vcf.gz

Important Notes:
  • FASTA and GFF must use same chromosome naming.
  • GFF3 format is required (GTF may need conversion).
  • Haplotype-aware annotation improves accuracy.
  • Unphased data is still supported but less precise.