[R] Defining a "list"

Megh Dal megh700004 at yahoo.com
Wed Oct 15 13:19:30 CEST 2008


Can anyone please tell me how to define a "list". Suppose I want to define a list object "result" with length n then want to fill each place of "result" with different objects. For e.g.

i=1
result[1] = rnorm(1)

i=2
result[2] = rnorm(2)

.......................

i=n
result[n] = rnorm(n)

What would be the best way to do that?

Regards,



More information about the R-help mailing list