Title: | Nonlinear Time Series Analysis |
---|---|
Description: | Function and data sets in the book entitled "Nonlinear Time Series Analysis with R Applications" B.Guris (2020). The book will be published in Turkish and the original name of this book will be "R Uygulamali Dogrusal Olmayan Zaman Serileri Analizi". It is possible to perform nonlinearity tests, nonlinear unit root tests, nonlinear cointegration tests and estimate nonlinear error correction models by using the functions written in this package. The Momentum Threshold Autoregressive (MTAR), the Smooth Threshold Autoregressive (STAR) and the Self Exciting Threshold Autoregressive (SETAR) type unit root tests can be performed using the functions written. In addition, cointegration tests using the Momentum Threshold Autoregressive (MTAR), the Smooth Threshold Autoregressive (STAR) and the Self Exciting Threshold Autoregressive (SETAR) models can be applied. It is possible to estimate nonlinear error correction models. The Granger causality test performed using nonlinear models can also be applied. |
Authors: | Burak Guris <[email protected]> |
Maintainer: | Burak Guris <[email protected]> |
License: | GPL (>= 2) |
Version: | 0.5.0 |
Built: | 2024-12-11 07:11:59 UTC |
Source: | CRAN |
This function allows you to make ARCH Test for residuals
ARCH.Test(x, lags)
ARCH.Test(x, lags)
x |
residual series name, |
lags |
lags |
set.seed(12345) x <- rnorm(1000) ARCH.Test(x,3)
set.seed(12345) x <- rnorm(1000) ARCH.Test(x,3)
This function allows you to make Cook and Vougas(2009) nonlinear unit root test
Cook_Vougas_2009_unit_root(x, model, max_lags)
Cook_Vougas_2009_unit_root(x, model, max_lags)
x |
series name, |
model |
if model A 1, if model B 2, if model C 3, model D 4 |
max_lags |
maximum lag(optimal lag selected by AIC) |
set.seed(12345) x <- rnorm(1000) Cook_Vougas_2009_unit_root(x,model=1,max_lags=3) data(IBM) Cook_Vougas_2009_unit_root(x=IBM,model=3,max_lags=3)
set.seed(12345) x <- rnorm(1000) Cook_Vougas_2009_unit_root(x,model=1,max_lags=3) data(IBM) Cook_Vougas_2009_unit_root(x=IBM,model=3,max_lags=3)
This function allows you to make Cuestas and Garratt(2011) nonlinear unit root test
Cuestas_Garratt_unit_root(x, max_lags, lsm)
Cuestas_Garratt_unit_root(x, max_lags, lsm)
x |
series name, |
max_lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC, if 3 t-stat significance |
Model Estimated model
Selected lag the lag order
Test Statistic the value of the test statistic
CV Critical Values
Cuestas, J. C., & Garratt, D. (2011). Is real GDP per capita a stationary process? Smooth transitions, nonlinear trends and unit root testing. Empirical Economics, 41(3), 555-563.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Cuestas_Garratt_unit_root(x,max_lags=6,lsm=3) y <- cumsum(rnorm(1000)) Cuestas_Garratt_unit_root(y,max_lags=12,lsm=2) data(IBM) Cuestas_Garratt_unit_root(IBM,max_lags=3,lsm=1)
x <- rnorm(1000) Cuestas_Garratt_unit_root(x,max_lags=6,lsm=3) y <- cumsum(rnorm(1000)) Cuestas_Garratt_unit_root(y,max_lags=12,lsm=2) data(IBM) Cuestas_Garratt_unit_root(IBM,max_lags=3,lsm=1)
This function allows you to make Cuestas and Ordonez(2014) nonlinear unit root test
Cuestas_Ordonez_2014_unit_root(x, max_lags)
Cuestas_Ordonez_2014_unit_root(x, max_lags)
x |
series name, |
max_lags |
maximum lag selected lag is determined by AIC |
"model" Estimated model
"Selected lag" the lag order
"Test Statistic" the value of the test statistic
Cuestas, J. C., & Ordóñez, J. (2014). Smooth transitions, asymmetric adjustment and unit roots. Applied Economics Letters, 21(14), 969-972.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Cuestas_Ordonez_2014_unit_root(x, max_lags = 6) y <- cumsum(rnorm(1000)) Cuestas_Ordonez_2014_unit_root(y, max_lags = 8) data(IBM) Cuestas_Ordonez_2014_unit_root(IBM, max_lags = 20)
x <- rnorm(1000) Cuestas_Ordonez_2014_unit_root(x, max_lags = 6) y <- cumsum(rnorm(1000)) Cuestas_Ordonez_2014_unit_root(y, max_lags = 8) data(IBM) Cuestas_Ordonez_2014_unit_root(IBM, max_lags = 20)
This function allows you to make Enders and Granger(1998) nonlinear unit root test for MTAR model
Enders_Granger_1998(x, case, max_lags, lsm)
Enders_Granger_1998(x, case, max_lags, lsm)
x |
series name, |
case |
if raw data 1 if demeaned data 2 if detrended data 3, |
max_lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC |
"Model" Estimated model
"Selected lag" the lag order
"p1=p2=0 Statistic" the value of the test statistic
"p1=p2 statistic" the value of the test statistic
"prob." the probability of test statistic
Enders, W., & Granger, C. W. J. (1998). Unit-root tests and asymmetric adjustment with an example using the term structure of interest rates. Journal of Business & Economic Statistics, 16(3), 304-311.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Enders_Granger_1998(x, case = 1, max_lags = 6, lsm = 1) y <- cumsum(rnorm(1000)) Enders_Granger_1998(y, 2, 8, 2) data(IBM) Enders_Granger_1998(IBM,case = 2,max_lags = 12,lsm = 2 )
x <- rnorm(1000) Enders_Granger_1998(x, case = 1, max_lags = 6, lsm = 1) y <- cumsum(rnorm(1000)) Enders_Granger_1998(y, 2, 8, 2) data(IBM) Enders_Granger_1998(IBM,case = 2,max_lags = 12,lsm = 2 )
This function allows you to make Enders and Siklos(2001) nonlinear cointegration test
Enders_Siklos_2001(y, x, case = 2, max_lags)
Enders_Siklos_2001(y, x, case = 2, max_lags)
y |
series name |
x |
series name, |
case |
if no lag 1, if one lag 2, if four lag 3, default case=2 |
max_lags |
maximum lag (Apropriate lag is selected by Akaike Information Criteria) |
"Model" Estimated model
"Selected Lag" the lag order
"p1=p2=0 Statistic" the value of the test statistic
"p1=p2 Statistic" the value of the test statistic
"p value" the probability of test statistic
Enders, W., & Siklos, P. L. (2001). Cointegration and threshold adjustment. Journal of Business & Economic Statistics, 19(2), 166-176.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) Enders_Siklos_2001(x, y, max_lags = 6) data(MarketPrices) Enders_Siklos_2001(MarketPrices[,1],MarketPrices[,2], max_lags = 12)
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) Enders_Siklos_2001(x, y, max_lags = 6) data(MarketPrices) Enders_Siklos_2001(MarketPrices[,1],MarketPrices[,2], max_lags = 12)
This function allows you to estimate ESTAR Vector Error Correction Model
ESTAR_ECM(y, x, lags)
ESTAR_ECM(y, x, lags)
y |
series name, |
x |
series name |
lags |
lag length |
Exponential smooth transition error correction model as follows:
"Model" Estimated model
"AIC" Akaike information criteria
"BIC" Schwarz information criteria
Kapetanios, G., Shin, Y., & Snell, A. (2006). Testing for cointegration in nonlinear smooth transition error correction models. Econometric Theory, 22(2), 279-303.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) ESTAR_ECM(x, y, lags = 6) data(MarketPrices) ESTAR_ECM(MarketPrices[,1],MarketPrices[,2],lags = 2)
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) ESTAR_ECM(x, y, lags = 6) data(MarketPrices) ESTAR_ECM(MarketPrices[,1],MarketPrices[,2],lags = 2)
This function allows you to make Harvey and Mills(2002) nonlinear unit root test
Harvey_Mills_2002_unit_root(x, model, max_lags, lsm)
Harvey_Mills_2002_unit_root(x, model, max_lags, lsm)
x |
series name, |
model |
if model with intercept 1, if model with trend 2 if model with trend*function 3, |
max_lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC |
"Model" Estimated model
"Selected Lag" the lag order
"Test Statistic" the value of the test statistic
Harvey, D. I., & Mills, T. C. (2002). Unit roots and double smooth transitions. Journal of Applied Statistics, 29(5), 675-683.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Harvey_Mills_2002_unit_root(x, model = 1, max_lags = 6, lsm = 2) y <- cumsum(rnorm(1000)) Harvey_Mills_2002_unit_root(y, 3, 9, 1) data(IBM) Harvey_Mills_2002_unit_root(x = IBM, model = 2, max_lags = 12, lsm = 1)
x <- rnorm(1000) Harvey_Mills_2002_unit_root(x, model = 1, max_lags = 6, lsm = 2) y <- cumsum(rnorm(1000)) Harvey_Mills_2002_unit_root(y, 3, 9, 1) data(IBM) Harvey_Mills_2002_unit_root(x = IBM, model = 2, max_lags = 12, lsm = 1)
This function allows you to make Hu and Chen(2016) nonlinear unit root test
Hu_Chen_Unit_Root(x, case, lags, lsm)
Hu_Chen_Unit_Root(x, case, lags, lsm)
x |
series name, |
case |
if raw data 1 if demeaned data 2 if detrended data 3, |
lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC, if 3 t-stat significance |
"Model" Estimated model
"Selected lag" the lag order
"Test Statistic" the value of the test statistic
Hu, J., & Chen, Z. (2016). A unit root test against globally stationary ESTAR models when local condition is non-stationary. Economics letters, 146, 89-94.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Hu_Chen_Unit_Root(x, case = 1, lags = 6, lsm = 3) y <- cumsum(rnorm(1000)) Hu_Chen_Unit_Root(y, 1, 3, 2) data(IBM) Hu_Chen_Unit_Root(IBM, case = 2,lags = 12, lsm = 2)
x <- rnorm(1000) Hu_Chen_Unit_Root(x, case = 1, lags = 6, lsm = 3) y <- cumsum(rnorm(1000)) Hu_Chen_Unit_Root(y, 1, 3, 2) data(IBM) Hu_Chen_Unit_Root(IBM, case = 2,lags = 12, lsm = 2)
Daily time series data between 01.01.2010 - 01.01.2018
IBM
IBM
A data frame containing :
Price IBM Close Price
Yahoo Finance
summary(IBM)
summary(IBM)
This function allows you to make Kilic(2011) nonlinear unit root test
Kilic_2011_unit_root(x, case, max_lags)
Kilic_2011_unit_root(x, case, max_lags)
x |
series name, |
case |
if raw data 1 if demeaned data 2 if detrended data 3, |
max_lags |
maximum lag apropriate lag length is selected by Akaike Information Criteria |
"Model" Estimated model
"Selected Lag" the lag order
"Test statistic" the value of the test statistic
Kılıç, R. (2011). Testing for a unit root in a stationary ESTAR process. Econometric Reviews, 30(3), 274-302.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(100) Kilic_2011_unit_root(x,1,3) data(IBM) Kilic_2011_unit_root(IBM, case = 3, max_lags = 12)
x <- rnorm(100) Kilic_2011_unit_root(x,1,3) data(IBM) Kilic_2011_unit_root(IBM, case = 3, max_lags = 12)
This function allows you to make Kruse(2011) nonlinear unit root test
Kruse_Unit_Root(x, case, lags, lsm)
Kruse_Unit_Root(x, case, lags, lsm)
x |
series name, |
case |
if raw data 1 if demeaned data 2 if detrended data 3, |
lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC, if 3 t-stat significance |
"Model" Estimated model
"Selected lag" the lag order
"Test Statistic" the value of the test statistic
Kruse, R. (2011). A new unit root test against ESTAR based on a class of modified statistics. Statistical Papers, 52(1), 71-85.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Kruse_Unit_Root(x, case = 1, lags = 6, lsm =1) y <- cumsum(rnorm(1000)) Kruse_Unit_Root(y, 3, 3, 3) data(IBM) Kruse_Unit_Root(IBM,case = 2,lags = 12,lsm = 2)
x <- rnorm(1000) Kruse_Unit_Root(x, case = 1, lags = 6, lsm =1) y <- cumsum(rnorm(1000)) Kruse_Unit_Root(y, 3, 3, 3) data(IBM) Kruse_Unit_Root(IBM,case = 2,lags = 12,lsm = 2)
This function allows you to make Kapetanios, Shin and Snell(2006) nonlinear cointegration test using residual based approach
KSS_2006_Cointegration(y, x, case, lags, lsm)
KSS_2006_Cointegration(y, x, case, lags, lsm)
y |
series name, |
x |
series name |
case |
if raw data 1 if demeaned data 2 if detrended data 3, |
lags |
lag length |
lsm |
lag selection methods if 1 AIC, if 2 BIC, if 3 t-stat significance |
"Model" Estimated model
"Selected lag" the lag order
"Test Statistic" the value of the test statistic
Kapetanios, G., Shin, Y., & Snell, A. (2006). Testing for cointegration in nonlinear smooth transition error correction models. Econometric Theory, 22(2), 279-303.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) KSS_2006_Cointegration(x, y, case = 1, lags = 6, lsm = 3) KSS_2006_Cointegration(MarketPrices[,1],MarketPrices[,2], case = 1, lags = 2, lsm = 1)
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) KSS_2006_Cointegration(x, y, case = 1, lags = 6, lsm = 3) KSS_2006_Cointegration(MarketPrices[,1],MarketPrices[,2], case = 1, lags = 2, lsm = 1)
This function allows you to make Kapetanios, Shin and Snell(2003) nonlinear unit root test
KSS_Unit_Root(x, case, lags, lsm)
KSS_Unit_Root(x, case, lags, lsm)
x |
series name, |
case |
if raw data 1 if demeaned data 2 if detrended data 3, |
lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC, if 3 t-stat significance |
"Model" Estimated model
"Selected lag" the lag order
"Test Statistic" the value of the test statistic
Kapetanios, G., Shin, Y., & Snell, A. (2003). Testing for a unit root in the nonlinear STAR framework. Journal of econometrics, 112(2), 359-379.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) KSS_Unit_Root(x, case = 1, lags = 6, lsm =1) y <- cumsum(rnorm(1000)) KSS_Unit_Root(y, 1, 3, 3) data(IBM) KSS_Unit_Root(IBM,case = 1,lags = 20,lsm = 3)
x <- rnorm(1000) KSS_Unit_Root(x, case = 1, lags = 6, lsm =1) y <- cumsum(rnorm(1000)) KSS_Unit_Root(y, 1, 3, 3) data(IBM) KSS_Unit_Root(IBM,case = 1,lags = 20,lsm = 3)
This function allows you to make Leybourne, Newbold and Vougas (1998) nonlinear unit root test
LNV_1998_unit_root(x, model, max_lags, lsm)
LNV_1998_unit_root(x, model, max_lags, lsm)
x |
series name, |
model |
if model with intercept 1, if model with trend 2 if model with trend*function 3, |
max_lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC |
"Model" Estimated model
"Selected Lag" the lag order
"Test Statistic" the value of the test statistic
Leybourne, S., Newbold, P., & Vougas, D. (1998). Unit roots and smooth transitions. Journal of time series analysis, 19(1), 83-97.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) LNV_1998_unit_root(x, model = 1, max_lags = 6, lsm = 2) y <- cumsum(rnorm(1000)) LNV_1998_unit_root(y, 3, 3, lsm = 1) data(IBM) LNV_1998_unit_root(x = IBM, model=2,max_lags = 10, lsm = 1)
x <- rnorm(1000) LNV_1998_unit_root(x, model = 1, max_lags = 6, lsm = 2) y <- cumsum(rnorm(1000)) LNV_1998_unit_root(y, 3, 3, lsm = 1) data(IBM) LNV_1998_unit_root(x = IBM, model=2,max_lags = 10, lsm = 1)
Daily time series data between 01.01.2014-01.01.2019
MarketPrices
MarketPrices
A data frame containing :
FCHI CAC 40 Paris Stock Exchange Prices
IBEX Madrid Stock Exchange Prices
Yahoo Finance
summary(MarketPrices)
summary(MarketPrices)
This function allows you to make Mc.Leod.Li nonlinearity test
Mc.Leod.Li(y, lag)
Mc.Leod.Li(y, lag)
y |
series name, |
lag |
lag parameter, |
"lag stat pvalue" the lag order, the value of the test statistic and the probability of test statistic, respectively.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Mc.Leod.Li(x, 10) data(IBM) Mc.Leod.Li(IBM,4)
x <- rnorm(1000) Mc.Leod.Li(x, 10) data(IBM) Mc.Leod.Li(IBM,4)
This function allows you to estimate MTAR Vector Error Correction Model with threshold=0
MTAR_ECM(y, x, lags)
MTAR_ECM(y, x, lags)
y |
series name, |
x |
series name |
lags |
lag length |
"Model" Estimated model
"AIC" Akaike information criteria
"BIC" Schwarz information criteria
Enders, W., & Siklos, P. L. (2001). Cointegration and threshold adjustment. Journal of Business & Economic Statistics, 19(2), 166-176.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) MTAR_ECM(x, y, lags = 6) data(MarketPrices) MTAR_ECM(MarketPrices[,1],MarketPrices[,2],lags = 2)
x <- cumsum(rnorm(1000)) y <- cumsum(rnorm(1000)) MTAR_ECM(x, y, lags = 6) data(MarketPrices) MTAR_ECM(MarketPrices[,1],MarketPrices[,2],lags = 2)
This function allows you to make Park and Shintani(2012) nonlinear unit root test
Park_Shintani_2016_unit_root(x, max_lags)
Park_Shintani_2016_unit_root(x, max_lags)
x |
series name, |
max_lags |
maximum lag (Apropriate lag is selected by Akaike Information Criteria) |
"Model" Estimated model
"Selected Lag" the lag order
"Test statistic" the value of the test statistic
Park, J. Y., & Shintani, M. (2016). Testing for a unit root against transitional autoregressive models. International Economic Review, 57(2), 635-664.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(50) Park_Shintani_2016_unit_root(x, max_lags = 1) data(IBM) Park_Shintani_2016_unit_root(IBM, max_lags = 12)
x <- rnorm(50) Park_Shintani_2016_unit_root(x, max_lags = 1) data(IBM) Park_Shintani_2016_unit_root(IBM, max_lags = 12)
This function allows you to make Pascalau(2007) nonlinear unit root test
Pascalau_2007_unit_root(x, case, max_lags, lsm)
Pascalau_2007_unit_root(x, case, max_lags, lsm)
x |
series name, |
case |
if raw data 1, if demeaned data 2, if detrended data 3 |
max_lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC |
"Model" Estimated model
"Selected lag" the lag order
"Test statistic" the value of the test statistic
Pascalau, R. (2007). Testing for a unit root in the asymmetric nonlinear smooth transition framework. Department of Economics, Finance and Legal Studies University of Alabama Unpublished manuscript.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Pascalau_2007_unit_root(x, case = 1, max_lags = 6, lsm = 2) y <- cumsum(rnorm(1000)) Pascalau_2007_unit_root(y, 2, 4, 1) data(IBM) Pascalau_2007_unit_root(x = IBM, case = 3, max_lags = 3, lsm = 1)
x <- rnorm(1000) Pascalau_2007_unit_root(x, case = 1, max_lags = 6, lsm = 2) y <- cumsum(rnorm(1000)) Pascalau_2007_unit_root(y, 2, 4, 1) data(IBM) Pascalau_2007_unit_root(x = IBM, case = 3, max_lags = 3, lsm = 1)
This function allows you to estimate SETAR model
SETAR_model(y, delay_order, lag_length, trim_value)
SETAR_model(y, delay_order, lag_length, trim_value)
y |
series name, |
delay_order |
Delay order, |
lag_length |
lag length |
trim_value |
trimmed value, .15, .10, .5 |
"Model" Estimated model
"threshold" the value of threshold
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(100) SETAR_model(x, 1, 12, .15) data(IBM) SETAR_model(IBM, 1, 12, .05)
x <- rnorm(100) SETAR_model(x, 1, 12, .15) data(IBM) SETAR_model(IBM, 1, 12, .05)
This function allows you to make Sollis(2004) nonlinear unit root test
Sollis_2004_unit_root(x, model, max_lags)
Sollis_2004_unit_root(x, model, max_lags)
x |
series name, |
model |
if model with intercept 1, if model with trend 2 if model with trend*function 3 |
max_lags |
maximum lag(optimal lag selected by AIC) |
"Model" Estimated model
"Selected lag" the lag order
"p1=p2=0 Statistic" the value of the test statistic
Sollis, R. (2004). Asymmetric adjustment and smooth transitions: a combination of some unit root tests. Journal of time series analysis, 25(3), 409-417.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
set.seed(123) x <- rnorm(1000) Sollis_2004_unit_root(x, model = 1, max_lags = 6) set.seed(123) y <- cumsum(rnorm(1000)) Sollis_2004_unit_root(y, 2, 12) data(IBM) Sollis_2004_unit_root(x = IBM, model = 3, max_lags = 3)
set.seed(123) x <- rnorm(1000) Sollis_2004_unit_root(x, model = 1, max_lags = 6) set.seed(123) y <- cumsum(rnorm(1000)) Sollis_2004_unit_root(y, 2, 12) data(IBM) Sollis_2004_unit_root(x = IBM, model = 3, max_lags = 3)
This function allows you to make Sollis(2009) nonlinear unit root test
Sollis2009_Unit_Root(x, case, lags, lsm)
Sollis2009_Unit_Root(x, case, lags, lsm)
x |
series name, |
case |
if raw data 1 if demeaned data 2 if detrended data 3, |
lags |
maximum lag |
lsm |
lag selection methods if 1 AIC, if 2 BIC, if 3 t-stat significance |
"Model" Estimated model
"Selected lag" the lag order
"Test Statistic" the value of the test statistic
Sollis, R. (2009). A simple unit root test against asymmetric STAR nonlinearity with an application to real exchange rates in Nordic countries. Economic modelling, 26(1), 118-125.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Sollis2009_Unit_Root(x, case = 1, lags = 6, lsm = 3) y <- cumsum(rnorm(1000)) Sollis2009_Unit_Root(y, 3, 8, 1) data(IBM) Sollis2009_Unit_Root(IBM,case = 2,lags = 12,lsm = 2)
x <- rnorm(1000) Sollis2009_Unit_Root(x, case = 1, lags = 6, lsm = 3) y <- cumsum(rnorm(1000)) Sollis2009_Unit_Root(y, 3, 8, 1) data(IBM) Sollis2009_Unit_Root(IBM,case = 2,lags = 12,lsm = 2)
This function allows you to make Terasvirta (1994) nonlinearity test
Terasvirta1994test(x, d, maxp)
Terasvirta1994test(x, d, maxp)
x |
series name, |
d |
delay parameter, |
maxp |
maximum p |
"Linearity" the value of the test statistic and the probability of the test statistic
"H01" the value of the test statistic and the probability of the test statistic
"H02" the value of the test statistic and the probability of the test statistic
"H03" the value of the test statistic and the probability of the test statistic
"H12" the value of the test statistic and the probability of the test statistic
Teräsvirta, T. (1994). Specification, estimation, and evaluation of smooth transition autoregressive models. Journal of the american Statistical association, 89(425), 208-218.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
x <- rnorm(1000) Terasvirta1994test(x, 3, 4) data(IBM) Terasvirta1994test(IBM, 4, 4)
x <- rnorm(1000) Terasvirta1994test(x, 3, 4) data(IBM) Terasvirta1994test(IBM, 4, 4)
This function allows you to make Vougas(2006) nonlinear unit root test
Vougas_2006_unit_root(x, model, max_lags)
Vougas_2006_unit_root(x, model, max_lags)
x |
series name, |
model |
if model A 1, if model B 2, if model C 3, model D 4, model E 5 |
max_lags |
maximum lag(optimal lag selected by AIC) |
"Model" Estimated model
"Selected lag" the lag order
"Test Statistic" the value of the test statistic
Vougas, D. V. (2006). On unit root testing with smooth transitions. Computational statistics & data analysis, 51(2), 797-800.
Burak Guris, R Uygulamalı Dogrusal Olmayan Zaman Serileri Analizi, DER Yayinevi, 2020.
set.seed(12345) x <- rnorm(1000) Vougas_2006_unit_root(x, model = 1, max_lags = 6) set.seed(12345) y <- cumsum(rnorm(1000)) Vougas_2006_unit_root(x = y ,model = 2, max_lags = 9) data(IBM) Vougas_2006_unit_root(x = IBM, model = 3, max_lags = 3)
set.seed(12345) x <- rnorm(1000) Vougas_2006_unit_root(x, model = 1, max_lags = 6) set.seed(12345) y <- cumsum(rnorm(1000)) Vougas_2006_unit_root(x = y ,model = 2, max_lags = 9) data(IBM) Vougas_2006_unit_root(x = IBM, model = 3, max_lags = 3)