Reputation: 1
I am trying to do VaR backtesting using ugarchroll (rugarch). When setting the solver to "hybrid", the model still does not converge. Is there anything I could do?
This is my code:
arima_fit<- auto.arima(as.numeric(**data**),stationary=TRUE,ic = "bic", trace =TRUE)
p <- arima_fit$arma[1]
q <- arima_fit$arma[2]
garchspec = ugarchspec(mean.model = list(armaOrder = c(p,q)),
variance.model = list(model = "sGARCH"),
distribution.model = "sstd")
garchfit = ugarchfit(data = **data**, spec = garchspec)
garchroll = ugarchroll(spec = garchspec , data = **data**, n.start = nstart, refit.every = 1,
refit.window = "recursive", calculate.VaR=TRUE, VaR.alpha = alpha, solver = "hybrid")
This is my data:
structure(list(somedata = c(0.034, 0.002, 0.036, 0.024, 0.004,
0.034, 0.012, 0.035, 0.003, 0.019, 0.028, 0.044, 0.011, 0.011,
0.005, 0.008, 0.041, 0.017, -0.002, 0.022, -0.008, 0.034, 0.033,
0.004, 0.019, 0.009, 0.04, 0.029, 0.01, 0.032, 0.039, 0.024,
0.018, 0.011, 0.017, -0.004, 0.04, 0.013, 0.022, 0.022, -0.002,
0.039, 0.024, 0.007, 0.019, 0.015, 0.05, 0.016, 0.015, 0.006,
0.003, 0.033, 0.028, 0.021, 0.009, 0.03, 0.033, 0.007, 0.01,
0.03, -0.001, 0.03, 0.008, 0.034, 0.014, 0.016, 0.048, 0.012,
0.005, 0.001, 0.034, 0.033, 0.023, 0.012, 0.019, 0.012, 0.036,
0.021, 0.006, 0.007, 0.02, 0.046, 0.019, 0.008, 0.002, 0.028,
0.03, 0.004, 0.007, 0.011, 0.03, 0.025, 0.028, 0.013, 0.046,
0.008, -0.006, 0.044, 0.019, -0.001, 0.017, 0.033, 0.046, 0.018,
0.012, 0.002, 0.025, 0.041, 0.014, 0.011, 0.03, 0.013, 0.067,
0.01, 0.015, 0.012, 0.005, 0.035, 0.033, 0.044, 0, 0.031, 0.035,
0.018, 0.019, 0.018, 0.004, 0.026, 0.036, 0.032, 0.02, 0.014,
0.065, 0.008, 0.023, 0.021, 0.025, 0.008, 0.032, 0.005, 0.064,
0.024, 0.025, 0.018, 0.023, 0.02, 0.032, 0.039, 0.03, 0.02, 0.003,
0.052, 0.009, 0.009, 0.003, 0.017, 0.034, 0.015, 0.018, 0.018,
0.023, 0.066, 0.014, -0.007, -0.004, 0.022, 0.022, 0.016, 0.022,
0.007, 0.027, 0.022, 0.031, 0.002, 0.032, 0.023, -0.023, 0.006,
0.034, 0.013, 0.005, 0.029, 0.012, -0.024, 0.032, 0.016, 0.028,
0.015, 0.027, -0.001, 0.008, 0.037, 0.018, 0.02, 0.014, 0.015,
0.045, 0.013, 0.019, 0.01, 0.021, 0.034, 0.015, 0.004, 0.01,
0.007, 0.03, 0.022, 0.015, 0.026, 0.014, 0.038, 0.019, 0.016,
0.018, 0.035, 0.015)), class = "data.frame", row.names = c("2023-06-01",
"2023-06-02", "2023-06-05", "2023-06-06", "2023-06-07", "2023-06-08",
"2023-06-09", "2023-06-12", "2023-06-13", "2023-06-14", "2023-06-15",
"2023-06-16", "2023-06-19", "2023-06-20", "2023-06-21", "2023-06-22",
"2023-06-23", "2023-06-26", "2023-06-27", "2023-06-28", "2023-06-29",
"2023-06-30", "2023-07-03", "2023-07-04", "2023-07-05", "2023-07-06",
"2023-07-07", "2023-07-10", "2023-07-11", "2023-07-12", "2023-07-13",
"2023-07-14", "2023-07-17", "2023-07-18", "2023-07-19", "2023-07-20",
"2023-07-21", "2023-07-24", "2023-07-25", "2023-07-26", "2023-07-27",
"2023-07-28", "2023-07-31", "2023-08-01", "2023-08-02", "2023-08-03",
"2023-08-04", "2023-08-07", "2023-08-08", "2023-08-09", "2023-08-10",
"2023-08-11", "2023-08-14", "2023-08-15", "2023-08-16", "2023-08-17",
"2023-08-18", "2023-08-21", "2023-08-22", "2023-08-23", "2023-08-24",
"2023-08-25", "2023-08-28", "2023-08-29", "2023-08-30", "2023-08-31",
"2023-09-01", "2023-09-04", "2023-09-05", "2023-09-06", "2023-09-07",
"2023-09-08", "2023-09-11", "2023-09-12", "2023-09-13", "2023-09-14",
"2023-09-15", "2023-09-18", "2023-09-19", "2023-09-20", "2023-09-21",
"2023-09-22", "2023-09-25", "2023-09-26", "2023-09-27", "2023-09-28",
"2023-09-29", "2023-09-30", "2023-10-02", "2023-10-03", "2023-10-04",
"2023-10-05", "2023-10-06", "2023-10-09", "2023-10-10", "2023-10-11",
"2023-10-12", "2023-10-13", "2023-10-16", "2023-10-17", "2023-10-18",
"2023-10-19", "2023-10-20", "2023-10-23", "2023-10-24", "2023-10-25",
"2023-10-26", "2023-10-27", "2023-10-30", "2023-10-31", "2023-11-01",
"2023-11-02", "2023-11-03", "2023-11-06", "2023-11-07", "2023-11-08",
"2023-11-09", "2023-11-10", "2023-11-13", "2023-11-14", "2023-11-15",
"2023-11-16", "2023-11-17", "2023-11-20", "2023-11-21", "2023-11-22",
"2023-11-23", "2023-11-24", "2023-11-27", "2023-11-28", "2023-11-29",
"2023-11-30", "2023-12-01", "2023-12-04", "2023-12-05", "2023-12-06",
"2023-12-07", "2023-12-08", "2023-12-11", "2023-12-12", "2023-12-13",
"2023-12-14", "2023-12-15", "2023-12-18", "2023-12-19", "2023-12-20",
"2023-12-21", "2023-12-22", "2023-12-26", "2023-12-27", "2023-12-28",
"2023-12-29", "2023-12-31", "2024-01-02", "2024-01-03", "2024-01-04",
"2024-01-05", "2024-01-08", "2024-01-09", "2024-01-10", "2024-01-11",
"2024-01-12", "2024-01-15", "2024-01-16", "2024-01-17", "2024-01-18",
"2024-01-19", "2024-01-22", "2024-01-23", "2024-01-24", "2024-01-25",
"2024-01-26", "2024-01-29", "2024-01-30", "2024-01-31", "2024-02-01",
"2024-02-02", "2024-02-05", "2024-02-06", "2024-02-07", "2024-02-08",
"2024-02-09", "2024-02-12", "2024-02-13", "2024-02-14", "2024-02-15",
"2024-02-16", "2024-02-19", "2024-02-20", "2024-02-21", "2024-02-22",
"2024-02-23", "2024-02-26", "2024-02-27", "2024-02-28", "2024-02-29",
"2024-03-01", "2024-03-04", "2024-03-05", "2024-03-06", "2024-03-07",
"2024-03-08", "2024-03-11", "2024-03-12", "2024-03-13", "2024-03-14",
"2024-03-15", "2024-03-18", "2024-03-19", "2024-03-20", "2024-03-21",
"2024-03-22", "2024-03-25", "2024-03-26", "2024-03-27", "2024-03-28",
"2024-03-31"))
Upvotes: 0
Views: 20