This tool locates and tags duplicate reads in a SAM, BAM or CRAM file, where duplicate\\\\nreads are defined as originating from a single fragment of DNA. Duplicates can arise during sample preparation e.g.\\\\nlibrary construction using PCR. See also EstimateLibraryComplexity\\\\nfor additional notes on PCR duplication artifacts. Duplicate reads can also result from a single amplification cluster,\\\\nincorrectly detected as multiple clusters by the optical sensor of the sequencing instrument. These duplication\\\\nartifacts are referred to as optical duplicates.
The MarkDuplicates tool works by comparing sequences in the 5\\\\nprime positions of both reads and read-pairs in a SAM/BAM file. A BARCODE_TAG option is available to facilitate\\\\nduplicate marking using molecular barcodes. After duplicate reads are collected, the tool differentiates the primary\\\\nand duplicate reads using an algorithm that ranks reads by the sums of their base-quality scores (default method). Note\\\\nthat this is different from directly checking if the sequences match, which MarkDuplicates does not do.
The\\\\ntool's main output is a new SAM, BAM or CRAM file, in which duplicates have been identified in the SAM flags field for\\\\neach read. Duplicates are marked with the hexadecimal value of 0x0400, which corresponds to a decimal value of 1024. \\\\nIf you are not familiar with this type of annotation, please see the following blog post for additional information.
Although the\\\\nbitwise flag annotation indicates whether a read was marked as a duplicate, it does not identify the type of duplicate. \\\\nTo do this, a new tag called the duplicate type (DT) tag was recently added as an optional output in the 'optional\\\\nfield' section of a SAM/BAM/CRAM file. Invoking the TAGGING_POLICY option, you can instruct the program to mark all the\\\\nduplicates (All), only the optical duplicates (OpticalOnly), or no duplicates (DontTag). The records within the output\\\\nof a SAM/BAM/CRAM file will have values for the 'DT' tag (depending on the invoked TAGGING_POLICY), as either\\\\nlibrary/PCR-generated duplicates (LB), or sequencing-platform artifact duplicates (SQ). This tool uses the\\\\nREAD_NAME_REGEX and the OPTICAL_DUPLICATE_PIXEL_DISTANCE options as the primary methods to identify and differentiate\\\\nduplicate types. Set READ_NAME_REGEX to null to skip optical duplicate detection, e.g. for RNA-seq or other data where\\\\nduplicate sets are extremely large and estimating library complexity is not an aim. Note that without optical duplicate\\\\ncounts, library size estimation will be inaccurate.
MarkDuplicates also produces a metrics file indicating the\\\\nnumbers of duplicates for both single- and paired-end reads.
The program can take either coordinate-sorted or\\\\nquery-sorted inputs, however the behavior is slightly different. When the input is coordinate-sorted, unmapped mates of\\\\nmapped records and supplementary/secondary alignments are not marked as duplicates. However, when the input is\\\\nquery-sorted (actually query-grouped), then unmapped mates and secondary/supplementary reads are not excluded from the\\\\nduplication test and can be marked as duplicate reads.
If desired, duplicates can be removed using the\\\\nREMOVE_DUPLICATE and REMOVE_SEQUENCING_DUPLICATES options.
java -jar picard.jar\\\\nMarkDuplicates \\\\\\\\Please see MarkDuplicates for\\\\ndetailed explanations of the output metrics.
I=input.bam \\\\\\\\
O=marked_duplicates.bam \\\\\\\\
\\\\nM=marked_dup_metrics.txt
This tool locates and tags duplicate reads in a SAM, BAM or CRAM file, where duplicate\\nreads are defined as originating from a single fragment of DNA. Duplicates can arise during sample preparation e.g.\\nlibrary construction using PCR. See also EstimateLibraryComplexity\\nfor additional notes on PCR duplication artifacts. Duplicate reads can also result from a single amplification cluster,\\nincorrectly detected as multiple clusters by the optical sensor of the sequencing instrument. These duplication\\nartifacts are referred to as optical duplicates.
The MarkDuplicates tool works by comparing sequences in the 5\\nprime positions of both reads and read-pairs in a SAM/BAM file. A BARCODE_TAG option is available to facilitate\\nduplicate marking using molecular barcodes. After duplicate reads are collected, the tool differentiates the primary\\nand duplicate reads using an algorithm that ranks reads by the sums of their base-quality scores (default method). Note\\nthat this is different from directly checking if the sequences match, which MarkDuplicates does not do.
The\\ntool's main output is a new SAM, BAM or CRAM file, in which duplicates have been identified in the SAM flags field for\\neach read. Duplicates are marked with the hexadecimal value of 0x0400, which corresponds to a decimal value of 1024. \\nIf you are not familiar with this type of annotation, please see the following blog post for additional information.
Although the\\nbitwise flag annotation indicates whether a read was marked as a duplicate, it does not identify the type of duplicate. \\nTo do this, a new tag called the duplicate type (DT) tag was recently added as an optional output in the 'optional\\nfield' section of a SAM/BAM/CRAM file. Invoking the TAGGING_POLICY option, you can instruct the program to mark all the\\nduplicates (All), only the optical duplicates (OpticalOnly), or no duplicates (DontTag). The records within the output\\nof a SAM/BAM/CRAM file will have values for the 'DT' tag (depending on the invoked TAGGING_POLICY), as either\\nlibrary/PCR-generated duplicates (LB), or sequencing-platform artifact duplicates (SQ). This tool uses the\\nREAD_NAME_REGEX and the OPTICAL_DUPLICATE_PIXEL_DISTANCE options as the primary methods to identify and differentiate\\nduplicate types. Set READ_NAME_REGEX to null to skip optical duplicate detection, e.g. for RNA-seq or other data where\\nduplicate sets are extremely large and estimating library complexity is not an aim. Note that without optical duplicate\\ncounts, library size estimation will be inaccurate.
MarkDuplicates also produces a metrics file indicating the\\nnumbers of duplicates for both single- and paired-end reads.
The program can take either coordinate-sorted or\\nquery-sorted inputs, however the behavior is slightly different. When the input is coordinate-sorted, unmapped mates of\\nmapped records and supplementary/secondary alignments are not marked as duplicates. However, when the input is\\nquery-sorted (actually query-grouped), then unmapped mates and secondary/supplementary reads are not excluded from the\\nduplication test and can be marked as duplicate reads.
If desired, duplicates can be removed using the\\nREMOVE_DUPLICATE and REMOVE_SEQUENCING_DUPLICATES options.
java -jar picard.jar\\nMarkDuplicates \\\\Please see MarkDuplicates for\\ndetailed explanations of the output metrics.
I=input.bam \\\\
O=marked_duplicates.bam \\\\
\\nM=marked_dup_metrics.txt