earowang/hts

Forecast horizon ignored in stlf forecast

Closed this issue · 3 comments

When forecasts are made using the stlf method (one of the methods recommended by the author), the input forecast horizon is ignored and instead the default horizon of 2L * frequency(object$bts) is used. The problem can be reproduced using the code below.

nodes <- list(2, c(3, 2))
abc <- ts(5 + matrix(sort(rnorm(500)), ncol = 5, nrow = 100),frequency=4)
x <- hts(abc, nodes)
forecast(x, h = 4, method = "comb", algorithms = "lu",FUN = stlf)

Thank you!

That problem is actually caused by the forecast package. I'll fix it over there.

Now fixed

Thanks!