> x <- matrix(1:10, ncol = 2) > xc <- cor(x[, 2], x[, 0]) > cbind(xc, vector())Process R floating point exception at Tue Feb 11 19:16:51 2003> version_ platform i686-pc-linux-gnu arch i686 os linux-gnu system i686, linux-gnu status major 1 minor 6.2 year 2003 month 01 day 10 language R -- Ramón Díaz-Uriarte Bioinformatics Unit Centro Nacional de Investigaciones Oncológicas (CNIO) (Spanish National Cancer Center) Melchor Fernández Almagro, 3 28029 Madrid (Spain) http://bioinfo.cnio.es/~rdiaz
Peter Dalgaard BSA
2003-Feb-11 19:43 UTC
[Rd] cbind rises floating point exception (PR#2541)
rdiaz@cnio.es writes:> > x <- matrix(1:10, ncol = 2) > > xc <- cor(x[, 2], x[, 0]) > > cbind(xc, vector())[SIGFPE] Confirmed. Similar effect: y <- matrix(0,1,0) cbind(y,vector()) Actually not a floating point error but an arithmetic exception from calculation of i % k with i = k = 0 at l.1123 in bind.c. Presumably the "if (length(u) >lenmin)" should also check that length(u) > 0. -- O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard@biostat.ku.dk) FAX: (+45) 35327907