Time Series Decomposition Error - Time Series has no or less than 2 periods

I am trying to decompose a time series of daily precipitation data from 2010 to 2022. When I use the decompose() function in RStudio I receive the error "Error in decompose(precipSMA100) : time series has no or less than two periods". Does anyone have any advice on how to get around this error?


This will happen if the time series attributes of the data have not been set, or have been set incorrectly. Try this:

precipSMA100 <- ts(precipSMA100, start = 2010, frequency = 365)

This topic was automatically closed 42 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.