To solve the error before using SS, do a double transpose to the time series
example
the following works:
m2=NULL
m2 <- SS( t(t(ts(runif(100, 5.0, 7.5)))))
m2.n=1;
m2.p=1;
m2.f <- kfilter(m2)
plot(m2$y)
lines(m2$y,lty=2,col="green")
lines(m2.f$m,lty=2,col="red")
but dont forget to first install the sspir package using
install.packages("sspir")
and loading the library using
library(sspir)
No comments:
Post a Comment