[R] slowness of auto.arima() from package forecast (was Execution time very high in linux)

Joao Santos jcsantos at student.dei.uc.pt
Fri Nov 9 17:19:46 CET 2007


Hello again,

I read the posting guide and now I could send the example.
I also send a mail directly to Prof. Rob J Hyndman that is the maintainer of
package forecast and if I have a answer I will send it to the list.

ts <-
structure(c(61, 60, 60, 59, 58, 58, 58, 58, 58, 61, 64, 65, 65, 
64, 64, 64, 63, 63, 62, 61, 60, 60, 60, 59, 58, 58, 58, 57, 57, 
57, 57, 56, 57, 57, 58, 59, 59, 59, 60, 60, 60, 61, 60, 60, 60, 
60, 60, 59, 58, 57, 57, 56, 55, 55, 55, 56, 60, 71, 76, 78, 77, 
78, 80, 80, 80, 79, 76, 71, 68, 66, 65, 64, 63, 62, 61, 60, 60, 
59, 59, 60, 63, 73, 77, 79, 78, 78, 80, 81, 81, 80, 77, 71, 67, 
67, 66, 65, 63, 62, 61, 60, 60, 60, 60, 60, 64, 74, 78, 80, 79, 
79, 81, 81, 81, 80, 76, 68, 66, 65, 65, 64, 63, 62, 61, 60, 60, 
60, 59, 60, 64, 73, 77, 79, 79, 78, 80, 80, 80, 80, 76, 70, 67, 
66, 65, 64, 63, 61, 61, 60, 60, 59, 59, 60, 63, 73, 77, 78, 78, 
78, 79, 80, 80, 79, 74, 69, 65, 64, 63, 62, 61, 60, 60, 59, 58, 
58, 58, 58, 59, 61, 63, 64, 63, 63, 63, 63, 64, 63, 63, 61, 60, 
60, 59, 59, 58, 58, 57, 56, 55, 55, 54, 54, 54, 54, 55, 55, 56, 
56, 57, 57, 58, 58, 58, 58, 57, 57, 57, 57, 57, 56, 55, 55, 54, 
54, 54, 55, 60, 72, 76, 77, 77, 77, 79, 80, 80, 79, 76, 70, 66, 
65, 64, 63, 62, 61, 61, 60, 60, 59, 58, 59, 63, 72, 76, 77, 77, 
77, 79, 80, 80, 79, 76, 71, 66, 65, 64, 63, 62, 61, 60, 58, 58, 
57, 57, 58, 62, 71, 75, 76, 77, 76, 78, 79, 79, 77, 74, 69, 65, 
64, 63, 62, 62, 60, 59, 58, 58, 58, 58, 58, 62, 69, 75, 78, 78, 
73, 64, 61, 58, 57, 56, 56, 55, 54, 53, 53, 53, 53, 53, 57, 69, 
74, 75, 75, 75, 76, 75, 76, 75, 71, 65, 60, 58, 54, 53, 53, 52, 
52, 51, 51, 49, 50, 51, 52, 55, 58, 60, 60, 59, 59, 60, 60, 59, 
59, 57, 57, 56, 56, 55, 55, 54, 54, 54, 53, 53, 53, 53, 53, 53, 
54, 54, 55, 55, 55, 56, 56, 56, 56, 56, 56, 56, 55, 55, 55, 54, 
54, 53, 53, 53, 52, 53, 57, 68, 73, 74, 74, 74, 76, 76, 77, 76, 
72, 67, 64, 63, 62, 61, 60, 59, 59, 58, 58, 57, 57, 58, 61, 71, 
75, 76, 76, 76, 78, 78, 78, 77, 74, 69, 65, 64, 63, 62, 59, 58, 
56, 53, 51, 51, 51, 48, 53, 67, 73, 75, 77, 78, 78, 78, 74, 68, 
65, 63, 63, 62, 61, 59, 59, 58, 57, 57, 57, 57, 61, 71, 75, 77, 
77, 77, 78, 79, 79, 78, 75, 69, 66, 65, 64, 63, 61, 60, 59, 58, 
58, 58, 58, 59, 62, 72, 76, 77, 78, 78, 78, 79, 79, 78, 74, 68, 
64, 63, 62, 61, 60, 59, 58), .Tsp = c(1, 3.9702380952381, 168
), class = "ts")


João Santos



