[R] time series has no or less than 2 periods
daniel.hickman at live.com
Thu Oct 3 17:32:26 CEST 2013
I have been tasked with taking an excel file that my colleague had implemented Triple Exponential Smoothing and recreate using R.
The following image shows the before and after of smoothing out a fixed interval time series data using Triple Exponential Smoothing inside of Excel.
enter image description here
I am trying to perform the same triple exponential smoothing in R. I created a csv file with the before smoothing data. The csv file is attached and can also be found here.
I found the HoltWinters method but I keep getting an error when I try to apply HoltWinters against the csv.
data <- read.table("TripleExpSmoothingXLS.csv", header=TRUE, sep=",")
ts <- ts(data$QtyPerWeek, frequency=52)
This results in the following error. "Error in decompose(ts(x[1L:wind], start = start(x), frequency = f), seasonal) : time series has no or less than 2 periods"
In case it helps, excel file with the triple exponential smoothing formulas and original data can be found here.
More information about the R-help