Package: tsDyn 11.0.5.2

tsDyn: Nonlinear Time Series Models with Regime Switching

Implements nonlinear autoregressive (AR) time series models. For univariate series, a non-parametric approach is available through additive nonlinear AR. Parametric modeling and testing for regime switching dynamics is available when the transition is either direct (TAR: threshold AR) or smooth (STAR: smooth transition AR, LSTAR). For multivariate series, one can estimate a range of TVAR or threshold cointegration TVECM models with two or three regimes. Tests can be conducted for TVAR as well as for TVECM (Hansen and Seo 2002 and Seo 2006).

Authors:Antonio Fabio Di Narzo [aut], Jose Luis Aznarte [ctb], Matthieu Stigler [aut, cre]

tsDyn_11.0.5.2.tar.gz
tsDyn_11.0.5.2.zip(r-4.5)tsDyn_11.0.5.2.zip(r-4.4)tsDyn_11.0.5.2.zip(r-4.3)
tsDyn_11.0.5.2.tgz(r-4.4-x86_64)tsDyn_11.0.5.2.tgz(r-4.4-arm64)tsDyn_11.0.5.2.tgz(r-4.3-x86_64)tsDyn_11.0.5.2.tgz(r-4.3-arm64)
tsDyn_11.0.5.2.tar.gz(r-4.5-noble)tsDyn_11.0.5.2.tar.gz(r-4.4-noble)
tsDyn_11.0.5.2.tgz(r-4.4-emscripten)tsDyn_11.0.5.2.tgz(r-4.3-emscripten)
tsDyn.pdf |tsDyn.html
tsDyn/json (API)
NEWS

