picard.sam.markduplicates.util

## Class AbstractOpticalDuplicateFinderCommandLineProgram

- java.lang.Object
- - picard.cmdline.CommandLineProgram
  - - picard.sam.markduplicates.util.AbstractOpticalDuplicateFinderCommandLineProgram

- Direct Known Subclasses:
    AbstractMarkDuplicatesCommandLineProgram, EstimateLibraryComplexity

      public abstract class AbstractOpticalDuplicateFinderCommandLineProgram
      extends CommandLineProgram

  Abstract class that holds parameters and methods common to classes that optical duplicate detection. We put them here so that the explanation about how read names are parsed is in once place

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected static htsjdk.samtools.util.Log` | `LOG`
    `int` | `OPTICAL_DUPLICATE_PIXEL_DISTANCE`
    `protected OpticalDuplicateFinder` | `opticalDuplicateFinder`
    `String` | `READ_NAME_REGEX`

    - ### Fields inherited from class picard.cmdline.CommandLineProgram

      `COMPRESSION_LEVEL, CREATE_INDEX, CREATE_MD5_FILE, GA4GH_CLIENT_SECRETS, MAX_RECORDS_IN_RAM, QUIET, REFERENCE_SEQUENCE, TMP_DIR, VALIDATION_STRINGENCY, VERBOSITY`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractOpticalDuplicateFinderCommandLineProgram()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected String[]` | `customCommandLineValidation()` Put any custom command-line validation in an override of this method.
    `void` | `setupOpticalDuplicateFinder()`

    - ### Methods inherited from class picard.cmdline.CommandLineProgram

      `doWork, getCommandLine, getCommandLineParser, getDefaultHeaders, getMetricsFile, getNestedOptions, getNestedOptionsForHelp, getStandardUsagePreamble, getVersion, instanceMain, instanceMainWithExit, parseArgs, setDefaultHeaders`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### LOG

          protected static htsjdk.samtools.util.Log LOG

    - #### READ_NAME_REGEX

          @Option(doc="Regular expression that can be used to parse read names in the incoming SAM file. Read names are parsed to extract three variables: tile/region, x coordinate and y coordinate. These values are used to estimate the rate of optical duplication in order to give a more accurate estimated library size. Set this option to null to disable optical duplicate detection, e.g. for RNA-seq or other data where duplicate sets are extremely large and estimating library complexity is not an aim. Note that without optical duplicate counts, library size estimation will be inaccurate. The regular expression should contain three capture groups for the three variables, in order. It must match the entire read name. Note that if the default regex is specified, a regex match is not actually done, but instead the read name  is split on colon character. For 5 element names, the 3rd, 4th and 5th elements are assumed to be tile, x and y values. For 7 element names (CASAVA 1.8), the 5th, 6th, and 7th elements are assumed to be tile, x and y values.",
                  optional=true)
          public String READ_NAME_REGEX

    - #### OPTICAL_DUPLICATE_PIXEL_DISTANCE

          @Option(doc="The maximum offset between two duplicate clusters in order to consider them optical duplicates. The default is appropriate for unpatterned versions of the Illumina platform. For the patterned flowcell models, 2500 is moreappropriate. For other platforms and models, users should experiment to find what works best.")
          public int OPTICAL_DUPLICATE_PIXEL_DISTANCE

    - #### opticalDuplicateFinder

          protected OpticalDuplicateFinder opticalDuplicateFinder

  - ### Constructor Detail

    - #### AbstractOpticalDuplicateFinderCommandLineProgram

          public AbstractOpticalDuplicateFinderCommandLineProgram()

  - ### Method Detail

    - #### setupOpticalDuplicateFinder

          public void setupOpticalDuplicateFinder()

    - #### customCommandLineValidation

          protected String[] customCommandLineValidation()

      Description copied from class: `CommandLineProgram`
      Put any custom command-line validation in an override of this method. clp is initialized at this point and can be used to print usage and access argv. Any options set by command-line parser can be validated.
      Overrides:
        `customCommandLineValidation` in class `CommandLineProgram`
      Returns:
        null if command line is valid. If command line is invalid, returns an array of error message to be written to the appropriate place.