AutoSTR {stR}R Documentation

Automatic STR decomposition for time series data

Description

Automatically selects parameters for an STR decomposition of time series data. The time series should be of class ts or msts.

Usage

AutoSTR(
  data,
  robust = FALSE,
  gapCV = NULL,
  lambdas = NULL,
  reltol = 0.001,
  confidence = NULL,
  nsKnots = NULL,
  trace = FALSE
)

Arguments

data

A time series of class ts or msts.

robust

When TRUE, Robust STR decomposition is used. Default is FALSE.

gapCV

An optional parameter defining the length of the sequence of skipped values in the cross validation procedure.

lambdas

An optional parameter. A structure which replaces lambda parameters provided with predictors. It is used as either a starting point for the optimisation of parameters or as the exact model parameters.

reltol

An optional parameter which is passed directly to optim() when optimising the parameters of the model.

confidence

A vector of percentiles giving the coverage of confidence intervals. It must be greater than 0 and less than 1. If NULL, no confidence intervals are produced.

nsKnots

An optional vector parameter, defining the number of seasonal knots (per period) for each sesonal component.

trace

When TRUE, tracing is turned on.

Value

A structure containing input and output data. It is an S3 class STR, which is a list with the following components:

Author(s)

Alexander Dokumentov

References

Dokumentov, A., and Hyndman, R.J. (2022) STR: Seasonal-Trend decomposition using Regression, INFORMS Journal on Data Science, 1(1), 50-62. https://robjhyndman.com/publications/str/

See Also

STR

Examples


# Decomposition of a multiple seasonal time series
decomp <- AutoSTR(calls)
plot(decomp)

# Decomposition of a monthly time series
decomp <- AutoSTR(log(grocery))
plot(decomp)


[Package stR version 0.7 Index]