Class RegressionPredictor

  • All Implemented Interfaces:
    LogicalOperator

    public class RegressionPredictor
    extends AbstractPredictor
    Apply a regression model to the input data. The model defines the independent variables used to create the model. The input data must contain the same independent variables as fields in the data flow. The predicted value is added to the output data flow. All input fields are also transferred to the output.
    • Constructor Detail

      • RegressionPredictor

        public RegressionPredictor()
        Construct a new operator instance.
    • Method Detail

      • getPredictedFieldSuffix

        public String getPredictedFieldSuffix()
        Get the suffix to add to the target field name.
        Returns:
        target field name suffix
      • setPredictedFieldSuffix

        public void setPredictedFieldSuffix​(String predictedFieldSuffix)
        Set the suffix to be added to the target field name. The suffix is set to "(predicted)" by default.
        Parameters:
        predictedFieldSuffix - target field name suffix
      • predictedType

        protected RecordTokenType predictedType​(PMMLModelSpec modelSpec)
        Description copied from class: AbstractPredictor
        Given the model spec, returns the predicted type. This should not include the input type ( the input is automatically prepended to the type that is returned )
        Specified by:
        predictedType in class AbstractPredictor
        Parameters:
        modelSpec - the model metadata
        Returns:
        the predicted type