Learn R Programming

gratis (version 1.0.7)

generate_ts: Generate time series from random parameter spaces of the mixture autoregressive (MAR) models.

Description

Deprecated function. Please use mar_model() and generate.mar() instead. Generate time series from random parameter spaces of the mixture autoregressive (MAR) models.

Usage

generate_ts(n.ts = 1, freq = 1, nComp = NULL, n = 120, output_format = "list")

Value

A list of time series together with the SARIMA coefficients used in each mixing component and the corresponding mixing weights.

Arguments

n.ts

number of time series to be generated.

freq

seasonal period of the time series to be generated.

nComp

number of mixing components when simulating time series using MAR models.

n

length of the generated time series.

output_format

An optional argument which allows to choose output format between "list" and "tsibble"

Author

Yanfei Kang and Feng Li

References

Wong, CS & WK Li (2000).

Examples

Run this code
x <- generate_ts(n.ts = 2, freq = 12, nComp = 2, n = 120)
x$N1$pars
forecast::autoplot(x$N1$x)

Run the code above in your browser using DataLab