| oesg | R Documentation |
Wrapper of omg that fits a general occurrence (probability) model — two parallel ETS sub-models A and B combined via a Beta-distribution link — to a univariate intermittent time series. ARIMA components and regression formulas are disabled; use omg directly if those are needed.
oesg(y, modelA = "MNN", modelB = modelA, lags = c(frequency(y)),
persistenceA = NULL, persistenceB = persistenceA, phiA = NULL,
phiB = phiA, initial = c("backcasting", "optimal", "two-stage",
"complete"), ic = c("AICc", "AIC", "BIC", "BICc"), h = 0,
holdout = FALSE, bounds = c("usual", "admissible", "none"),
etsA = c("conventional", "adam"), etsB = etsA, xregA = NULL,
xregB = NULL, regressorsA = c("use", "select"),
regressorsB = regressorsA, silent = TRUE, ...)
y |
Univariate numeric vector or time series. Non-binary input is binarised internally by omg. |
modelA |
Three-letter ETS specification for sub-model A. |
modelB |
Three-letter ETS specification for sub-model B.
Defaults to |
lags |
Vector of seasonal lags. Defaults to |
persistenceA |
Optional persistence vector for sub-model A. |
persistenceB |
Optional persistence vector for sub-model B.
Defaults to |
phiA |
Optional damping parameter for sub-model A. |
phiB |
Optional damping parameter for sub-model B. Defaults to |
initial |
Initialisation method passed to both sub-models. |
ic |
Information criterion for model selection. |
h |
Forecast horizon. |
holdout |
If |
bounds |
Parameter bounds type. |
etsA |
ETS type for sub-model A: |
etsB |
ETS type for sub-model B. Defaults to |
xregA |
Optional numeric vector or matrix of exogenous regressors for
sub-model A, aligned with |
xregB |
Optional numeric vector or matrix of exogenous regressors for
sub-model B, aligned with |
regressorsA |
How to handle |
regressorsB |
How to handle |
silent |
If |
... |
Additional arguments forwarded to omg. |
An object of class c("omg","om","smooth","occurrence").
omg, oes
set.seed(42)
y <- rbinom(120, 1, 0.3)
m <- oesg(y, modelA="MNN", modelB="MNN")
forecast(m, h=12)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.