allele count in bam files
1
0
Entering edit mode
5.8 years ago

Hi! I'm trying to get the allele count for some snps in my bam files.

The variant calling was done by haplotypeCaller. The allele count in the output doesn't represent the real number of reads I have in my bam file, whitch is what I want.

I tried with bcftools mpileup, but the output only shows genotype liklyhoods. Also tried bam-readcount but it deosn't work with peired-end reads (I think).

I need to know the number of reads supports each allele in my vcf file.

Does anyone know how I coud do it?

SNP alignment sequence • 2.4k views
ADD COMMENT
0
Entering edit mode

Could you post one vcf line from a SNP you are interested?

ADD REPLY
0
Entering edit mode
5.8 years ago
h.mon 35k

I need to know the number of reads supports each allele in my vcf file.

If you are using HaplotypeCaller, the AD field is exactly what you want. See What is a VCF and how should I interpret it?, which explains it, and also briefly explains why AD may be different from what you expect.

AD is the unfiltered allele depth, i.e. the number of reads that support each of the reported alleles. All reads at the position (including reads that did not pass the variant caller’s filters) are included in this number, except reads that were considered uninformative. Reads are considered uninformative when they do not provide enough statistical evidence to support one allele over another.

See also Allele Depth (AD) is lower than expected, which enters into more details about AD quirks.

ADD COMMENT

Login before adding your answer.

Traffic: 1799 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6