Extracts the fitted values.

# S3 method for ETS
fitted(object, ...)

Arguments

object

A model for which forecasts are required.

...

Other arguments passed to methods

Value

A vector of fitted values.

Examples

as_tsibble(USAccDeaths) %>%
  model(ets = ETS(log(value) ~ season("A"))) %>%
  fitted()
#> # A tsibble: 72 x 3 [1M]
#> # Key:       .model [1]
#>    .model    index .fitted
#>    <chr>     <mth>   <dbl>
#>  1 ets    1973 Jan   8966.
#>  2 ets    1973 Feb   8115.
#>  3 ets    1973 Mar   8976.
#>  4 ets    1973 Apr   9182.
#>  5 ets    1973 May  10076.
#>  6 ets    1973 Jun  10537.
#>  7 ets    1973 Jul  11626.
#>  8 ets    1973 Aug  10652.
#>  9 ets    1973 Sep   9525.
#> 10 ets    1973 Oct   9927.
#> # ℹ 62 more rows