Operator RLSFilter
Specialized toolkits - release 4.3.1.0-prod20190605 > com.ibm.streams.timeseries 5.0.1 > com.ibm.streams.timeseries.modeling > RLSFilter
The Recursive Least Squares (RLS) is linear regression estimation algorithm that learns to predict a target time series, given inputs.
A linear regression model is estimated from a sequence of provided inputs(covariates) and targets (dependent variables). The fitting is done adaptively by using the recursive least squares (RLS) method. The fitted model can be used to estimate the target (dependent variable), given new unseen inputs (covariates).
The RLSFilter operator takes input in the form of a list of values and produces output in the form of single value or list of values.
Behavior in a consistent region
- The RLSFilter operator is not supported in a consistent region. A warning occurs when you compile your streams processing application.
- The operator cannot be the start of a consistent region. An error occurs when you compile your streams processing application.
Summary
- Ports
- This operator has 2 input ports and 3 output ports.
- Windowing
- This operator does not accept any windowing configurations.
- Parameters
- This operator supports arbitrary parameters in addition to 3 specific parameters.
Required: dependentVariable, forgettingFactor, inputCovariates
- Metrics
- This operator does not report any metrics.
Properties
- Implementation
- C++
- Threading
- Never - Operator never provides a single threaded execution context.
- Ports (0)
-
This port ingests tuples to update the model.
- Properties
-
- Optional: false
- ControlPort: false
- TupleMutationAllowed: false
- WindowingMode: NonWindowed
- WindowPunctuationInputMode: Oblivious
- Ports (1)
-
This port ingests tuples to be scored.
- Properties
-
- Optional: false
- ControlPort: false
- TupleMutationAllowed: false
- WindowingMode: NonWindowed
- WindowPunctuationInputMode: Oblivious
- Assignments
- This operator allows any SPL expression of the correct type to be assigned to output attributes.
- Output Functions
-
- RLSDep
-
- <any T> T AsIs(T v)
- <any T> T estimatedValue()
- RLSCoef
-
- <any T> T AsIs(T v)
- <any T> list<T> coefficients()
- Ports (0)
-
- Properties
-
- Optional: false
- TupleMutationAllowed: false
- WindowPunctuationOutputMode: Preserving
- Ports (1)
-
- Properties
-
- Optional: false
- TupleMutationAllowed: false
- WindowPunctuationOutputMode: Preserving
- Ports (2)
-
- Properties
-
- Optional: false
- TupleMutationAllowed: false
- WindowPunctuationOutputMode: Generating
Required: dependentVariable, forgettingFactor, inputCovariates
- dependentVariable
-
Specifies the input attribute that contains the dependent variable from the update input port.
- Properties
-
- Cardinality: 1
- Optional: false
- ExpressionMode: Expression
- forgettingFactor
-
Specifies that the forgettingFactor range is between 0 and 1.
- Properties
-
- Type: float64
- Cardinality: 1
- Optional: false
- ExpressionMode: Expression
- inputCovariates
-
Specifies the input attribute that contains the co-variates to be operated upon from both the update port and scoring port.
- Properties
-
- Type: list<float64>
- Cardinality: 2
- Optional: false
- ExpressionMode: Expression
- RecursiveLeastSquare
-
( stream<${schema1}> ${outputStream1}; stream<${schema2}> ${outputStream2}; stream<${schema3}> ${outputStream3}) = RLSFilter(${inputStreamForUpdate};${inputStreamForScoring} ) { param inputCovariates: ${inputCovariatesExpression}; dependentVariable: ${dependentVariableExpression}; forgettingFactor: ${forgettingFactorConstant}; output ${outputStream(n)}: ${outputExpression}; }
- RecursiveLeastSquares