mTAR.sim: Generate Two-Regime (TAR) Models

mTAR.simR Documentation

Generate Two-Regime (TAR) Models

Description

Generates multivariate two-regime threshold autoregressive models.

Usage

mTAR.sim(
  nob,
  thr,
  phi1,
  phi2,
  sigma1,
  sigma2 = NULL,
  c1 = NULL,
  c2 = NULL,
  delay = c(1, 1),
  ini = 500
)

Arguments

nob

number of observations.

thr

threshold value.

phi1

VAR coefficient matrix of regime 1.

phi2

VAR coefficient matrix of regime 2.

sigma1

innovational covariance matrix of regime 1.

sigma2

innovational covariance matrix of regime 2.

c1

constant vector of regime 1.

c2

constant vector of regime 2.

delay

two elements (i,d) with "i" being the component index and "d" the delay for threshold variable.

ini

burn-in period.

Value

mTAR.sim returns a list with following components:

series

a time series following the multivariate two-regime VAR model.

at

innovation of the time series.

threshold

threshold value.

delay

two elements (i,d) with "i" being the component index and "d" the delay for threshold variable.

n1

number of observations in regime 1.

n2

number of observations in regime 2.

Examples

phi1=matrix(c(0.5,0.7,0.3,0.2),2,2)
phi2=matrix(c(0.4,0.6,0.5,-0.5),2,2)
sigma1=matrix(c(1,0,0,1),2,2)
sigma2=matrix(c(1,0,0,1),2,2)
c1=c(0,0)
c2=c(0,0)
delay=c(1,1)
y=mTAR.sim(100,0,phi1,phi2,sigma1,sigma2,c1,c2,delay,ini=500)

NTS documentation built on Sept. 25, 2023, 1:08 a.m.

Related to mTAR.sim in NTS...