-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Paste your results for one-week ahead forecasts of rotavirus in Berlin #1
Comments
Example: library("hhh4addon")
data("rotaBE")
ctrl <- list(end = list(f = addSeason2formula(~0 + fe(1, unitSpecific = TRUE),
S = 1)),
ar = list(f = ~ 0 + fe(1, unitSpecific = TRUE)),
family = "NegBin1",
subset = 6:312)
fit <- hhh4(rotaBE, ctrl)
owa <- oneStepAhead(fit, tp = c(312, 363))
colMeans(scores(owa))
|
library("hhh4addon")
data("rotaBE")
## let the power law act on (o+1) => AR is integrated in NE
rotaBE1 <- rotaBE
neighbourhood(rotaBE1) <- neighbourhood(rotaBE1) + 1
form1 <- ~ 0 + fe(1, unitSpecific = TRUE)
ctrl <- list(end = list(f = addSeason2formula(form1, S = 2)),
ne = list(f = addSeason2formula(form1, S = 2),
weights = W_powerlaw(maxlag = max(neighbourhood(rotaBE1)))),
family = "NegBinM", subset = 6:312)
fit <- hhh4(rotaBE1, ctrl)
plot(fit, total = TRUE)
owa <- oneStepAhead(fit, tp = c(312, 363))
colMeans(scores(owa))
Did anyone achieve something smaller? I observed that some more complicated models do not converge at all time points during the rolling forecasts. One could use |
library("hhh4addon")
data("rotaBE")
## let the power law act on (o+1) => AR is integrated in NE
rotaBE1 <- rotaBE
neighbourhood(rotaBE1) <- neighbourhood(rotaBE1) + 1
form1 <- ~ 0 + fe(1, unitSpecific = TRUE)
ctrl <- list(end = list(f = addSeason2formula(form1, S = 2)),
ne = list(f = addSeason2formula(form1, S = 2),
weights = W_powerlaw(maxlag = max(neighbourhood(rotaBE1)))),
family = "NegBinM", subset = 6:312)
fit <- profile_par_lag(rotaBE1, ctrl)
plot(fit, total = TRUE)
owa <- oneStepAhead_hhh4lag(fit, tp = c(312, 363))
colMeans(scores(owa))
Just a little tweak ;) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can paste the return of
colMeans(scores(owa))
here, if you like along with your control argument or a little piece of R code. See my example post below.The text was updated successfully, but these errors were encountered: