rugarch (default)
The engine uses rugarch::multispec()
and then rugarch::multifit()
Main Arguments
type
: You can choose between ugarchspec
(default) or arfimaspec
. Depending on which one you choose,
you will select either a univariate GARCH model for each of your variables or an Arfima model as specification,
which will then be passed to rugarch::multispec()
.
You must pass an argument through set_engine()
called specs which will
be a list consisting of the arguments to be passed to each of the specifications used
in rugarch::multispec()
. Other arguments that you wish to pass to rugarch::multifit()
can
also be passed through set_engine()
For example, imagine you have a data frame with 3 variables. For each of those variables you must
define a specification (you can check the arguments you can use for a specification in ?rugarch::ugarchspec).
Once the specifications have been decided, the way to pass it through set_engine would be as follows:
garch_multivariate_reg(mode = "regression") %>%
set_engine("rugarch" , specs = list(spec1 = list(mean.model = list(armaOrder = c(1,0))),
spec2 = list(mean.model = list(armaOrder = c(1,0))),
spec3 = list(mean.model = list(armaOrder = c(1,0)))),
out.sample = 10)
In the fit section we will see how to pass variables through parsnip::fit (See Fit Section below).
Parameter Notes:
xreg
- This engine does support xregs, but you have to provide them to each model in an
array through set_engine. For more information see ?rugarch::ugarchspec. The xregs can be provided
through variance.model$external.regressors
or mean.model$external.regressors
(or both) for the
specifications of the desired variables.
dcc_rmgarch
The engine uses rugarch::multispec()
, rugarch::multifit()
, rmgarch::dccspec()
and rmgarch::dccfit()
.
Main Arguments
You must pass an argument through set_engine()
called specs which will
be a list consisting of the arguments to be passed to each of the specifications used
in rugarch::multispec()
. Other arguments that you wish to pass to rugarch::multifit()
can
also be passed through set_engine()
. To pass arguments to dccfit()
you must pass a list through
set_engine
called dcc_specs.
For example, imagine you have a data frame with 3 variables. For each of those variables you must
define a specification (you can check the arguments you can use for a specification in ?rugarch::ugarchspec).
Once the specifications have been decided, the way to pass it through set_engine would be as follows:
garch_fit_model <- garch_multivariate_reg(type = "ugarchspec") %>%
set_engine("dcc_rmgarch" , specs = list(spec1 = list(mean.model = list(armaOrder = c(1,0))),
spec2 = list(mean.model = list(armaOrder = c(1,0))),
spec3 = list(mean.model = list(armaOrder = c(1,0)))),
dcc_specs = list(dccOrder = c(2,2), distribution = "mvlaplace"))
In the fit section we will see how to pass variables through parsnip::fit (See Fit Section below).
c_rmgarch
The engine uses rugarch::multispec()
, rugarch::multifit()
, rmgarch::cgarchspec()
and rmgarch::cgarchfit()
.
Main Arguments
You must pass an argument through set_engine()
called specs which will
be a list consisting of the arguments to be passed to each of the specifications used
in rugarch::multispec()
. Other arguments that you wish to pass to rugarch::multifit()
can
also be passed through set_engine()
. To pass arguments to cgarchfit()
you must pass a list through
set_engine
called c_specs.
For example, imagine you have a data frame with 3 variables. For each of those variables you must
define a specification (you can check the arguments you can use for a specification in ?rugarch::ugarchspec).
Once the specifications have been decided, the way to pass it through set_engine would be as follows:
garch_fit_model <- garch_multivariate_reg(type = "arfima") %>%
set_engine("c_rmgarch" , specs = list(spec1 = list(mean.model = list(armaOrder = c(1,0))),
spec2 = list(mean.model = list(armaOrder = c(1,0))),
spec3 = list(mean.model = list(armaOrder = c(1,0)))),
c_specs = list(dccOrder = c(2,2))) %>%
fit(value ~ date + id, data = rX_longer_train)
In the fit section we will see how to pass variables through parsnip::fit (See Fit Section below).
gogarch_rmgarch
The engine uses rmgarch::gogarchspec()
and rmgarch::gogarchfit()
.
Main Arguments
You must pass an argument through set_engine()
called gogarch_specs which will
be a list consisting of the arguments to be passed to each of the specifications used
in rmgarch::gogarchspec()
. Other arguments that you wish to pass to rmgarch::gogarchfit()
can
also be passed through set_engine()
.
For example, imagine you have a data frame with 3 variables. For each of those variables you must
define a specification (you can check the arguments you can use for a specification in ?rugarch::ugarchspec).
Once the specifications have been decided, the way to pass it through set_engine would be as follows:
model_fit_garch <- garch_multivariate_reg(type = "ugarchspec") %>%
set_engine("gogarch_rmgarch" , gogarch_specs = list(variance.model = list(garchOrder = c(2,2)))) %>%
fit(value ~ date + id, data = rX_longer_train)
In the fit section we will see how to pass variables through parsnip::fit (See Fit Section below).