Applies a model-specific estimation technique to predict the values of missing values in a tsibble, and replace them.

# S3 method for ARIMA
interpolate(object, new_data, specials, ...)

Arguments

object

A model for which forecasts are required.

new_data

A tsibble containing the time points and exogenous regressors to produce forecasts for.

specials

(passed by fabletools::forecast.mdl_df()).

...

Other arguments passed to methods

Value

A tibble of the same dimension of new_data with missing values interpolated.

Examples

library(tsibbledata)

olympic_running %>%
  model(arima = ARIMA(Time ~ trend())) %>%
  interpolate(olympic_running)
#> # A tsibble: 312 x 4 [4Y]
#> # Key:       Length, Sex [14]
#>    Length Sex    Year  Time
#>     <int> <chr> <int> <dbl>
#>  1    100 men    1896  12  
#>  2    100 men    1900  11  
#>  3    100 men    1904  11  
#>  4    100 men    1908  10.8
#>  5    100 men    1912  10.8
#>  6    100 men    1916   0  
#>  7    100 men    1920  10.8
#>  8    100 men    1924  10.6
#>  9    100 men    1928  10.8
#> 10    100 men    1932  10.3
#> # ℹ 302 more rows