tidyverts / feasts

Feature Extraction And Statistics for Time Series
https://feasts.tidyverts.org/
295 stars 23 forks source link

Same error here... Error in stop_vctrs(): ! <interval> + <integer> is not permitted #148

Closed Steviey closed 2 years ago

Steviey commented 2 years ago

got the same error with feasts...

repr. example here: https://github.com/tidyverts/tsibble/issues/278

df     <- df %>% as_tsibble(index=id,key=name)
myPlot  <- df %>% group_by(name) %>%
feasts::ACF(value) %>% feasts::autoplot()
print(myPlot)

Error in `stop_vctrs()`:
! <interval> + <integer> is not permitted
mitchelloharawild commented 2 years ago

Note that when you load dlookr, it overwrites the tsibble:::format.interval method with inum:::format.interval. Like the previous fix you've linked, I specifically use the tsibble method in the plot function now.

library(feasts)
#> Loading required package: fabletools
library(dlookr)
#> Registered S3 method overwritten by 'inum':
#>   method          from   
#>   format.interval tsibble
#> 
#> Attaching package: 'dlookr'
#> The following object is masked from 'package:base':
#> 
#>     transform
tsibbledata::vic_elec %>% ACF(Temperature) %>% autoplot()

Created on 2022-08-25 by the reprex package (v2.0.1)