Description Usage Arguments Value Examples
Calculates ME, MAE, MASE, Coverage, and Width for a time series tibble.
1 | ts_accuracy(ts_df, lag = 1)
|
ts_df |
A tibble containing dates in column labeled 'ds' and values in column labeled 'y'. The point forecast should be in a column labeled 'yhat', and respective prediction intervals should be in columns labeled 'yhat_lower' and 'yhat_upper'. |
lag |
The lag to be used in calculating MASE, which should be the period of seasonality of the time series. |
A tibble with ME, MAE, MASE, Coverage, and Width columns.
1 2 3 4 5 6 7 8 | df <- tidyr::tibble(
ds = lubridate::today() - 100:1,
y = rnorm(100),
yhat = rnorm(100),
yhat_lower = yhat - 1,
yhat_upper = yhat + 1
)
ts_accuracy(df)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.