public abstract class MultiVariantWalkerGroupedOnStart extends MultiVariantWalker
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
COMBINE_VARIANTS_DISTANCE |
protected int |
distanceToCombineVariants |
static java.lang.String |
IGNORE_VARIANTS_THAT_START_OUTSIDE_INTERVAL |
protected boolean |
ignoreIntervalsOutsideStart
this option has no effect unless intervals are specified.
|
static java.lang.String |
MAX_COMBINED_DISTANCE |
protected int |
maxCombinedDistance |
static java.lang.String |
REFERENCE_WINDOW_PADDING |
protected int |
referenceWindowPadding |
multiVariantInputArgumentCollection
DEFAULT_DRIVING_VARIANTS_LOOKAHEAD_BASES, genomicsDBOptions
addOutputSAMProgramRecord, addOutputVCFCommandLine, cloudIndexPrefetchBuffer, cloudPrefetchBuffer, createOutputBamIndex, createOutputBamMD5, createOutputVariantIndex, createOutputVariantMD5, disableBamIndexCaching, features, intervalArgumentCollection, lenientVCFProcessing, outputSitesOnlyVCFs, progressMeter, readArguments, referenceArguments, SECONDS_BETWEEN_PROGRESS_UPDATES_NAME, seqValidationArguments
GATK_CONFIG_FILE, logger, NIO_MAX_REOPENS, NIO_PROJECT_FOR_REQUESTER_PAYS, QUIET, specialArgumentsCollection, tmpDir, useJdkDeflater, useJdkInflater, VERBOSITY
Constructor and Description |
---|
MultiVariantWalkerGroupedOnStart() |
Modifier and Type | Method and Description |
---|---|
void |
apply(java.util.List<htsjdk.variant.variantcontext.VariantContext> variantContexts,
java.util.List<ReadsContext> readsContexts) |
abstract void |
apply(java.util.List<htsjdk.variant.variantcontext.VariantContext> variantContexts,
ReferenceContext referenceContext,
java.util.List<ReadsContext> readsContexts)
This method must be implemented by tool authors.
|
void |
apply(htsjdk.variant.variantcontext.VariantContext variant,
ReadsContext readsContext,
ReferenceContext referenceContext,
FeatureContext featureContext)
This method keeps track of all the variants it is passed and will feed all the variants that start at the same
site to the reduce method.
|
protected int |
defaultDistanceToGroupVariants() |
protected int |
defaultMaxGroupedSpan() |
protected int |
defaultReferenceWindowPadding() |
protected boolean |
isWithinInterval(htsjdk.samtools.util.Locatable loc) |
boolean |
requiresReference()
Does this tool require reference data? Traversals types and/or tools that do should override to return true.
|
void |
traverse()
A complete traversal from start to finish.
|
doDictionaryCrossValidation, getDrivingVariantsFeatureInputs, getHeaderForVariants, getMultiVariantInputArgumentCollection, getSamplesForVariants, getSequenceDictionaryForDrivingVariants, getSpliteratorForDrivingVariants, initializeDrivingVariants, onShutdown, onStartup
getBestAvailableSequenceDictionary, getDrivingVariantCacheLookAheadBases, getGenomicsDBOptions, getProgressMeterRecordLabel, getTransformedVariantStream, getTransformedVariantStream, makePostVariantFilterTransformer, makePreVariantFilterTransformer, makeVariantFilter, requiresFeatures
directlyAccessEngineFeatureManager, directlyAccessEngineReadsDataSource, directlyAccessEngineReferenceDataSource
addFeatureInputsAfterInitialization, bamIndexCachingShouldBeEnabled, closeTool, createSAMWriter, createVCFWriter, createVCFWriter, createVCFWriter, disableProgressMeter, doWork, getDefaultCloudIndexPrefetchBufferSize, getDefaultCloudPrefetchBufferSize, getDefaultReadFilters, getDefaultToolVCFHeaderLines, getDefaultVariantAnnotationGroups, getDefaultVariantAnnotations, getHeaderForFeatures, getHeaderForReads, getHeaderForSAMWriter, getMasterSequenceDictionary, getPluginDescriptors, getReferenceDictionary, getSequenceDictionaryValidationArgumentCollection, getToolName, getTransformedReadStream, getTraversalIntervals, hasFeatures, hasReads, hasReference, hasUserSuppliedIntervals, initializeProgressMeter, makePostReadFilterTransformer, makePreReadFilterTransformer, makeReadFilter, makeSamReaderFactory, makeVariantAnnotations, onTraversalStart, onTraversalSuccess, requiresIntervals, requiresReads, transformTraversalIntervals, useVariantAnnotations
customCommandLineValidation, getCommandLine, getCommandLineParser, getDefaultHeaders, getMetricsFile, getSupportInformation, getToolkitName, getToolkitShortName, getToolStatusWarning, getUsage, getVersion, instanceMain, instanceMainPostParseArgs, isBetaFeature, isExperimentalFeature, parseArgs, printLibraryVersions, printSettings, printStartupMessage, runTool, setDefaultHeaders, warnOnToolStatus
public static final java.lang.String IGNORE_VARIANTS_THAT_START_OUTSIDE_INTERVAL
public static final java.lang.String COMBINE_VARIANTS_DISTANCE
public static final java.lang.String MAX_COMBINED_DISTANCE
public static final java.lang.String REFERENCE_WINDOW_PADDING
@Advanced @Argument(fullName="ignore-variants-starting-outside-interval", doc="Restrict variant output to sites that start within provided intervals (only applies when an interval is specified)", optional=true) protected boolean ignoreIntervalsOutsideStart
This exists to mimic GATK3 interval traversal patterns
@Advanced @Argument(fullName="combine-variants-distance", doc="Maximum distance for variants to be grouped together", optional=true) protected int distanceToCombineVariants
@Advanced @Argument(fullName="max-distance", doc="Maximum distance for variants to be grouped together", optional=true) protected int maxCombinedDistance
@Advanced @Argument(fullName="ref-padding", doc="Number of bases on either side to expand spanning reference window", optional=true) protected int referenceWindowPadding
protected int defaultDistanceToGroupVariants()
protected int defaultReferenceWindowPadding()
protected int defaultMaxGroupedSpan()
public boolean requiresReference()
GATKTool
requiresReference
in class GATKTool
public final void apply(htsjdk.variant.variantcontext.VariantContext variant, ReadsContext readsContext, ReferenceContext referenceContext, FeatureContext featureContext)
apply
in class MultiVariantWalker
variant
- Current variant being processed.readsContext
- Reads overlapping the current variant. Will be an empty, but non-null, context object
if there is no backing source of reads data (in which case all queries on it will return
an empty array/iterator)referenceContext
- Reference bases spanning the current variant. Will be an empty, but non-null, context object
if there is no backing source of reference data (in which case all queries on it will return
an empty array/iterator). Can request extra bases of context around the current variant's interval
by invoking ReferenceContext.setWindow(int, int)
on this object before calling ReferenceContext.getBases()
featureContext
- Features spanning the current variant. Will be an empty, but non-null, context object
if there is no backing source of Feature data (in which case all queries on it will return an
empty List).public abstract void apply(java.util.List<htsjdk.variant.variantcontext.VariantContext> variantContexts, ReferenceContext referenceContext, java.util.List<ReadsContext> readsContexts)
variantContexts
- VariantContexts from driving variants with matching start position
NOTE: This will never be emptyreferenceContext
- ReferenceContext object covering the reference of the longest spanning VariantContextreadsContexts
- public void apply(java.util.List<htsjdk.variant.variantcontext.VariantContext> variantContexts, java.util.List<ReadsContext> readsContexts)
public void traverse()
MultiVariantWalker.traverse()
if you are writing a new walker base class in the
engine package that extends this class. It is not meant to be overridden by tools outside of the
engine package.
Implementation of multi-variant grouped on start traversal.
NOTE: You should only override traverse()
if you are writing a new walker base class in the
engine package that extends this class. It is not meant to be overridden by tools outside of the
engine package.traverse
in class MultiVariantWalker
protected final boolean isWithinInterval(htsjdk.samtools.util.Locatable loc)
loc
- locatable to query