anomalize
0.3.0Tidy Anomaly Detection
Overview
The 'anomalize' package enables a "tidy" workflow for detecting anomalies in data. The main functions are time_decompose(), anomalize(), and time_recompose(). When combined, it's quite simple to decompose time series, detect anomalies, and create bands separating the "normal" data from the anomalous data at scale (i.e. for multiple time series). Time series decomposition is used to remove trend and seasonal components via the time_decompose() function and methods include seasonal decomposition of time series by Loess ("stl") and seasonal decomposition by piecewise medians ("twitter"). The anomalize() function implements two methods for anomaly detection of residuals including using an inner quartile range ("iqr") and generalized extreme studentized deviation ("gesd"). These methods are based on those used in the 'forecast' package and the Twitter 'AnomalyDetection' package. Refer to the associated functions for specific references for these methods.
Install
Health
- OK2026-06-0913 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
- ERROR2026-06-0812 OK · 0 NOTE · 0 WARNING · 1 ERROR · 0 FAILURE
- OK2026-03-1014 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
Documentation
- Examples that run
- 75%
- Documented parameters
- 100%
- Return-value docs
- 92%
- References docs
- 29%
Downloads
Repository
Stars over time
Forks over time
Issues over time
PRs over time
Repository practices
7 development-tooling and community-health practices detected across 6 families in the upstream repository
Checks run against github.com/business-science/anomalize on 2026-07-19.
Show all practices
Dependencies
Code & Tests
- Cyclomatic complexity
- 1.0 median / 8 max
- Test cases
- 45 / 0.25 per code line
Test coverage
Line coverage
79%
Expression
81.5%
Tests / Examples
79.0% / 64% ex
Functions
62 17 exported
Complexity
2 avg / 8 max
Call network
62 nodes / 47 edges
Call graph
Open call graph →Lowest coverage
62 functions| Function | Cyclo | Coverage |
|---|---|---|
| set_time_scale_template exp | 2 | 0% |
| time_scale_template exp | 1 | 0% |
| .onLoad | 1 | 0% |
| anomalize.default | 1 | 0% |
| palette_dark | 1 | 0% |
| palette_green | 1 | 0% |
People & History
8 releases. Pick two to compare their code metrics. R releases are shown for context.
- RR 4.6.0 released · 2026-04-24
- RR 4.5.0 released · 2025-04-11
- RR 4.4.0 released · 2024-04-24
- 0.3.0Latest
- 0.2.42023-09-26 · diff ↗
- unarchivedReturned to CRAN2023-09-25
- RR 4.3.0 released · 2023-04-21
- archivedRemoved from CRAN2023-03-23requires archived package 'sweep'
- 0.2.32023-02-09 · diff ↗
- RR 4.2.0 released · 2022-04-22
- RR 4.1.0 released · 2021-05-18
- 0.2.22020-10-20 · diff ↗
- 0.2.12020-06-19 · diff ↗
- unarchivedReturned to CRAN2020-06-19
- archivedRemoved from CRAN2020-06-15check problems were not corrected in time
- RR 4.0.0 released · 2020-04-24
Package metadata
- First published
- 2018-04-06
- Total releases
- 8 / 8 yrs
- License
- GPL (>= 3) OSI
- Minimum R
- ≥ 3.0.0
- Bundled data
- 40 KB / 1 file
- Download size
- 2.9 MB
- Installed size
- not tracked yet
- With dependencies
- not tracked yet