【发布时间】:2021-07-17 22:46:41
【问题描述】:
我正在尝试开始使用 R 中的 fable 包进行预测。
我正在使用他们website中的基本示例:
我正在尝试运行以下示例,但它永远不会运行,它会永远运行。
我已经升级了我的 RStudio 版本,不得不多次重启,但都没有成功。
library(fable)
library(tsibble)
library(tsibbledata)
library(lubridate)
library(dplyr)
aus_retail %>%
filter(
State %in% c("New South Wales", "Victoria"),
Industry == "Department stores"
) %>%
model(
ets = ETS(box_cox(Turnover, 0.3)),
arima = ARIMA(log(Turnover)),
snaive = SNAIVE(Turnover)
) %>%
forecast(h = "2 years") %>%
autoplot(filter(aus_retail, year(Month) > 2010), level = NULL)
这是我的 sessioninfo()
> sessionInfo()
R version 4.0.2 (2020-06-22)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19042)
Matrix products: default
locale:
[1] LC_COLLATE=English_Ireland.1252 LC_CTYPE=English_Ireland.1252
[3] LC_MONETARY=English_Ireland.1252 LC_NUMERIC=C
[5] LC_TIME=English_Ireland.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] compiler_4.0.2 magrittr_2.0.1 ellipsis_0.3.1 cli_2.4.0 tools_4.0.2
[6] pillar_1.5.1 glue_1.4.2 rstudioapi_0.13 tibble_3.1.0 crayon_1.4.1
[11] utf8_1.2.1 fansi_0.4.1 vctrs_0.3.4 hardhat_0.1.5 lifecycle_1.0.0
[16] pkgconfig_2.0.3 rlang_0.4.10
任何建议将不胜感激
【问题讨论】:
-
我在
mac中尝试了R 4.1.0和packageVersion('fable')# [1] ‘0.3.1’,packageVersion('tsibble')# [1] ‘1.0.1’,它工作正常 -
你的
sessionInfo没有包含那些重要的包裹信息