[R] Re: Package tseries: crash for Windows version (PR#2302)

Mehmet Balcilar mbalcilar at manas.kg
Mon Nov 18 18:19:28 CET 2002


I also have the same bug under Linux. As far as I know, this is not new. 
I it had for almost a year, with previous versions of R and tseries Here 
is the relevant information.

 > R.version
         _               
platform i686-pc-linux-gnu
arch     i686            
os       linux-gnu       
system   i686, linux-gnu 
status                   
major    1               
minor    6.1             
year     2002            
month    11              
day      01              
language R               
 > Sys.info()
                           sysname                            release
                           "Linux"                     "2.4.19-16mdk"
                           version                           nodename
"#1 Fri Sep 20 18:15:05 CEST 2002"                   "rifle.manas.kg"
                           machine                              login
                            "i686"                          "unknown"
                              user
                          "mehmet"

 > library(tseries)

    `tseries' version: 0.9-4
 
    `tseries' is a package for time series analysis
     and computational finance.
     See `library (help=tseries)' for details.

 > example(garch)

garch> n <- 1100

garch> a <- c(0.1, 0.5, 0.2)

garch> e <- rnorm(n)

garch> x <- double(n)

garch> x[1:2] <- rnorm(2, sd = sqrt(a[1]/(1 - a[2] - a[3])))

garch> for (i in 3:n) {
    x[i] <- e[i] * sqrt(a[1] + a[2] * x[i - 1]^2 + a[3] * x[i -
        2]^2)
}

garch> x <- ts(x[101:1100])

garch> x.arch <- garch(x, order = c(0, 2))

 ***** ESTIMATION WITH ANALYTICAL GRADIENT *****


     I     INITIAL X(I)        D(I)

     1     0.244460E+00     0.100E+01
     2     0.500000E-01     0.100E+01
     3     0.500000E-01     0.100E+01

    IT   NF       F        RELDF    PRELDF    RELDX   STPPAR   D*STEP   
NPRELDF

     0    1 -0.192E+03
     1    3 -0.228E+03  0.16E+00  0.19E+00  0.2E+00  0.4E+04  0.1E+00  
0.41E+03
     2    5 -0.241E+03  0.54E-01  0.59E-01  0.1E+00  0.5E+01  0.5E-01  
0.25E+02
     3    6 -0.250E+03  0.36E-01  0.49E-01  0.1E+00  0.4E+03  0.5E-01  
0.24E+03
     4    7 -0.252E+03  0.49E-02  0.38E-01  0.1E+00  0.5E+01  0.5E-01  
0.91E+00
     5    8 -0.257E+03  0.22E-01  0.33E-01  0.7E-01  0.2E+01  0.5E-01  
0.19E+00
     6    9 -0.259E+03  0.82E-02  0.86E-02  0.9E-01  0.2E+01  0.5E-01  
0.39E+00
     7   10 -0.260E+03  0.15E-02  0.12E-01  0.8E-01  0.2E+01  0.5E-01  
0.21E+00
     8   11 -0.264E+03  0.16E-01  0.20E-01  0.6E-01  0.2E+01  0.5E-01  
0.13E+01
     9   12 -0.264E+03  0.92E-03  0.43E-02  0.6E-01  0.2E+01  0.5E-01  
0.10E+00
    10   13 -0.265E+03  0.35E-02  0.43E-02  0.6E-01  0.2E+01  0.5E-01  
0.15E-01
    11   15 -0.265E+03  0.69E-03  0.12E-02  0.7E-02  0.1E+02  0.5E-02  
0.49E-01
    12   16 -0.265E+03  0.54E-03  0.55E-03  0.6E-02  0.3E+01  0.5E-02  
0.79E-02
    13   17 -0.266E+03  0.91E-03  0.97E-03  0.1E-01  0.2E+01  0.1E-01  
0.66E-02
    14   19 -0.266E+03  0.22E-02  0.28E-02  0.6E-01  0.7E+00  0.5E-01  
0.37E-02
    15   20 -0.266E+03  0.70E-03  0.16E-02  0.6E-01  0.1E+01  0.5E-01  
0.16E-02
    16   21 -0.266E+03  0.26E-03  0.24E-03  0.2E-01  0.0E+00  0.2E-01  
0.24E-03
    17   22 -0.266E+03  0.33E-05  0.35E-05  0.2E-02  0.0E+00  0.2E-02  
0.35E-05
    18   23 -0.266E+03  0.22E-07  0.21E-07  0.1E-03  0.0E+00  0.1E-03  
0.21E-07
    19   24 -0.266E+03  0.26E-09  0.25E-09  0.2E-04  0.0E+00  0.2E-04  
0.25E-09
    20   25 -0.266E+03  0.92E-12  0.91E-12  0.1E-05  0.0E+00  0.1E-05  
0.91E-12

 ***** RELATIVE FUNCTION CONVERGENCE *****

 FUNCTION    -0.266482E+03   RELDX        0.147E-05
 FUNC. EVALS      25         GRAD. EVALS      21
 PRELDF       0.910E-12      NPRELDF      0.910E-12

     I      FINAL X(I)        D(I)          G(I)

     1    0.103728E+00     0.100E+01     0.168E-04
     2    0.431380E+00     0.100E+01    -0.181E-06
     3    0.214628E+00     0.100E+01     0.110E-04

Segmentation fault (core dumped)


Kenneth Cabrera wrote:

> ripley at stats.ox.ac.uk wrote:
>
>> This is not the appropriate place to report such an error, unless you
>> built the packages yourself under the current version of R, which you
>> clearly did not.
>>
> I did (both R and tseries).
> I build the tseries packages with the "Rcmd" command and also with 
> "make pkg-tseries" command.
>
>> And this is *definitely* not the place to say `me too'.  Neither of you
>> provided any debugging information.
>>
>> Please do not clog up R-bugs with reports on out-of-date builds, and
>> please do remember that having compiled versions for R is a *privilege*
>> which such reports abuse.
>>
>> Note that the tseries pre-compiled package did run the checks under the
>> version of R on its date stamp and this may well be a problem with the
>> R 1.6.1 build rather than the package.
>>
> I now check the package (so maybe the problem is in the package) with:
> "make pkgcheck-tseries"
> And the execution crashes with this output (tseries-Ex.Rout file)  on 
> the garch example:
>
> > ###--- >>> `garch' <<<----- Fit GARCH Models to Time Series
> >
> >     ## alias     help(garch)
> >
> > ##___ Examples ___:
> >
> > n <- 1100
> > a <- c(0.1, 0.5, 0.2)  # ARCH(2) coefficients
> > e <- rnorm(n) > x <- double(n)
> > x[1:2] <- rnorm(2, sd = sqrt(a[1]/(1.0-a[2]-a[3])))
> > for(i in 3:n)  # Generate ARCH(2) process
> + {
> +   x[i] <- e[i]*sqrt(a[1]+a[2]*x[i-1]^2+a[3]*x[i-2]^2)
> + }
> > x <- ts(x[101:1100])
> > x.arch <- garch(x, order = c(0,2))  # Fit ARCH(2)
>
> ***** ESTIMATION WITH ANALYTICAL GRADIENT *****
>
>
>     I     INITIAL X(I)        D(I)
>
>     1     0.334425E+00     0.100E+01
>     2     0.500000E-01     0.100E+01
>     3     0.500000E-01     0.100E+01
>
>    IT   NF       F        RELDF    PRELDF    RELDX   STPPAR   D*STEP   
> NPRELDF
>
>     0    1 -0.119E+03
>     1    3 -0.174E+03  0.32E+00  0.40E+00  0.1E+00  0.7E+04  0.1E+00  
> 0.14E+04
>     2    5 -0.221E+03  0.21E+00  0.24E+00  0.2E+00  0.8E+01  0.1E+00  
> 0.14E+04
>     3    6 -0.240E+03  0.80E-01  0.14E+00  0.2E+00  0.6E+01  0.1E+00  
> 0.44E+02
>     4    7 -0.243E+03  0.13E-01  0.12E+00  0.1E+00  0.2E+01  0.1E+00  
> 0.13E+02
>     5    8 -0.261E+03  0.69E-01  0.68E-01  0.1E+00  0.2E+01  0.1E+00  
> 0.25E+01
>     6    9 -0.262E+03  0.22E-02  0.24E-01  0.1E+00  0.3E+01  0.1E+00  
> 0.58E+00
>     7   10 -0.265E+03  0.12E-01  0.32E-01  0.4E-01  0.2E+01  0.5E-01  
> 0.54E+00
>     8   11 -0.266E+03  0.36E-02  0.50E-02  0.4E-01  0.2E+01  0.5E-01  
> 0.10E+00
>     9   14 -0.266E+03  0.38E-03  0.84E-03  0.5E-02  0.3E+01  0.7E-02  
> 0.26E+00
>    10   15 -0.266E+03  0.69E-03  0.83E-03  0.5E-02  0.2E+01  0.7E-02  
> 0.10E+00
>    11   16 -0.266E+03  0.58E-03  0.87E-03  0.1E-01  0.2E+01  0.1E-01  
> 0.52E-01
>    12   17 -0.266E+03  0.23E-03  0.15E-02  0.2E-01  0.2E+01  0.3E-01  
> 0.96E-02
>    13   18 -0.267E+03  0.11E-02  0.14E-02  0.3E-01  0.2E+01  0.3E-01  
> 0.75E-02
>    14   19 -0.267E+03  0.97E-04  0.19E-03  0.2E-01  0.0E+00  0.2E-01  
> 0.19E-03
>    15   22 -0.267E+03  0.44E-04  0.76E-04  0.1E-02  0.4E+01  0.1E-02  
> 0.25E-03
>    16   24 -0.267E+03  0.16E-04  0.16E-04  0.3E-02  0.6E+00  0.3E-02  
> 0.21E-04
>    17   25 -0.267E+03  0.40E-05  0.45E-05  0.3E-02  0.0E+00  0.3E-02  
> 0.45E-05
>    18   27 -0.267E+03  0.25E-06  0.39E-06  0.5E-03  0.1E+01  0.6E-03  
> 0.58E-06
>    19   28 -0.267E+03  0.15E-07  0.16E-07  0.2E-03  0.0E+00  0.2E-03  
> 0.16E-07
>    20   29 -0.267E+03  0.38E-10  0.38E-10  0.8E-05  0.0E+00  0.8E-05  
> 0.38E-10
>
> ***** RELATIVE FUNCTION CONVERGENCE *****
>
> FUNCTION    -0.266614E+03   RELDX        0.812E-05
> FUNC. EVALS      29         GRAD. EVALS      21
> PRELDF       0.384E-10      NPRELDF      0.384E-10
>
>     I      FINAL X(I)        D(I)          G(I)
>
>     1    0.935455E-01     0.100E+01    -0.107E-03
>     2    0.505532E+00     0.100E+01    -0.676E-05
>     3    0.212453E+00     0.100E+01    -0.114E-04
>
> >Your long-suffering Windows package compiler.
>
> I hope I will not make you suffer too much  ;-)
>


-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list