Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • japuch
    Junior Member
    • Sep 2012
    • 3

    #1

    Quality in Pileup depends on Reference

    Dear all,

    i have a strange (for me) problem with generating variant calls by 'samtools mpileup' from a BAM file (attached in archive) generated with novoalign. Namely the base qualities are wrong (different as reported in BAM/SAM) when the reference is provided. Running the following command on the attached BAM:

    'samtools mpileup -r chr14:68272021-68272021 test.bam'

    yields:
    chr14 68272021 N 23 acaCcCacacAAAACCCCACAC^gC ___QFF___]][_\___X\___W

    but running:

    'samtools mpileup -r chr14:68272021-68272021 -f hg19.fa test.bam'

    yields:

    chr14 68272021 C 23 a,a.,.a,a,AAAA....A.A.^g. !^!QFF!^!]!%!$^N^X$^!^A

    The base quality values in the latter are different than those stored in BAM/SAM.

    Any help will be appreciated.

    Best Regards,

    Jacek
    Attached Files
  • me_myself_andI
    Member
    • Nov 2010
    • 30

    #2
    Hi,

    this is most likely due to samtools BAQ computation. Briefly, it will downgrade base-qualities if a misalignment/indel is likely and that will change depending on the reference. See 2021320865. If you don't want this behaviour, you can switch off BAQ computation in samtools mpileup with the option -B, which is however not recommended.

    Andreas

    Comment

    • japuch
      Junior Member
      • Sep 2012
      • 3

      #3
      Hi,

      you were right, thanks. Setting the B parameter recovers the correct behavior. The trick is, however, that none of the reads included in the bam file I attached to my first message has an insertion or deletion (no D or I in CIGAR). That's something I don't understand.


      Jacek

      Comment

      • swbarnes2
        Senior Member
        • May 2008
        • 910

        #4
        Your pileups don't show any indels either, so I don't see what the problem there is.

        ^g does not mean an insertion of a G.

        Also at the read base column, a symbol `^' marks the start of a read segment which is a contiguous subsequence on the read separated by `N/S/H' CIGAR operations. The ASCII of the character following `^' minus 33 gives the mapping quality.

        Comment

        • japuch
          Junior Member
          • Sep 2012
          • 3

          #5
          The thing is that I don't understand why the qualities of the bases indicating a SNP in the position mentioned are reduced by BAQ (using BAQ or not leads to different calls at the position). The BAQ should "reduce false SNP calls caused by misalignments around insertions and deletions (indels).", as the paper about BAQ says. As there is no indel around the position mentioned (and thus no reason for misalignment), the BAQ should not change qualities in this case. Or do I misunderstand something here?

          Thanks for the help!

          Jacek

          Comment

          • swbarnes2
            Senior Member
            • May 2008
            • 910

            #6
            Just don't use BAQ. No matter what it's supposed to do, it often does just what you observed. Its supposed to reduce the number of false positives, but sometimes, it ruins real positives.

            Comment

            Latest Articles

            Collapse

            • SEQadmin2
              Multiomic Liquid Biopsy: What DNA/RNA Panels Reveal That DNA Alone Can’t
              by SEQadmin2



              Tumors contain complex mixtures of cell populations that evolve in response to treatment and host-specific factors. Tissue biopsies provide only static snapshots of a tumor’s state. But what if we could follow that evolution over time using a minimally invasive technique?

              Liquid biopsies can detect tumor-derived material circulating in the bloodstream, providing a way to study treatment response, detect emerging resistance, and discover new biomarkers. Circulating
              ...
              10-14-2026, 09:55 AM
            • SEQadmin2
              New Genomics Technologies Take Aim at Long-Standing Limits
              by SEQadmin2


              Researchers using sequencing and genomics tools often have to make trade-offs. They can choose between speed or scale, short reads or long-range information, or targeted panels or a view of the whole transcriptome. New technologies that have been released this year are built to address those tough choices.

              We asked six companies the same four questions to learn about their latest products. The new technologies bring a lot to the table, including rethinking sequencing
              ...
              09-28-2026, 10:25 AM

            ad_right_rmr

            Collapse

            News

            Collapse

            Topics Statistics Last Post
            Started by SEQadmin2, Yesterday, 11:13 AM
            0 responses
            21 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, Yesterday, 10:48 AM
            0 responses
            18 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-15-2026, 10:52 AM
            0 responses
            36 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 10-14-2026, 05:39 AM
            0 responses
            42 views
            0 reactions
            Last Post SEQadmin2  
            Working...