Distance Profiling Methods
Anomaly detection is the process of identifying signal anomalies by detecting deviations from normal behavior.
One approach to anomaly detection is using distance methods, which base anomaly detection on pattern matching within the time series data. This pattern matching is based on the z-normalized Euclidean distances among subsequences.
Distance methods allow you to identify common recurring subsequences (motifs) that typically indicate normal operation and unique subsequences (discords) that indicate possible anomalies.
Distance methods are especially useful because they are relatively simple. The methods require no trained models or labeled data. They can detect anomalous deviations in the data itself for any type of anomalous behavior, whether characterized previously or not. The algorithms for these methods are optimized for fast computation.
Functions
similarityDistance | Compute distance profile between query and time series subsequences (Since R2024b) |
distanceProfile | Compute distance profile of the distances between a query subsequence and all other subsequences of a time series (Since R2024b) |
matrixProfile | Compute matrix profile between all pairs of subsequences in a single-variable or multivariable time series (Since R2024b) |
findDiscord | Find the locations of top discords from the matrix profile of a time series (Since R2024b) |
findMotif | Find the locations of top motif pairs from the matrix profile of a time series (Since R2025a) |
Topics
- Detecting Anomalies in Time Series Using Distance Methods
Compare algorithms for similarity distance, distance profile, and matrix profile that detect anomalous data using pattern-matching.