Hi Phani,
something like this looks promising:
#
library(forecast)
library(Mcomp)
MAPE.for.Holt <- function (x,series,bignum=10e6) {
foo <-
try(ets(series$x,model="AAN",damped=FALSE,alpha=x[1],beta=x[2],restrict=FALSE),silent=TRUE)
if ( class(f
Hey,
Thanks for the tip Stephan. But you could tell me how to pass the series to
the function calling ets?
Initially I planned to do it this way:
wrapper<-function(x)
{
alpha<-x[1]
beta<-x[2]
ph<-x[3]
series<-x[4]
foofit<-ets(series,model="AZZ",alpha=alpha,beta=beta,phi=phi,additive.only=T,opt.cri
Hi Phani,
to get the best Holt's model, I would simply wrap a suitable function
calling ets() within optim() and optimize for alpha and beta - the
values given by ets() without constraints would probably be good
starting values, but you had better start the optimization with a
variety of star
Hey,
I am using the ets() function in the forecast package to find out the best
fit parameters for my time-series. I have about 50 sets of time series data.
I'm currently using the function as follows:
ets(x,model="AZZ",opt.crit="mse")
As to my observation about 5-10 of them have been identifie
4 matches
Mail list logo