DetectAnomaly()
Detects anomalies in numeric expression using specified parameters. The result value is set by the anomalyDetection argument:
- "Anomaly" (0 or 1 - indicates anomaly alert for a given data point),
- "AnomalyScore", "Mag", "ExpectedValue", "BoundaryUnit", "UpperBoundary" or "LowerBoundary".
- Detect mode: "AnomalyOnly", "AnomalyAndMargin" or "AnomalyAndExpectedValue".
Syntax
DetectAnomaly(numericExpression, threshold, batchSize, sensitivity,
string detectMode, string anomalyDetection, date/time forecastStartTime)
Example
DetectAnomaly("oil production" in "m3", 0.5, 1000, 0, "AnomalyOnly", "Anomaly", #01/01/2021#)
DetectAnomaly("oil production" in "m3", 0.3, 100, 99, "AnomalyAndMargin",
"AnomalyScore", #02/02/2022#)
DetectAnomaly("oil production" in "m3", 0.2, 500, 100, "AnomalyAndExpectedValue",
"Mag", #03/03/2023#)