Class BaseBigNumberEmStdOperator<T>
java.lang.Object
io.deephaven.engine.table.impl.updateby.UpdateByOperator
io.deephaven.engine.table.impl.updateby.internal.BaseObjectUpdateByOperator<BigDecimal>
io.deephaven.engine.table.impl.updateby.emstd.BaseBigNumberEmStdOperator<T>
- Direct Known Subclasses:
BigDecimalEmStdOperator
,BigIntegerEmStdOperator
-
Nested Class Summary
Modifier and TypeClassDescriptionclass
static interface
-
Field Summary
Modifier and TypeFieldDescriptionprotected final OperationControl
protected WritableColumnSource<BigDecimal>
protected final @NotNull MathContext
protected WritableColumnSource<BigDecimal>
protected final BigDecimal
protected final BigDecimal
protected final double
For EM operators, we can allow floating-point tick/time units.protected ColumnSource<?>
Fields inherited from class io.deephaven.engine.table.impl.updateby.internal.BaseObjectUpdateByOperator
colType, maybeInnerSource, outputSource
Fields inherited from class io.deephaven.engine.table.impl.updateby.UpdateByOperator
affectingColumns, forwardWindowScaleUnits, inputModifiedColumnSet, isWindowed, outputModifiedColumnSet, pair, rowRedirection, timestampColumnName
-
Constructor Summary
ConstructorDescriptionBaseBigNumberEmStdOperator
(@NotNull MatchPair pair, @NotNull String[] affectingColumns, @NotNull OperationControl control, @Nullable String timestampColumnName, double windowScaleUnits, @NotNull MathContext mathContext) An operator that computes an EM Std output from a big number column using an exponential decay function. -
Method Summary
Modifier and TypeMethodDescriptionvoid
applyOutputShift
(@NotNull RowSet subRowSetToShift, long delta) Apply a shift to the operation.protected BigDecimal
computeAlpha
(long dt, double timeScaleUnits) protected BigDecimal
computeOneMinusAlpha
(BigDecimal alpha) protected void
handleBadData
(BaseBigNumberEmStdOperator<T>.@NotNull Context ctx, boolean isNull) void
initializeCumulative
(UpdateByOperator.Context updateContext, long firstUnmodifiedKey, long firstUnmodifiedTimestamp, @NotNull RowSet bucketRowSet) Initialize the bucket context for a cumulative operatorvoid
initializeSources
(@NotNull Table source, @Nullable RowRedirection rowRedirection) Initialize this operator with a specific source table (and row redirection if needed).void
prepareForParallelPopulation
(RowSet changedRows) Prepare this operator output column for parallel updated.void
Indicate that the operation should start tracking previous values for ticking updates.Methods inherited from class io.deephaven.engine.table.impl.updateby.internal.BaseObjectUpdateByOperator
clearOutputRows, getOutputColumns
Methods inherited from class io.deephaven.engine.table.impl.updateby.UpdateByOperator
copy, createInputModifiedColumnSet, createOutputModifiedColumnSet, extractDownstreamModifiedColumnSet, finishUpdate, getAffectingColumnNames, getFwdWindowUnits, getInputColumnNames, getInputModifiedColumnSet, getOutputColumnNames, getOutputModifiedColumnSet, getPrevWindowUnits, getTimestampColumnName, initializeCumulativeWithKeyValues, initializeRolling, initializeRollingWithKeyValues, makeUpdateContext, requiresRowPositions
-
Field Details
-
control
-
reverseWindowScaleUnits
protected final double reverseWindowScaleUnitsFor EM operators, we can allow floating-point tick/time units. -
mathContext
-
opAlpha
-
opOneMinusAlpha
-
valueSource
-
emaSource
-
maybeEmaInnerSource
-
-
Constructor Details
-
BaseBigNumberEmStdOperator
public BaseBigNumberEmStdOperator(@NotNull @NotNull MatchPair pair, @NotNull @NotNull String[] affectingColumns, @NotNull @NotNull OperationControl control, @Nullable @Nullable String timestampColumnName, double windowScaleUnits, @NotNull @NotNull MathContext mathContext) An operator that computes an EM Std output from a big number column using an exponential decay function.- Parameters:
pair
- theMatchPair
that defines the input/output for this operationaffectingColumns
- the names of the columns that affect this emacontrol
- defines how to handlenull
input values.timestampColumnName
- the name of the column containing timestamps for time-based calcuationswindowScaleUnits
- the smoothing window for the EMA. If notimestampColumnName
is provided, this is measured in ticks, otherwise it is measured in nanoseconds
-
-
Method Details
-
initializeSources
public void initializeSources(@NotNull @NotNull Table source, @Nullable @Nullable RowRedirection rowRedirection) Description copied from class:UpdateByOperator
Initialize this operator with a specific source table (and row redirection if needed). This will be called exactly once per operator.- Overrides:
initializeSources
in classBaseObjectUpdateByOperator<BigDecimal>
-
initializeCumulative
public void initializeCumulative(@NotNull UpdateByOperator.Context updateContext, long firstUnmodifiedKey, long firstUnmodifiedTimestamp, @NotNull @NotNull RowSet bucketRowSet) Description copied from class:UpdateByOperator
Initialize the bucket context for a cumulative operator- Overrides:
initializeCumulative
in classBaseObjectUpdateByOperator<BigDecimal>
-
startTrackingPrev
public void startTrackingPrev()Description copied from class:UpdateByOperator
Indicate that the operation should start tracking previous values for ticking updates.- Overrides:
startTrackingPrev
in classBaseObjectUpdateByOperator<BigDecimal>
-
applyOutputShift
Description copied from class:UpdateByOperator
Apply a shift to the operation.- Overrides:
applyOutputShift
in classBaseObjectUpdateByOperator<BigDecimal>
-
prepareForParallelPopulation
Description copied from class:UpdateByOperator
Prepare this operator output column for parallel updated.- Overrides:
prepareForParallelPopulation
in classBaseObjectUpdateByOperator<BigDecimal>
-
handleBadData
protected void handleBadData(@NotNull BaseBigNumberEmStdOperator<T>.@NotNull Context ctx, boolean isNull) -
computeAlpha
-
computeOneMinusAlpha
-