TARMA.sim {tseriesTARMA} | R Documentation |
Simulation of a two-regime TARMA(p1,p2,q1,q2)
process
Description
Simulates from the following two-regime TARMA(p1,p2,q1,q2)
process:
Usage
TARMA.sim(
n,
phi1,
phi2,
theta1,
theta2,
d = 1,
thd = 0,
s1 = 1,
s2 = 1,
rand.gen = rnorm,
innov = rand.gen(n, ...),
n.start = 500,
xstart,
start.innov = rand.gen(n.start, ...),
...
)
Arguments
n |
Length of the series. |
phi1 |
Vector of |
phi2 |
Vector of |
theta1 |
Vector of |
theta2 |
Vector of |
d |
Delay parameter. Defaults to |
thd |
Threshold parameter. Defaults to |
s1 |
Innovation variance for the lower regime. Defaults to |
s2 |
Innovation variance for the upper regime. Defaults to |
rand.gen |
Optional: a function to generate the innovations. Defaults to |
innov |
Optional: a time series of innovations. If not provided, |
n.start |
Length of the burn-in period. Defaults to |
xstart |
Initial condition as a named list: |
start.innov |
Optional: a time series of innovations for the burn-in period. |
... |
Additional arguments for |
Details
Note that the parameters are not checked for ergodicity.
Value
A time series object of class ts
generated from the above model.
Author(s)
Simone Giannerini, simone.giannerini@unibo.it
Greta Goracci, greta.goracci@unibz.it
References
-
Giannerini S, Goracci G (2021). “Estimating and Forecasting with TARMA models.” University of Bologna.
Examples
## a TARMA(1,1,1,1) model
set.seed(123)
x <- TARMA.sim(n=100, phi1=c(0.5,-0.5), phi2=c(0.0,0.8), theta1=-0.5, theta2=0.5, d=1, thd=0.2)
## a TARMA(1,2,1,1) model
x <- TARMA.sim(n=100,phi1=c(0.5,-0.5,0),phi2=c(0,0.5,0.3),theta1=-0.5,theta2=0.5,d=1,thd=0.2)