Hi,
I've used bcftools consensus
to create fasta files from individual vcf files. However, some sites in the fasta file do not correspond to the vcf. Using the --sample
flag resolved some of these problems, but not all. For example this site
chr22 2600340 . C T 1638.22 PASS . GT:AD:DP:GQ:PL 1/1:0,9:9:27:405,27,0
should have T, but
samtools faidx 8L19766_sam_sample.fasta chr22:2600340-2600340
yield a C.
The vcf files have been called using GATKs HaplotypeCaller
. I have also attempted using GATKs FastaAlternateReferenceMaker
to create fasta files, but this made the discrepancies far worse.
What could be causing these issues?
Thanks so much for any help!
No, if the VCF indicates that the individual has the alternative allele at a certain site, as is the case here,
bcftools consensus
should place the alternative allele at that position in the fasta file. This is how it works for most of my sites, but not all.Do you have insertions or deletions in your vcf? If so, then chr22:260034 in the consensus fasta will not represent the same position in the original fasta.
Can you please give us the exact
bcftools consensus
command you're using?so, you create a consensus "patching" your reference genome? how do you generate that?
No, there are no insertions or deletions .
This is the command I use: