Seqanswers Leaderboard Ad

Collapse

Announcement

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

  • Remove paired end duplicated reads -Samtools-Picard

    Dear All,

    I am facing some big problem with samtools rmdup command,

    What I would like to do is to discard reads that fail to align as proper pairs and remove non-unique fragments (and not non-unique reads), in order to delete paired reads that have both F and R reads starting and ending exactly in the same place.

    I tried to run:

    to select only properly paired reads
    Code:
    samtools view -f 2 -b -h -o output.bam input.bam
    to remove duplicates:
    Code:
    samtools rmdup  input.bam output.bam
    but it seems thta reads are not properly removed,

    I tried also to run samtools fixmate before running rmdup but even strangest results.

    So I Switched to Piacard tools Markduplicates command:
    Code:
    java -jar MarkDuplicates.jar I=input.bam O=output.bam M=marked_rep
    ort.txt VALIDATION_STRINGENCY=SILENT REMOVE_DUPLICATES=true
    But even if my file is sorted the program fails reporting bam not sorted:

    Exception in thread "main" net.sf.picard.PicardException: Input file input.bam is not coordinate sorted.
    Any suggestion??

    Thanks,
    Paolo

  • #2
    Picard isn't actually checking to see if the file is sorted, it's just looking for a line in the header saying it is, but samtools sort will not put that header there.

    Use Picard SortSam to sort, and it will adjust the header to say that it is sorted, then MarkDuplicates will work.

    Comment


    • #3
      Just tell Picard to assume it is a sorted file (AS=true)

      Comment

      Latest Articles

      Collapse

      • seqadmin
        Essential Discoveries and Tools in Epitranscriptomics
        by seqadmin




        The field of epigenetics has traditionally concentrated more on DNA and how changes like methylation and phosphorylation of histones impact gene expression and regulation. However, our increased understanding of RNA modifications and their importance in cellular processes has led to a rise in epitranscriptomics research. “Epitranscriptomics brings together the concepts of epigenetics and gene expression,” explained Adrien Leger, PhD, Principal Research Scientist...
        04-22-2024, 07:01 AM
      • seqadmin
        Current Approaches to Protein Sequencing
        by seqadmin


        Proteins are often described as the workhorses of the cell, and identifying their sequences is key to understanding their role in biological processes and disease. Currently, the most common technique used to determine protein sequences is mass spectrometry. While still a valuable tool, mass spectrometry faces several limitations and requires a highly experienced scientist familiar with the equipment to operate it. Additionally, other proteomic methods, like affinity assays, are constrained...
        04-04-2024, 04:25 PM

      ad_right_rmr

      Collapse

      News

      Collapse

      Topics Statistics Last Post
      Started by seqadmin, Yesterday, 08:47 AM
      0 responses
      12 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-11-2024, 12:08 PM
      0 responses
      60 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-10-2024, 10:19 PM
      0 responses
      60 views
      0 likes
      Last Post seqadmin  
      Started by seqadmin, 04-10-2024, 09:21 AM
      0 responses
      54 views
      0 likes
      Last Post seqadmin  
      Working...
      X