How can measurement data be filtered?
When assigning raw data to measuring points, filters can be defined to filter the measurement data before it is displayed or processed further.
Moving average filters are currently implemented, which average measurement data according to certain criteria. The current measured value is determined by averaging over a predefined number of measured values in the past, whereby further criteria can be applied to these measured values.
This number of measured values in the past forms the averaging window. The number represents its maximum “width”.
To calculate a specific measured value, you can now imagine this averaging window positioned at the measured value, which selects a certain number of measured values from the time series in the past for averaging. In the course of the calculation for the entire time series, this window is shifted step by step from measured value to measured value, starting with the oldest measured value in the direction of more recent measured values, and the mean value is recalculated for the current measured value respectively.
Note: If using the process outlined above, it does mean that filtering is not possible for a certain number of the oldest measured values in the time series, as there are not enough previous values. The error code 910 is then set for the affected measured values. When interpreting the results, a certain run-in time must therefore always be taken into account, which depends in particular on the selected window width and the measurement cycle with which the time series was recorded.
Simple moving average
The current measured value is determined by averaging over a number of measured values in the past, whereby a maximum measured value age relative to the current measured value timestamp must be specified in addition to the window width to configure this filter.
This means that the new value to be calculated for the current point in time by the filtering is a simple arithmetic mean of the previous values in the averaging window, whereby a measured value in the window is only included in the averaging if its timestamp relative to the timestamp of the current measuring point is not older than the specified maximum age.
In particular, this prevents excessively old measured values from being included in the averaging if there are correspondingly long measurement pauses.
Mean variance
The mean value is initially calculated in the same way as for the simple moving average, but the measured values in the averaging window are ultimately subjected to a further check:
Only measured values that lie within a predefined bound, which is defined as a multiple of the current standard deviation, around the current window mean value contribute to the final mean value.
This makes it possible for outliers to be suppressed.
The “age criterion” described for the simple moving average also applies to measured values in the averaging window for this averaging method.
Set filtering for a channel
Filtering can be defined separately for each measuring point channel. This is done in the assignments of a measuring point, the filter criteria are therefore considered properties of the assignment.
Filter properties
Window width
Specification of the number of measured points in the past which are used for the average - in metaphorical terms: the width of the averaging window.
Restrictions: This whole number must be greater than 2.
The larger the value, the greater the computing effort.Filter width in hours
Specification of a time period as the maximum age of measured values in the averaging window, relative to the respective current calculated measured value.Multiple of standard deviation – only for the filter type “Mean variance”:
Specification of a multiple of standard deviation.
The filter width in hours must be set large enough to ensure that there are sufficient measured values in the window for the measurement frequency of the channels that are being filtered.