[R] R Crashes when using "large" matrices (Ubuntu 11.04)

Prof. John C Nash nashjc at uottawa.ca
Sat Jun 4 13:31:15 CEST 2011


On Ubuntu 10.04 it ran fine, albeit in a machine with lots of memory, it seems to work
fine. Here's the output:
> rm(list=ls())
> gc()
         used (Mb) gc trigger (Mb) max used (Mb)
Ncells 131881  7.1     350000 18.7   350000 18.7
Vcells 128838  1.0     786432  6.0   559631  4.3
> p <- 500
> n <- 300
> set.seed(1234)
> x <- matrix(rnorm(n*p), n, p)
> sih <- var(x)
> b <- svd(sih)
>
> gc()
          used (Mb) gc trigger (Mb) max used (Mb)
Ncells  133536  7.2     350000 18.7   350000 18.7
Vcells 1030006  7.9    2644909 20.2  2536523 19.4
>

> sessionInfo()
R version 2.13.0 (2011-04-13)
Platform: x86_64-pc-linux-gnu (64-bit)

locale:
 [1] LC_CTYPE=en_US.utf8       LC_NUMERIC=C
 [3] LC_TIME=en_US.utf8        LC_COLLATE=en_US.utf8
 [5] LC_MONETARY=C             LC_MESSAGES=en_US.utf8
 [7] LC_PAPER=en_US.utf8       LC_NAME=C
 [9] LC_ADDRESS=C              LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.utf8 LC_IDENTIFICATION=C

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base
>


Maybe another 11.04 glitch.

JN


On 06/04/2011 06:00 AM, r-help-request at r-project.org wrote:
> Message: 93
> Date: Fri, 3 Jun 2011 18:55:06 -0700 (PDT)
> From: Matias Salibian-Barrera <msalibian at yahoo.ca>
> To: "R-help at r-project.org" <R-help at r-project.org>
> Subject: [R] R Crashes when using "large" matrices (Ubuntu 11.04)
> Message-ID: <75655.88533.qm at web161614.mail.bf1.yahoo.com>
> Content-Type: text/plain; charset=iso-8859-1
> 
> 
> This simple SVD calculation (commands are copied 
> immediately below) crashes on my Ubuntu machine (R 2.13.0). However it 
> works fine on my Windows 7 machine, so I suspect there's a problem with 
> (my?) Ubuntu and / or R. Can anybody else reproduce it (with Ubuntu 
> 11.04)? Thanks in advance.
> 
> p <- 500
> n <- 300
> set.seed(1234)
> x <- matrix(rnorm(n*p), n, p)
> sih <- var(x)
> b <- svd(sih)
>



More information about the R-help mailing list