Linear Prediction
The Linear Prediction processor forecast future data points by fitting a linear equation to collected data and using statistical techniques to identify the underlying trend.
- Once window values are full, the mean of values is subtracted from each element and squared (Y_i - Mean_Y)
- Same is done for the time series elements (X_i - Mean_X)
- The sum of squares is sum of (X_i - Mean_X)^2
- The sum of products is sum of (Y_i - Mean_Y) * (X_i - Mean_X)
- The slope is obtained by the formula m = { Sum of products } / { Sum of Squares }
- The intercept is obtained by the formula b = Mean_Y - m * Mean_X
- Finally, prediction is made by extrapolating the number of predictions in the simple formula y = m*X + b
- Residual Error is obtained by modeling for current value, and subtracting the ACTUAL current value.
- The timer interval parameter is useful if the connected input tag is currently not polling, but you still want this KPI to publish a value every few seconds, defined by the aforementioned timer.
- If you know your input is going to publish at the expected interval, it is better to disable this timer by entering 0 in the field.
Parameters | Details |
---|---|
Window Size | This parameter determines how many values the processor should observe before making each prediction. |
Number of Predictions | This parameter specifies how many polling intervals into the future the processor should predict. |
Polling Interval | This parameter defines the time interval, in seconds, between successive data polling or data collection. |
Timer Interval | If no event is detected, this timer interval is used to keep displaying the output continually. Entering zero disables this timer, and the prediction model relies entirely on incoming data for updates. |
Note: When creating an analytics flow with Linear Prediction processor, refer the Use the Linear Prediction Function guide for more details.