iterate_more | R Documentation |
iterate_more
uses a variable metric algorithm to finalize maximum likelihood
estimation of a GMVAR, StMVAR, or G-StMVAR model (object of class 'gsmvar'
) which already has preliminary estimates.
iterate_more(
gsmvar,
maxit = 100,
calc_std_errors = TRUE,
custom_h = NULL,
stat_tol = 0.001,
posdef_tol = 1e-08,
df_tol = 1e-08
)
gsmvar |
an object of class |
maxit |
the maximum number of iterations in the variable metric algorithm. |
calc_std_errors |
calculate approximate standard errors for the estimates? |
custom_h |
A numeric vector with same the length as the parameter vector: i:th element of custom_h is the difference
used in central difference approximation for partial differentials of the log-likelihood function for the i:th parameter.
If |
stat_tol |
numerical tolerance for stationarity of the AR parameters: if the "bold A" matrix of any regime
has eigenvalues larger that |
posdef_tol |
numerical tolerance for positive definiteness of the error term covariance matrices: if the error term covariance matrix of any regime has eigenvalues smaller than this, the model is classified as not satisfying positive definiteness assumption. Note that if the tolerance is too small, numerical evaluation of the log-likelihood might fail and cause error. |
df_tol |
the parameter vector is considered to be outside the parameter space if all degrees of
freedom parameters are not larger than |
The purpose of iterate_more
is to provide a simple and convenient tool to finalize
the estimation when the maximum number of iterations is reached when estimating a GMVAR, StMVAR, or G-StMVAR model
with the main estimation function fitGSMVAR
. iterate_more
is essentially a wrapper
around the function optim
from the package stats
and GSMVAR
from the package
gmvarkit
.
Returns an object of class 'gsmvar'
defining the estimated GMVAR, StMVAR, or G-StMVAR model.
Kalliovirta L., Meitz M. and Saikkonen P. 2016. Gaussian mixture vector autoregression. Journal of Econometrics, 192, 485-498.
Kalliovirta L. and Saikkonen P. 2010. Reliable Residuals for Multivariate Nonlinear Time Series Models. Unpublished Revision of HECER Discussion Paper No. 247.
Virolainen S. 2022. Gaussian and Student's t mixture vector autoregressive model with application to the asymmetric effects of monetary policy shocks in the Euro area. Unpublished working paper, available as arXiv:2109.13648.
Virolainen S. 2025. A statistically identified structural vector autoregression with endogenously switching volatility regime. Journal of Business & Economic Statistics, 43, 1, 44-54.
fitGSMVAR
, GSMVAR
, optim
,
profile_logliks
, update_numtols
## These are long running examples that use parallel computing!
## Running the below examples takes approximately 2 minutes
# GMVAR(1,2) model, only 5 iterations of the variable metric
# algorithm
fit12 <- fitGSMVAR(gdpdef, p=1, M=2, ncalls=1, maxit=5, seeds=1)
fit12
# Iterate more:
fit12_2 <- iterate_more(fit12)
fit12_2
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.