[R] replace zeros in a block diagonal matrix with small random values?

Rick DeShon deshon at msu.edu
Tue Feb 24 14:28:03 CET 2009

Hi All.

Imagine you have a large block diagonal matrix.  I'd like to replace
the zeros in this matrix with small random (runif) numbers.  Any ideas
for a simple and efficient way to do this?

Best regards,

Rick DeShon

More information about the R-help mailing list