Package: sstvars 1.1.0

sstvars: Toolkit for Reduced Form and Structural Smooth Transition Vector Autoregressive Models

Maximum likelihood estimation of smooth transition vector autoregressive models with various types of transition weight functions, conditional distributions, and identification methods. Constrained estimation with various types of constraints is available. Residual based model diagnostics, forecasting, simulations, and calculation of impulse response functions, generalized impulse response functions, and generalized forecast error variance decompositions. See Heather Anderson, Farshid Vahid (1998) <doi:10.1016/S0304-4076(97)00076-6>, Helmut Lütkepohl, Aleksei Netšunajev (2017) <doi:10.1016/j.jedc.2017.09.001>, Markku Lanne, Savi Virolainen (2024) <doi:10.48550/arXiv.2403.14216>, Savi Virolainen (2024) <doi:10.48550/arXiv.2404.19707>.

Authors:Savi Virolainen [aut, cre]

sstvars_1.1.0.tar.gz
sstvars_1.1.0.zip(r-4.5)sstvars_1.1.0.zip(r-4.4)sstvars_1.1.0.zip(r-4.3)
sstvars_1.1.0.tgz(r-4.4-x86_64)sstvars_1.1.0.tgz(r-4.4-arm64)sstvars_1.1.0.tgz(r-4.3-x86_64)sstvars_1.1.0.tgz(r-4.3-arm64)
sstvars_1.1.0.tar.gz(r-4.5-noble)sstvars_1.1.0.tar.gz(r-4.4-noble)
sstvars_1.1.0.tgz(r-4.4-emscripten)sstvars_1.1.0.tgz(r-4.3-emscripten)
sstvars.pdf |sstvars.html
sstvars/json (API)
NEWS

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

Peer review:

Bug tracker:https://github.com/saviviro/sstvars/issues

Uses libs:
  • openblas– Optimized BLAS
  • c++– GNU Standard C++ Library v3
  • openmp– GCC OpenMP (GOMP) support library
Datasets:
  • acidata - A monthly U.S. data covering the period from 1961I to 2022III (735 observations) and consisting four variables. First, The Actuaries Climate Index (ACI), which is a measure of the frequency of severe weather and the extend changes in sea levels. Second, the monthly GDP growth rate constructed by the Federal Reserve Bank of Chicago from a collapsed dynamic factor analysis of a panel of 500 monthly measures of real economic activity and quarterly real GDP growth. Third, the monthly growth rate of the consumer price index (CPI). Third, an interest rate variable, which is the effective federal funds rate that is replaced by the the Wu and Xia (2016) shadow rate during zero-lower-bound periods. The Wu and Xia (2016) shadow rate is not bounded by the zero lower bound and also quantifies unconventional monetary policy measures, while it closely follows the federal funds rate when the zero lower bound does not bind.
  • gdpdef - U.S. real GDP percent change and GDP implicit price deflator percent change.
  • usacpu - A monthly U.S. data covering the period from 1987:4 to 2024:2
  • usamone - A quarterly U.S. data covering the period from 1954Q3 to 2021Q4 (270 observations) and consisting three variables: cyclical component of the log of real GDP, the log-difference of GDP implicit price deflator, and an interest rate variable. The interest rate variable is the effective federal funds rate from 1954Q3 to 2008Q2 and after that the Wu and Xia (2016) shadow rate, which is not constrained by the zero lower bound and also quantifies unconventional monetary policy measures. The log-differences of the GDP deflator and producer price index are multiplied by hundred.

On CRAN:

5.99 score 2 stars 36 scripts 617 downloads 30 exports 3 dependencies

Last updated 4 hours agofrom:a7b137039c. Checks:OK: 1 WARNING: 8. Indexed: yes.

TargetResultDate
Doc / VignettesOKNov 22 2024
R-4.5-win-x86_64WARNINGNov 22 2024
R-4.5-linux-x86_64WARNINGNov 22 2024
R-4.4-win-x86_64WARNINGNov 22 2024
R-4.4-mac-x86_64WARNINGNov 22 2024
R-4.4-mac-aarch64WARNINGNov 22 2024
R-4.3-win-x86_64WARNINGNov 22 2024
R-4.3-mac-x86_64WARNINGNov 22 2024
R-4.3-mac-aarch64WARNINGNov 22 2024

Exports:alt_stvarbound_JSRbound_jsr_Gcalc_gradientcalc_hessiancheck_paramsdiag_Omegasdiagnostic_plotfilter_estimatesfitSSTVARfitSTVARget_focget_gradientget_hessianget_socGFEVDGIRFiterate_morelinear_IRFLR_testPortmanteau_testprofile_logliksRao_testredecompose_Omegasreorder_B_columnsSTVARswap_B_signsswap_parametrizationuncond_momentsWald_test

Dependencies:pbapplyRcppRcppArmadillo

sstvars: Structural Smooth Transition Vector Autoregressive Models R

Rendered fromsstvars-vignette.Rnwusingutils::Sweaveon Nov 22 2024.

Last update: 2024-11-14
Started: 2024-01-22

Readme and manuals

Help Manual