# Install 'tsDyn' in R:
install.packages('tsDyn', repos = c('https://matthieustigler.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/matthieustigler/tsdyn/issues

Datasets:
  • IIPUs - US monthly industrial production from Hansen
  • UsUnemp - US unemployment series used in Caner and Hansen
  • barry - Time series of PPI used as example in Bierens and Martins
  • m.unrate - Monthly US unemployment
  • setarTest_IIPUs_results - Results from the setarTest, applied on Hansen (1999) data
  • zeroyld - Zeroyld time series
  • zeroyldMeta - Zeroyld time series

On CRAN:

9.63 score 34 stars 3 packages 632 scripts 2.8k downloads 72 exports 54 dependencies

Last updated 8 days agofrom:3d5f10527d. Checks:OK: 9. Indexed: yes.

TargetResultDate
Doc / VignettesOKOct 29 2024
R-4.5-win-x86_64OKOct 29 2024
R-4.5-linux-x86_64OKOct 29 2024
R-4.4-win-x86_64OKOct 29 2024
R-4.4-mac-x86_64OKOct 29 2024
R-4.4-mac-aarch64OKOct 29 2024
R-4.3-win-x86_64OKOct 29 2024
R-4.3-mac-x86_64OKOct 29 2024
R-4.3-mac-aarch64OKOct 29 2024

Exports:aaraccuracy_stataddRegimear_meanautopairsautotriplesautotriples.rglavailableModelsBBCTestcharac_rootcoefAcoefBcoefPIcomputeGradientdeltadelta.lindelta.lin.testdelta.testdsigmoidfevdgetThGIRFirfisLinearKapShinTestlags.selectlinearlinear.bootlinear.simlineVarllarllar.fittedllar.predictlstarMakeThSpecMAPEmsenlarnnetTsplot_ECTpredict_rollingrank.selectrank.testregimeresample_vecresVarselectLSTARselectNNETselectSETARsetarsetar.bootsetar.simsetarTestsigmoidstartidyTVARTVAR.bootTVAR.LRtestTVAR.simTVECMTVECM.bootTVECM.HStestTVECM.SeoTestTVECM.simVAR.bootVAR.simVARrepVECMVECM_symbolicVECM.bootVECM.sim

Dependencies:clicodetoolscolorspacecurldeSolvefansifarverforeachforecastfracdiffgenericsggplot2gluegtableisobanditeratorsjsonlitelabelinglatticelifecyclelmtestmagrittrMASSMatrixmgcvmnormtmunsellnlmennetpillarpkgconfigquadprogquantmodR6RColorBrewerRcppRcppArmadillorlangsandwichscalesstrucchangetibbletimeDatetseriestseriesChaosTTRurcautf8varsvctrsviridisLitewithrxtszoo

Threshold cointegration: overview and implementation in R

Rendered fromThCointOverview.Rnwusingutils::Sweaveon Oct 29 2024.

Last update: 2020-12-03
Started: 2012-02-13

tsDyn: Nonlinear autoregressive time series models in R

Rendered fromtsDyn.Stexusingutils::Sweaveon Oct 29 2024.

Last update: 2020-11-30
Started: 2012-02-13

Readme and manuals

Help Manual

Help pageTopics
Getting started with the tsDyn packagetsDyn-package tsDyn
Additive nonlinear autoregressive modelAAR aar plot.aar print.aar summary.aar
Forecasting accuracy measures.accuracy_stat accuracy_stat.default accuracy_stat.pred_roll
addRegime testaddRegime
Long-term mean of an AR(p) processar_mean ar_mean.linear ar_mean.lstar ar_mean.setar
Bivariate time series plotsautopairs
Trivariate time series plotsautotriples
Interactive trivariate time series plotsautotriples.rgl
Available modelsavailableModels
Time series of PPI used as example in Bierens and Martins (2010)barry
Test of unit root against SETAR alternativeBBCTest
Characteristic roots of the AR coefficientscharac_root charac_root.nlar
Extract cointegration parameters A, B and PIcoefA coefA.ca.jo coefA.VECM coefB coefB.ca.jo coefB.VECM coefPI
delta test of conditional independencedelta delta.test
delta test of linearitydelta.lin delta.lin.test
Forecast Error Variance Decompositionfevd.nlVar
fitted method for objects of class nlVar, i.e. VAR and VECM models.fitted fitted.nlVar
Extract threshold(s) coefficientgetTh getTh.default
Generalized Impulse response Function (GIRF)GIRF GIRF.linear GIRF.nlVar GIRF.setar plot.GIRF_df
US monthly industrial production from Hansen (1999)IIPUs
Impulse response functionirf.ar irf.linear irf.nlVar irf.setar irf.TVAR irf.TVECM irf.VAR irf.VECM
isLinearisLinear
Test of unit root against SETAR alternative withKapShinTest
Selection of the lag with Information criterion.lags.select
Linear AutoRegressive modelsLINEAR linear print.linear print.summary.linear summary.linear
Multivariate linear models: VAR and VECMlineVar
Locally linear modelas.data.frame.llar llar llar.fitted llar.predict plot.llar print.llar
Extract Log-LikelihoodlogLik.nlVar logLik.VAR logLik.VECM
Logistic Smooth Transition AutoRegressive modelLSTAR lstar
Monthly US unemploymentm.unrate
Specification of the threshold searchMakeThSpec makeThSpec
Mean Absolute Percent ErrorMAPE MAPE.default
Mean Square Errormse mse.default
NLAR methodsAIC.nlar BIC.nlar coef.nlar deviance.nlar fitted.nlar MAPE.nlar mse.nlar nlar-methods plot.nlar residuals.nlar summary.nlar toLatex.nlar
Neural Network nonlinear autoregressive modelNNET nnetTs
Plotting methods for SETAR and LSTAR subclassesplot-methods plot.lstar plot.setar
Plot the Error Correct Term (ECT) responseplot_ECT
Rolling forecastspredict_rolling predict_rolling.nlVar
Predict method for objects of class ''nlar''.predict predict.nlar
Predict method for objects of class ''VAR'', ''VECM'' or ''TVAR''predict.TVAR predict.VAR predict.VECM
Selection of the cointegrating rank with Information criterion.as.data.frame.rank.select print.rank.select rank.select summary.rank.select
Test of the cointegrating rankprint.rank.test rank.test summary.rank.test
Extract a variable showing the regimeregime regime.default regime.lstar
Resampling schemesresample_vec
Residual varianceresVar
Automatic selection of model hyper-parametersselectLSTAR selectNNET
Automatic selection of SETAR hyper-parametersselectSETAR selectSetar selectsetar
Self Threshold Autoregressive modelSETAR setar summary.setar
Simulation and bootstrap of Threshold Autoregressive model (SETAR)linear.boot linear.sim setar.boot setar.sim
Test of linearity against threshold (SETAR)setarTest setartest
Results from the setarTest, applied on Hansen (1999) datasetarTest_IIPUs_results
sigmoid functionsd2sigmoid dsigmoid sigmoid
STAR modelSTAR star
Latex representation of fitted setar modelstoLatex.setar
Multivariate Threshold Vector Autoregressive modelOlsTVAR TVAR
Test of linearityTVAR.LRtest
Simulation of a multivariate Threshold Autoregressive model (TVAR)TVAR.boot TVAR.sim
Threshold Vector Error Correction model (VECM)TVECM
Test of linear cointegration vs threshold cointegrationTVECM.HStest
No cointegration vs threshold cointegration testTVECM.SeoTest
Simulation and bootstrap a VECM or bivariate TVECMTVECM.boot TVECM.sim VECM.boot VECM.sim
US unemployment series used in Caner and Hansen (2001)UsUnemp
Simulate or bootstrap a VAR modelVAR.boot VAR.sim
VAR representationVARrep VARrep.VAR VARrep.VECM
Estimation of Vector error correction model (VECM)VECM
Virtual VECM modelVECM_symbolic
zeroyld time serieszeroyld zeroyldMeta