public class ReplaceMissingValues extends CompositeOperator implements RecordPipelineOperator
The order of the input data is preserved where possible. However, when using the action to skip records with missing data, records may be reordered. This is due to how the data is partitioned for parallelization.
A PMML model is created that contains statistics about the number of records skipped and
the number of field values replaced. This model is similar to the one created by the
SummaryStatistics
operator.
Constructor and Description |
---|
ReplaceMissingValues()
Defines a replacement with an empty specification.
|
Modifier and Type | Method and Description |
---|---|
protected void |
compose(CompositionContext ctx)
Compose the body of this operator.
|
RecordPort |
getInput()
Gets the record port providing the input data to the operation.
|
PMMLPort |
getModel()
Returns a port that will output a
PMMLSummaryStatisticsModel . |
RecordPort |
getOutput()
Gets the record port providing the output from the operation.
|
List<ReplaceSpecification> |
getReplaceSpecifications()
Gets the specifications currently configured for the
operation.
|
PMMLPort |
getStatisticsInput()
Gets the optional model port providing statistics for
replace specifications based on column statistics.
|
void |
setReplaceSpecifications(List<ReplaceSpecification> specifications)
Sets the replacement specifications to apply to the input data.
|
disableParallelism, getInputPorts, getOutputPorts, newInput, newInput, newOutput, newRecordInput, newRecordInput, newRecordOutput, notifyError
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
disableParallelism, getInputPorts, getOutputPorts
public ReplaceMissingValues()
public RecordPort getInput()
getInput
in interface PipelineOperator<RecordPort>
public PMMLPort getStatisticsInput()
public RecordPort getOutput()
getOutput
in interface PipelineOperator<RecordPort>
public PMMLPort getModel()
PMMLSummaryStatisticsModel
.
The model will be populated with the following information:
totalFrequency
: total number of rowsinvalidFrequency
: total number of rows for which at least one field with a skip condition was foundmissingFrequency
: total number of rows for which at least one field with a replace condition was foundtestFailureCounts
: per-test failure counts for each condition involving the given fieldPMMLSummaryStatisticsModel
.public List<ReplaceSpecification> getReplaceSpecifications()
public void setReplaceSpecifications(List<ReplaceSpecification> specifications)
specifications
- the value replacement specifications to applyprotected void compose(CompositionContext ctx)
CompositeOperator
OperatorComposable.add(O)
OperatorComposable.connect(P, P)
. This includes
connections from the composite's input ports to sub-operators, connections between sub-operators, and
connections from sub-operators output ports to the composite's output portscompose
in class CompositeOperator
ctx
- the contextCopyright © 2024 Actian Corporation. All rights reserved.