This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Finding pre defined SNPs with bedtools

Bit of a newbie question here...

I have a dataset of Illumina paired end reads mapped to a reference genome with BWA. The next step which I'm struggling with is to call SNPs from this dataset from an existing input list of SNPs. I know how to use bedtools to call new SNPs and to quality filter the calls ect but I'm just not sure how to ask it to pull out a-priori defined snps from a list of genome locations.

Any suggestions would be greatly appreciated.

snp bedtools samtools bcftools

I see the answer you got led you to the bedtools documentation. I've reviewed that, but I can't figure out how to actually call out SNPs rather than how to identify which reads overlap them using bedtools. Did you figure that out?

What is the reason you don't do variant calling for your entire genome and then filter the variants down to those which you want?

1 answer

See this manual:

http://bedtools.readthedocs.io/en/latest/content/overview.html

and find Comparing features in file “A” and file “B”.

I've read through the documentation, but I don't understand how this works. BED files contain start and stop positions, right? Does this work like an index pointing back to the actual sequences? If not, wouldn't an intersect between a BAM file and a SNPs.bed file only point out the position of the SNP, rather than identifying whether or not there is a SNP in the BAM file's sequence?

OP has a bam file and wants to call SNPs...

Log in to answer this question.