business-science / sweep

Extending broom for time series forecasting
https://business-science.github.io/sweep/
155 stars 31 forks source link

sw_sweep produces a type_convert warning I don't understand #15

Open Someone894 opened 3 years ago

Someone894 commented 3 years ago

For several yeas now I happily use the sweep package, many thanks to you for this great package :-) Recently I discovered a strange warning, that never happened on older versions. The output of the function is still the same, so it is a minor issue, but id like to understand whats going on and if it's save to ignore this warning.

Based on your Vignette I've wrote an MWE to illustrate the warning:

library(magrittr)

result <- fpp2::a10 %>%
  forecast::ets() %>%
  forecast::forecast(h = 12)

sweep::sw_sweep(result, fitted = FALSE)

Here is the resulting data + the warning

# A tibble: 216 x 7
   index     key    value lo.80 lo.95 hi.80 hi.95
   <yearmon> <chr>  <dbl> <dbl> <dbl> <dbl> <dbl>
 1 Jul 1991  actual  3.53    NA    NA    NA    NA
 2 Aug 1991  actual  3.18    NA    NA    NA    NA
 3 Sep 1991  actual  3.25    NA    NA    NA    NA
 4 Okt 1991  actual  3.61    NA    NA    NA    NA
 5 Nov 1991  actual  3.57    NA    NA    NA    NA
 6 Dez 1991  actual  4.31    NA    NA    NA    NA
 7 Jan 1992  actual  5.09    NA    NA    NA    NA
 8 Feb 1992  actual  2.81    NA    NA    NA    NA
 9 Mrz 1992  actual  2.99    NA    NA    NA    NA
10 Apr 1992  actual  3.20    NA    NA    NA    NA
# ... with 206 more rows
Warning:
1: `type_convert()` only converts columns of type 'character'.
- `df` has no columns of type 'character' 
2: `type_convert()` only converts columns of type 'character'.
- `df` has no columns of type 'character' 

Do you have any idea what this means, where it comes from and whether it is dangerous?