Prof Brian Ripley wrote:
> 
> This is not the address of the package maintainer (nor of the person 
> who wrote to you), nor is that a reproducible example (we don't have 
> my_file.dat).  Please DO study the posting guide!
> 
> On Fri, 9 Nov 2007, Joao Santos wrote:
> 
>>
>> Hello,
>>
>> EXAMPLE
>> ##Create time series
>> bb_500 = scan("my_file.dat")
>> ts <- ts(bb_500, frequency=168)
> ...
> 
>> Prof Brian Ripley wrote:
>>>
>>> This is not about slowness of Linux nor of R but of a particular
>>> function
>>> in a contributed package.  Few of us are familiar with that package, and
>>> you have not given a reproducible example.  Please do as the posting
>>> guide
>>> asked and talk directly to the maintainer (who may well not read this
>>> list).
>>>
>>> I've altered the subject line to something less inappropriate.
>>>
>>> On Fri, 9 Nov 2007, Joao Santos wrote:
>>>
>>>>
>>>> Hello All,
>>>>
>>>> Sorry everybody for another message on this topic but I don't
>>>> understand
>>>> the
>>>> times off execution that I have.
>>>>> From my search in the forum I found that linux old be better to this
>>>>> kind of
>>>> operation, so now I using a dualCore 2.33GHz with 8Gb RAM but the times
>>>> off
>>>> execution don´t decrease.
>>>>
>>>> Once again the function and the times and I get in linux:
>>>> system.time(fit_2323v_168f<-auto.arima(regts.ts, d = NA, D = NA, max.p
>>>> =
>>>> 2,
>>>> max.q = 2,
>>>>            max.P = 1, max.Q = 1, max.order = 5,
>>>>            start.p=0, start.q=0, start.P=0, start.Q=0,
>>>>                        stationary = FALSE, ic = c("aic","aicc", "bic"),
>>>>            stepwise=FALSE, trace=TRUE))
>>>> user   system  elapsed
>>>> 38389.75  3786.29 22849.73
>>>>
>>>>
>>>> There is some optimization that could be done?
>>>>
>>>>
>>>> Thanks in advance for the replies!!!
>>>>
>>>>
>>>> João Santos
>>>>
>>>> Joao Santos wrote:
>>>>>
>>>>> Hello again,
>>>>>
>>>>> Sorry but the code that I insert wasn't write. Should be like this:
>>>>>
>>>>> fit_2323v_168f<-auto.arima(regts.ts, d = NA, D = NA, max.p = 2, max.q
>>>>> =
>>>>> 2,
>>>>>             max.P = 1, max.Q = 1, max.order = 5,
>>>>>             start.p=0, start.q=0, start.P=0, start.Q=0,
>>>>>                         stationary = FALSE, ic = c("aic","aicc",
>>>>> "bic"),
>>>>>             stepwise=TRUE, trace=TRUE)
>>>>>
>>>>> Sorry for the SPAM!!
>>>>>
>>>>> João Santos
>>>>>
>>>>>
>>>>> Joao Santos wrote:
>>>>>>
>>>>>> Hello,
>>>>>>
>>>>>> I using the fuction auto.arima() from package forecast to predict the
>>>>>> values of p,d,q and P,D,Q.
>>>>>> My problem is the execution time of this function, for example, a
>>>>>> time
>>>>>> series with 2323 values with seasonality to the week take over 8
>>>>>> hours
>>>>>> to
>>>>>> execute all the possibilities.
>>>>>> I using a computer with Windows XP,  a processor Intel Core2 Duo
>>>>>> T7300
>>>>>> and 2Gb of RAM.
>>>>>>
>>>>>> fit_2323v_168f<-auto.arima(regts.ts, d = 1, D = 1, max.p = 2, max.q =
>>>>>> 2,
>>>>>>             max.P = 1, max.Q = 1, max.order = 5,
>>>>>>             start.p=0, start.q=0, start.P=0, start.Q=0,
>>>>>>                         stationary = FALSE, ic = c("aic","aicc",
>>>>>> "bic"),
>>>>>>             stepwise=TRUE, trace=TRUE)
>>>>>>
>>>>>> It is any configuration to speed-up this?
>>>>>>
>>>>>>
>>>>>> Thanks in advance!
>>>>>>
>>>>>> João Santos
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>> --
>>> Brian D. Ripley,                  ripley at stats.ox.ac.uk
>>> Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
>>> University of Oxford,             Tel:  +44 1865 272861 (self)
>>> 1 South Parks Road,                     +44 1865 272866 (PA)
>>> Oxford OX1 3TG, UK                Fax:  +44 1865 272595
>>> ______________________________________________
>>> R-help at r-project.org mailing list
>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>> PLEASE do read the posting guide
>>> http://www.R-project.org/posting-guide.html
>>> and provide commented, minimal, self-contained, reproducible code.
>>>
>>>
>>
>>
> 
> -- 
> Brian D. Ripley,                  ripley at stats.ox.ac.uk
> Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
> University of Oxford,             Tel:  +44 1865 272861 (self)
> 1 South Parks Road,                     +44 1865 272866 (PA)
> Oxford OX1 3TG, UK                Fax:  +44 1865 272595
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
> 
> 

-- 
View this message in context: http://www.nabble.com/Help-me-please...Large-execution-time-in-auto.arima%28%29-function-tf4771610.html#a13670189
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list