Skip to content
Prev 170655 / 398506 Next

Alternate to for-loop

On Mon, Feb 16, 2009 at 12:59 PM, megh <megh700004 at yahoo.com> wrote:
as a variant of Patrick Burns code, you can write:

rowMeans(matrix(rnorm(1000),ncol=100))

,and substitute another distribution for rnorm if you want.

/Gustaf