| wbs2_wrapper | R Documentation |
Wraps the breakfast package's WBS2 solution path with
steepest-drop-to-low-levels (SDLL) model selection.
wbs2_wrapper(x, ...)
x |
A numeric vector. |
... |
Additional arguments passed to |
A ggcpt object.
This engine is not reproducible call to call within an R
session, and no argument here can make it so. On a 200-point series with
one change at 100, repeated identical calls (same input,
set.seed() re-run beforehand so that .Random.seed is
byte-identical on entry) return a last changepoint of either 183 or
188, roughly evenly split. The variation is therefore not driven by R's
random number stream, which is why this wrapper has no seed
argument to offer: there is no stream to pin.
It is upstream, not in this package. Calling
breakfast::breakfast(x, solution.path = "wbs2",
model.selection = "sdll") directly (breakfast 2.5) reproduces it
exactly. A fresh R session is deterministic (five separate
sessions agreed), so what varies is state the engine carries between
calls.
In practice this is rare, and needs a series whose model selection sits
near a tie. Measured over eight other series with three identical calls
each, wbs2 was stable on all eight; the flip above reproduces
only on that one configuration. tguh, which uses the same
package, was stable throughout, as were the other 35 of the 50 wired
methods this experiment covered (the rest need an engine that was not
installed when it was run). If you need a segmentation you can reproduce
exactly, take the result of the first call in a session, or use an
engine with a seed argument (cpt_methods()
reports which wrappers have one).
fryzlewicz2020detectingggchangepoint
Other changepoint engines:
bcp_wrapper(),
beast_wrapper(),
bfast_wrapper(),
binsegrcpp_wrapper(),
bocpd_wrapper(),
capa_wrapper(),
cpm_wrapper(),
cpop_wrapper(),
cpt_wrapper(),
decafs_wrapper(),
ecp_wrapper(),
envcpt_wrapper(),
esac_wrapper(),
fabisearch_wrapper(),
fastcpd_wrapper(),
fcov_wrapper(),
fmean_wrapper(),
fpop_wrapper(),
geomcp_wrapper(),
hdcov_wrapper(),
hdreg_wrapper(),
idetect_wrapper(),
inspect_wrapper(),
kcp_wrapper(),
kwc_wrapper(),
mcp_wrapper(),
mosum_wrapper(),
network_wrapper(),
not_wrapper(),
npmojo_wrapper(),
nsp_wrapper(),
ocd_wrapper(),
pilliat_wrapper(),
segmented_wrapper(),
smuce_wrapper(),
sn_wrapper(),
strucchange_wrapper(),
taylor_wrapper(),
tguh_wrapper(),
trend_wrapper(),
var_wrapper(),
wbs_wrapper(),
wbsts_wrapper()
set.seed(2026)
res <- wbs2_wrapper(c(rnorm(60), rnorm(60, 4)))
res$changepoints
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.