Seqanswers Leaderboard Ad

Collapse

Announcement

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

  • Sam to Bam using Picard - help!

    Hi,

    I am trying to convert from sam to bam using Picard but am getting an error message (see below). Can anyone interpret this for me?

    Thanks!

    Kath

    [skgtkaf@login01 13655]$ java -jar /home/skgtkaf/ngs/picard-tools-1.35/SamFormatConverter.jar I=13655_q20.sam O=13655_q20.bam
    [Wed Nov 24 10:54:33 CET 2010] net.sf.picard.sam.SamFormatConverter INPUT=13655_q20.sam OUTPUT=13655_q20.bam TMP_DIR=/tmp/skgtkaf VERBOSITY=INFO QUIET=false VALIDATION_STRINGENCY=STRICT COMPRESSION_LEVEL=5 MAX_RECORDS_IN_RAM=500000 CREATE_INDEX=false CREATE_MD5_FILE=false
    [Wed Nov 24 10:54:33 CET 2010] net.sf.picard.sam.SamFormatConverter done.
    Runtime.totalMemory()=128843776
    Exception in thread "main" net.sf.samtools.SAMFormatException: Error parsing text SAM file. CIGAR should have zero elements for unmapped read.; Line 165
    Line: GA04_0001:4:1:1082:7316#0 133 chr12 27877005 0 35M43S =27877005 0 AAANNATNTNNTNNAATGANNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNCTTANNANNACNNNNNNNNNN %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% XC:i:35
    at net.sf.samtools.SAMTextReader.reportErrorParsingLine(SAMTextReader.java:220)
    at net.sf.samtools.SAMTextReader.access$500(SAMTextReader.java:40)
    at net.sf.samtools.SAMTextReader$RecordIterator.parseLine(SAMTextReader.java:424)
    at net.sf.samtools.SAMTextReader$RecordIterator.next(SAMTextReader.java:268)
    at net.sf.samtools.SAMTextReader$RecordIterator.next(SAMTextReader.java:240)
    at net.sf.samtools.SAMFileReader$AssertableIterator.next(SAMFileReader.java:604)
    at net.sf.samtools.SAMFileReader$AssertableIterator.next(SAMFileReader.java:582)
    at net.sf.picard.sam.SamFormatConverter.doWork(SamFormatConverter.java:65)
    at net.sf.picard.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:156)
    at net.sf.picard.sam.SamFormatConverter.main(SamFormatConverter.java:73)

  • #2
    What aligner are you using? From the SAM flag of that read (133) that read is unaligned and so picard wants it to have no defined CIGAR (which makes sense!) Have you tried samtools? May its less strict

    Comment


    • #3
      I think you should change the VALIDATION_STRINGENCY option, read more about it here: http://seqanswers.com/forums/showthread.php?t=4246

      Comment


      • #4
        Thanks for the suggestions. I used BWA to align the reads. I didn't realise you could use SAMtools to convert from SAM to BAM.

        Comment


        • #5
          Ok, setting VALIDATION_STRINGENCY=LENIENT allows the .bam file to be produced. Thanks very much for your help!

          Comment


          • #6
            How did you set the validation=lenient?

            Comment


            • #7
              Originally posted by muzz56 View Post
              How did you set the validation=lenient?
              just include that string "VALIDATION_STRINGENCY=LENIENT" somewhere in your command.

              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
              10 views
              0 likes
              Last Post seqadmin  
              Started by seqadmin, Yesterday, 06:07 PM
              0 responses
              9 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