how to add more than two external regressors in GARCH model using rgarch
Please READ the documentation (?ugarchspec). I quote: "external.regressors...A matrix object containing the external regressors to include in the mean equation with as many rows as will be included in the data (which is passed in the fit function)." e.g. matrix(cbind(x1, x2), ncol = 2) Regards, Alexios
On 01/08/2011 22:42, zoe_zhang wrote:
Dear All, I am working on a GARCH model with two external regressors. I find the rgarch package could help and just follow the ugarchspec function which is function (variance.model = list(model = "sGARCH", garchOrder = c(1, 1), submodel = NULL, *external.regressors = NULL*, variance.targeting = FALSE), mean.model = list(armaOrder = c(1, 1), include.mean = TRUE, garchInMean = FALSE, inMeanType = 1, arfima = FALSE, external.regressors = NULL), distribution.model = "norm", start.pars = list(), fixed.pars = list(), ...) Assume I have to add two external regressors x1 and x2 . I tried external.regressors = (x1,x2) or external.regressors = x1,x2 but the result still comes out with one external regressor, does any one know how to add more than two regressors? Any suggestion would be appreciated a lot! Sincerely, Zoe -- View this message in context: http://r.789695.n4.nabble.com/how-to-add-more-than-two-external-regressors-in-GARCH-model-using-rgarch-tp3710899p3710899.html Sent from the Rmetrics mailing list archive at Nabble.com.
_______________________________________________ R-SIG-Finance at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-sig-finance -- Subscriber-posting only. If you want to post, subscribe first. -- Also note that this is not the r-help list where general R questions should go.