[R] --mem-vsize in R

From: kparamas <kparamas_at_asu.edu>
Date: Fri, 29 Apr 2011 13:14:29 -0700 (PDT)


Hi,

I am calculation pairwise correlation coefficient for a matrix of 234 X 30000.
I am getting the following error,
Error in cbind(as.vector(row(cl)), as.vector(col(cl)), as.vector(cl)) :   allocMatrix: too many elements specified In addition: There were 50 or more warnings (use warnings() to see the first 50)

The function used is,
corGraphPearson = function(cData, COR) #COR is threshold 0.5,0.7, etc {

    cl = unname(cor(cData, use="pairwise.complete.obs", method="pearson"))

        result = cbind(as.vector(row(cl)),as.vector(col(cl)),as.vector(cl))
        result = result[result[,1] != result[,2],]

        corm = result


# remove low cor pairs
corm =corm[abs(corm[,3]) >= COR, ]
# the network
net <- network(corm, directed = F)
}

I am running this in a cluster with 4 machines with 24 GB memory each.

How should I start R so that I make max use of the memory availbale? Or how to overcome this issue?

--
View this message in context: http://r.789695.n4.nabble.com/mem-vsize-in-R-tp3484541p3484541.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
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.
Received on Fri 29 Apr 2011 - 21:03:00 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 29 Apr 2011 - 21:10:34 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive