# ADWIN
# Usage
This function is used to detect possible concept drift of time series. According to delta parameter, the function judges if concept drift occurs at an input value using ADWIN algorithm, and a new time series of detected concept drifts will be output. For detail, see
Learning from Time-Changing Data with Adaptive Windowing, A Bifetet al., 2005
Name: ADWIN
Input Series: Only support a single input series. The type is INT32 / INT64 / FLOAT / DOUBLE.
delta
:a threshold to distinguish concept drifts. See the δ defined in the paper. Default value is 0.01.windowsize
:the size of window to detect. Should be larger than 2
Output Series: Output a single series. The type is INT32. 1 for anomaly, and 0 for others.
# Examples
# Assigning parameters
Input series:
+-----------------------------+------------+
| Time|root.test.s1|
+-----------------------------+------------+
|1970-01-01T08:00:00.000+08:00| 5.0|
|1970-01-01T08:00:00.100+08:00| 5.0|
|1970-01-01T08:00:00.200+08:00| 5.0|
|1970-01-01T08:00:00.300+08:00| 5.0|
|1970-01-01T08:00:00.400+08:00| 5.0|
|1970-01-01T08:00:00.500+08:00| 5.0|
|1970-01-01T08:00:00.600+08:00| 5.0|
|1970-01-01T08:00:00.700+08:00| 5.0|
|1970-01-01T08:00:00.800+08:00| 5.0|
|1970-01-01T08:00:00.900+08:00| 5.0|
|1970-01-01T08:00:01.000+08:00| 5.0|
|1970-01-01T08:00:01.100+08:00| 5.0|
|1970-01-01T08:00:01.200+08:00| 5.0|
|1970-01-01T08:00:01.300+08:00| 5.0|
|1970-01-01T08:00:01.400+08:00| 5.0|
|1970-01-01T08:00:01.500+08:00| 5.0|
|1970-01-01T08:00:01.600+08:00| 5.0|
|1970-01-01T08:00:01.700+08:00| 5.0|
|1970-01-01T08:00:01.800+08:00| 5.0|
|1970-01-01T08:00:01.900+08:00| 5.0|
|1970-01-01T08:00:02.000+08:00| 10.0|
|1970-01-01T08:00:02.100+08:00| 10.0|
|1970-01-01T08:00:02.200+08:00| 10.0|
|1970-01-01T08:00:02.300+08:00| 10.0|
|1970-01-01T08:00:02.400+08:00| 10.0|
|1970-01-01T08:00:02.500+08:00| 10.0|
|1970-01-01T08:00:02.600+08:00| 10.0|
|1970-01-01T08:00:02.700+08:00| 10.0|
|1970-01-01T08:00:02.800+08:00| 10.0|
|1970-01-01T08:00:02.900+08:00| 10.0|
|1970-01-01T08:00:03.000+08:00| 10.0|
|1970-01-01T08:00:03.100+08:00| 10.0|
|1970-01-01T08:00:03.200+08:00| 10.0|
|1970-01-01T08:00:03.300+08:00| 10.0|
|1970-01-01T08:00:03.400+08:00| 10.0|
|1970-01-01T08:00:03.500+08:00| 10.0|
|1970-01-01T08:00:03.600+08:00| 10.0|
|1970-01-01T08:00:03.700+08:00| 10.0|
|1970-01-01T08:00:03.800+08:00| 10.0|
|1970-01-01T08:00:03.900+08:00| 10.0|
+-----------------------------+------------+
SQL for query:
select adwin(s1,"windowsize"="30","delta"="0.01") from root.test
Output series:
+-----------------------------+------------------------------------------------------+
| Time|adwin(root.test.s1, "windowsize"="30", "delta"="0.01")|
+-----------------------------+------------------------------------------------------+
|1970-01-01T08:00:02.100+08:00| 1|
+-----------------------------+------------------------------------------------------+
← ValueAlign(TODO) IQR →