I am trying to decompose a daily time series, however this gives an
Error 'only univariate series are allowed'
When I have clearly converted the daily data in to time series using the ts function. How can I fix this?
I have tried solutions from other posts but none has worked for me. My data comprise of 669
observations, where the data spans from Jan 2017 to March 2019
.
SCTB.LV.TS = ts(SCTB_TS[,-1], start = c(2017,6,01), frequency = 365)
SCTB.LV.TS
decomp <- stl(log(SCTB.LV.TS), s.window = 'Periodic')
Before converting the data frame to time series the data looks like below
Date Count
6/1/2017 329
6/2/2017 284
6/3/2017 429
6/4/2017 454
6/5/2017 362
6/6/2017 334
6/7/2017 369
6/8/2017 319
6/9/2017 349
6/10/2017 373
6/11/2017 456
6/12/2017 344