Help pageTopics
sstvars: toolkit for reduced form and structural smooth transition vector autoregressive modelssstvars-package sstvars
A monthly U.S. data covering the period from 1961I to 2022III (735 observations) and consisting four variables. First, The Actuaries Climate Index (ACI), which is a measure of the frequency of severe weather and the extend changes in sea levels. Second, the monthly GDP growth rate constructed by the Federal Reserve Bank of Chicago from a collapsed dynamic factor analysis of a panel of 500 monthly measures of real economic activity and quarterly real GDP growth. Third, the monthly growth rate of the consumer price index (CPI). Third, an interest rate variable, which is the effective federal funds rate that is replaced by the the Wu and Xia (2016) shadow rate during zero-lower-bound periods. The Wu and Xia (2016) shadow rate is not bounded by the zero lower bound and also quantifies unconventional monetary policy measures, while it closely follows the federal funds rate when the zero lower bound does not bind.acidata
Construct a STVAR model based on results from an arbitrary estimation round of 'fitSTVAR'alt_stvar
Calculate upper bound for the joint spectral radius of the "companion form AR matrices" of the regimesbound_JSR
Calculate upper bound for the joint spectral radius of a set of matricesbound_jsr_G
Calculate gradient or Hessian matrixcalc_gradient calc_hessian get_foc get_gradient get_hessian get_soc
Check whether the parameter vector is in the parameter space and throw error if notcheck_params
Simultaneously diagonalize two covariance matricesdiag_Omegas
Residual diagnostic plot for a STVAR modeldiagnostic_plot
Filter inappropriate the estimates produced by fitSTVARfilter_estimates
Maximum likelihood estimation of a structural STVAR model based on preliminary estimates from a reduced form model.fitSSTVAR
Two-phase or three-phase maximum likelihood estimation of a reduced form smooth transition VAR modelfitSTVAR
Genetic algorithm for preliminary estimation of reduced form STVAR modelsGAfit
U.S. real GDP percent change and GDP implicit price deflator percent change.gdpdef
Switch from two-regime reduced form STVAR model to a structural model identified by heteroskedasticityget_hetsked_sstvar
Estimate generalized forecast error variance decomposition for structural STVAR models.GFEVD plot.gfevd print.gfevd
Estimate generalized impulse response function for structural STVAR models.GIRF plot.girf print.girf
Determine whether the parameter vector is in the parameter spacein_paramspace
Maximum likelihood estimation of a reduced form or structural STVAR model based on preliminary estimatesiterate_more
Estimate linear impulse response function based on a single regime of a structural STVAR model.linear_IRF plot.irf print.irf
Perform likelihood ratio test for a STVAR modelLR_test
Predict method for class 'stvar' objectsplot.stvarpred predict.stvar print.stvarpred
Perform adjusted Portmanteau test for a STVAR modelPortmanteau_test
Print method for the class hypotestprint.hypotest
Summary print method from objects of class 'stvarsum'print.stvarsum
Plot profile log-likelihood functions about the estimatesprofile_logliks
Perform Rao's score test for a STVAR modelRao_test
In the decomposition of the covariance matrices (Muirhead, 1982, Theorem A9.9), change the ordering of the covariance matrices.redecompose_Omegas
Reorder columns of impact matrix B (and lambda parameters if any) of a structural STVAR model that is identified by heteroskedasticity or non-Gaussianity.reorder_B_columns
Simulate method for class 'stvar' objectssimulate.stvar
Create a class 'stvar' object defining a reduced form or structural smooth transition VAR modellogLik.stvar plot.stvar print.stvar residuals.stvar STVAR summary.stvar
Swap all signs in pointed columns of the impact matrix of a structural STVAR model that is identified by heteroskedasticity or non-Gaussianityswap_B_signs
Swap the parametrization of a STVAR modelswap_parametrization
Calculate the unconditional means, variances, the first p autocovariances, and the first p autocorrelations of the regimes of the model.uncond_moments
A monthly U.S. data covering the period from 1987:4 to 2024:2 (443 observations) and consisting six variables. First, the climate policy uncertainty index (CPUI) (Gavridiilis, 2021), which is a news based measure of climate policy uncertainty. Second, the economic policy uncertainty index (EPUI), which is a news based measure of economic policy uncertainty. Third, the log-difference of real indsitrial production index (IPI). Fourth, the log-difference of the consumer price index (CPI). Fifth, the log-difference of the producer price index (PPI). Sixth, an interest rate variable, which is the effective federal funds rate that is replaced by the the Wu and Xia (2016) shadow rate during zero-lower-bound periods. The Wu and Xia (2016) shadow rate is not bounded by the zero lower bound and also quantifies unconventional monetary policy measures, while it closely follows the federal funds rate when the zero lower bound does not bind. This is the dataset used in Virolainen (2024)usacpu
A quarterly U.S. data covering the period from 1954Q3 to 2021Q4 (270 observations) and consisting three variables: cyclical component of the log of real GDP, the log-difference of GDP implicit price deflator, and an interest rate variable. The interest rate variable is the effective federal funds rate from 1954Q3 to 2008Q2 and after that the Wu and Xia (2016) shadow rate, which is not constrained by the zero lower bound and also quantifies unconventional monetary policy measures. The log-differences of the GDP deflator and producer price index are multiplied by hundred.usamone
Perform Wald test for a STVAR modelWald_test