Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • samtools mpileup generates an empty output

    Hello,

    I am runnning the samtools mpileup to a bam file generated by bfast (and processed by Picard RemoveDuplicates), and everything seems to work fine except for a certain sample in which the mpileup command generates an empty file.

    The inputted bam file seems OK; it is an exome paired end alignement (of note both end pairs of each read are aligned, since I've found in the forum that it could be a cause of mpileup failure).

    I've tried with several samtools versions and with several argument values, but it always rsults in the empty file after 1/2 hour of processing time.

    I'm pretty confused with that, since I've used the same commands for all the samples and in general it worked fine. Anyone has a clue of what is happening?

    Thanks!

  • #2
    Just for those than can be interested in this thread, I've found that all the reads of this sample have been accounted as anomalous reads by mpileup, so they are excluded (and thus, an empty output is generated) if the -A flag of the mpileup command is not set.

    cheers!
    david
    Last edited by david.tamborero; 01-22-2012, 01:15 PM.

    Comment


    • #3
      Thank you very much, I just ran into the exact same problem and I was completely puzzled.
      I wonder why the mpileup considered all those reads anomalous, do you know what criteria it uses to make that call? Is it a problem with aligner used?

      Comment


      • #4
        I was checking this long time ago, and now I don't remember it on detail. I guess mpileup filtered out those reads that could be untrustwirthy, as those with zero-mapping quality or those improperly paired. For exact details, i guess you can ask to the samtools mailing list.

        Comment


        • #5
          similar issue with RNA-Seq reads

          Hi I have been trying to use samtools mpileup on RNA-Seq reads. These reads were in fastq format, and aligned against a mm10 Ensemble68 transcriptome reference using Bowtie2. After aligning I sorted the sam files by genome coordinates and then converted to bam. Now I am trying to use the same bam files and the reference to create the mpileup for further analysis but I keep getting an empty file.

          mpileup only runs for about 2 secs and then stops. The only output I get is: [mpileup] 1 samples in 1 input files
          <mpileup> Set max per-file depth to 8000

          Does anyone have any suggestions?

          Comment


          • #6
            what is the samtools command you are using?

            what does the header to the bam file you are using look like?

            did you create an index for the bam file?

            Does the output from samtools flagstat look good/

            Comment


            • #7
              Hi Richard,

              The command I am using is
              samtools mpileup -f ./reference.fa ./D6-5066.bam > ./D6-5066-mpileup

              When I created the sam file by aligning to the Ensemble68 reference, the sam file had a header, but I needed to use the command 'convert-iso-to-genome-coords' to convert the isoforms genome coordinates. The resulting sam does not have a header and so the bam file needed to be created using this, as recommended for sam files without @SQ header

              samtools faidx ref.fa
              samtools view -bt ref.fa.fai aln.sam > aln.bam

              (link to info about command: http://dna.engr.uconn.edu/software/NGSTools/README.txt)

              So the bam also does not have a header. Do you think these steps might be part of the problem? And no, I did not create an index for the bam files. There didn't seem to be any indication to do so, but I can see if it makes a difference.

              I have not used flagstat before, and am not sure what it does.

              Comment


              • #8
                I encountered this problem, which was caused by me accidentally using the forward read for both the R1 and R2 reads.

                So, using "-A" might have allowed the .pileup file to be created without being empty or generating errors. However, I think it was important to understand why so many orphan "anomalous" reads were being flagged (which meant that I really needed to re-run the alignment).

                Comment

                Latest Articles

                Collapse

                • seqadmin
                  Strategies for Sequencing Challenging Samples
                  by seqadmin


                  Despite advancements in sequencing platforms and related sample preparation technologies, certain sample types continue to present significant challenges that can compromise sequencing results. Pedro Echave, Senior Manager of the Global Business Segment at Revvity, explained that the success of a sequencing experiment ultimately depends on the amount and integrity of the nucleic acid template (RNA or DNA) obtained from a sample. “The better the quality of the nucleic acid isolated...
                  03-22-2024, 06:39 AM
                • seqadmin
                  Techniques and Challenges in Conservation Genomics
                  by seqadmin



                  The field of conservation genomics centers on applying genomics technologies in support of conservation efforts and the preservation of biodiversity. This article features interviews with two researchers who showcase their innovative work and highlight the current state and future of conservation genomics.

                  Avian Conservation
                  Matthew DeSaix, a recent doctoral graduate from Kristen Ruegg’s lab at The University of Colorado, shared that most of his research...
                  03-08-2024, 10:41 AM

                ad_right_rmr

                Collapse

                News

                Collapse

                Topics Statistics Last Post
                Started by seqadmin, Yesterday, 06:37 PM
                0 responses
                8 views
                0 likes
                Last Post seqadmin  
                Started by seqadmin, Yesterday, 06:07 PM
                0 responses
                8 views
                0 likes
                Last Post seqadmin  
                Started by seqadmin, 03-22-2024, 10:03 AM
                0 responses
                49 views
                0 likes
                Last Post seqadmin  
                Started by seqadmin, 03-21-2024, 07:32 AM
                0 responses
                67 views
                0 likes
                Last Post seqadmin  
                Working...
                X