From: Drummond, J. <je...@bc...> - 2011-03-31 15:39:57
|
But then how do I get completely unfiltered SNPs? The attraction of the raw pileup with ABQ0 is that it doesn't make judgements. I just really don't need the positions where absolutely all the reads are completely reference. It makes the output file unnecessarily huge. I guess I still don't understand the two-round thing. If I "call SNPs" in the first round, what is the second round for? I apologize if I'm being dense, but I feel like what I want is really pretty simple -- to convert one-read-per-line BAMs into one-position-per-line variant lists. ________________________________________ From: Heng Li [lh...@sa...] Sent: Thursday, March 31, 2011 8:35 AM To: Drummond, Jennifer Cc: Samtools-help Subject: Re: [Samtools-help] Raw (m)pileup (plus BED support available in SVN) You call SNPs in the first round and give the list of SNP sites to "mpileup -l" in the second round. You cannot do in one round like with pileup. Heng On Mar 30, 2011, at 6:22 PM, Drummond, Jennifer wrote: > Thanks, but I still I don’t understand what you mean by “get the variant and feed it to mpileup”. I don’t know what the variant positions are in advance; that’s why I’m running [m]pileup. > > > On 3/30/11 4:22 PM, "Heng Li" <lh...@sa...> wrote: > > > > On Mar 30, 2011, at 4:38 PM, Drummond, Jennifer wrote: > > > Heng Li just mentioned the “raw pileup” command below: > > > > samtools mpileup -ABQ0 -d 1000000 in1.bam in2.bam > > > > Is there a way to have it output only positions with variants, like the -v option in the old pileup command? > > You may get the variant and feed it to mpileup with option "-l". > > BTW, samtools is now able to compute read depth and call SNPs in regions specified by an input BED file. For both "samtools mpileup" (not pileup) and "bcftools view", you may provide the BED via the "-l" option. If the input has two numeric columns, it is parsed as a BED (region list); if has one numeric column, parsed as a position list file, so the "-l" option is backward compatible with old versions. It is also possible to retrieve alignments overlapping a BED file with "samtools view -L in.bed". For mpileup, using "-l" to call SNPs in target/exome regions can be much faster than doing whole-genome calling and then filtering. > > Heng > > > > > ------------------------------------------------------------------------------ > > Create and publish websites with WebMatrix > > Use the most popular FREE web apps or write code yourself; > > WebMatrix provides all the features you need to develop and > > publish your website. http://p.sf.net/sfu/ms-webmatrix-sf > > _______________________________________________ > > Samtools-help mailing list > > Sam...@li... > > https://lists.sourceforge.net/lists/listinfo/samtools-help > > > > -- > The Wellcome Trust Sanger Institute is operated by Genome Research > Limited, a charity registered in England with number 1021457 and a > company registered in England with number 2742969, whose registered > office is 215 Euston Road, London, NW1 2BE. > > ------------------------------------------------------------------------------ > Create and publish websites with WebMatrix > Use the most popular FREE web apps or write code yourself; > WebMatrix provides all the features you need to develop and > publish your website. http://p.sf.net/sfu/ms-webmatrix-sf > _______________________________________________ > Samtools-help mailing list > Sam...@li... > https://lists.sourceforge.net/lists/listinfo/samtools-help -- The Wellcome Trust Sanger Institute is operated by Genome Research Limited, a charity registered in England with number 1021457 and a company registered in England with number 2742969, whose registered office is 215 Euston Road, London, NW1 2BE. |