[R] sparse matrix

Martin Gotz xgotz at informatics.muni.cz
Mon Jan 8 15:49:14 CET 2001


On Mon, 8 Jan 2001, Prof Brian Ripley wrote:

> A matrix in R is a vector plus a dim atttribute.  I presume you mean a
> numeric matrix (there are other types).  Then it needs a 8byte space per
> entry.

Yes. Numeric matrix.

> There are other ways to handle matrices: look at package Matrix, for
> example.
> 
> One obvious representation is to store the non-zero elements and their
> locations.
> 
> Just how large is this matrix, and does it have a pattern to its sparsity?

10000 x 10000 elements and 50 000 x 50 000 elements
There is no pattern of sparsity. Values in matrix means some distance
between words (for 10000 and 5 0000 words). 
98% of elements in matrix are the same (with value 7500)

> And what do you want to do with it?  Doing things with sparse matrices has
> a tendency to make them less sparse.

Hierarchical clustering. Input matrix is distance matrix for hierarchical
clustering with function hclust.   


Thank you 
		 Martin Gotz

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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