powered by
Threshold nonlinearity test.
thr.test(y, p = 1, d = 1, thrV = NULL, ini = 40, include.mean = T)
thr.test returns a list with components:
thr.test
F statistic.
the numerator and denominator degrees of freedom.
initial number of data to start RLS estimation.
a time series.
AR order.
delay for the threshold variable.
threshold variable.
a logical value for including constant terms.
Tsay, R. (1989) Testing and Modeling Threshold Autoregressive Processes. Journal of the American Statistical Associations 84(405), 231-240.
phi=t(matrix(c(-0.3, 0.5,0.6,-0.3),2,2)) y=uTAR.sim(nob=2000, arorder=c(2,2), phi=phi, d=2, thr=0.2, cnst=c(1,-1),sigma=c(1, 1)) thr.test(y$series,p=2,d=2,ini=40,include.mean=TRUE)
Run the code above in your browser using DataLab